markov_chain_chat_bot 0.1.4 → 0.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/lib/markov_chain_chat_bot.rb +2 -2
- metadata +2 -2
@@ -98,7 +98,7 @@ class MarkovChainChatBot
|
|
98
98
|
) or
|
99
99
|
# Punctuation.
|
100
100
|
(
|
101
|
-
p = s.scan(/([#{WHITESPACE_CHARSET}]|[^\-–a-zA-Zа-яёА-ЯЁ0-9]|[-–](?![a-zA-Zа-яёА-ЯЁ0-9
|
101
|
+
p = s.scan(/([#{WHITESPACE_CHARSET}]|[^\-–a-zA-Zа-яёА-ЯЁ0-9]|[-–](?![a-zA-Zа-яёА-ЯЁ0-9]))+/o) and begin
|
102
102
|
p.gsub(/[#{WHITESPACE_CHARSET}]+/, " ")
|
103
103
|
if p != " " then
|
104
104
|
tokens << PunctuationMark.new(p)
|
@@ -117,7 +117,7 @@ class MarkovChainChatBot
|
|
117
117
|
# Character Database" (http://www.unicode.org/reports/tr44, specifically
|
118
118
|
# http://www.unicode.org/Public/UNIDATA/PropList.txt).
|
119
119
|
#
|
120
|
-
WHITESPACE_CHARSET = "
|
120
|
+
WHITESPACE_CHARSET = "\u0009-\u000D\u0020\u0085\u00A0\u1680\u180E\u2000-\u200A\u2028\u2029\u202F\u205F\u3000"
|
121
121
|
|
122
122
|
Token = Object
|
123
123
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: markov_chain_chat_bot
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.6
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2015-12-
|
12
|
+
date: 2015-12-17 00:00:00.000000000 Z
|
13
13
|
dependencies: []
|
14
14
|
description: A chat bot utilizing Markov chains. It speaks Russian and English.
|
15
15
|
email: Lavir.th.Whiolet@gmail.com
|