saasagi 0.1.6 → 0.2.1
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.
- checksums.yaml +4 -4
- data/.travis.yml +1 -2
- data/CODE_OF_CONDUCT.md +3 -3
- data/Gemfile +3 -0
- data/LICENSE.txt +1 -1
- data/README.md +4 -3
- data/lib/saasagi.rb +65 -39
- data/lib/saasagi/version.rb +1 -1
- data/saasagi.gemspec +4 -3
- metadata +8 -13
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2d6c2160b7d38aa10252480802fcbd925e462b6c1ad5c4107a6c3b85b51f1449
|
4
|
+
data.tar.gz: 1fc711afe8b1320e5cc2ac6bd1e99c2edd0065c4835aa58a5aac973298a9ed7b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7d7ff15f81d8f629d2074725a105292c139a7fc88d9f2dd6c0cf555a3b3e5d50bb4183a839a3917d26d986d1076814987d73f6334ad4a9a37e4149b6fd91d79a
|
7
|
+
data.tar.gz: 63244f5ff5b71184baaf62256b2f981a408b703f79c667fc8bdf8e8fcddbe6ceac1d233769764dd61b4b209f2a48e013e9283ae0400fbe17f94d536e281f303a
|
data/.travis.yml
CHANGED
data/CODE_OF_CONDUCT.md
CHANGED
@@ -68,7 +68,7 @@ members of the project's leadership.
|
|
68
68
|
## Attribution
|
69
69
|
|
70
70
|
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
|
71
|
-
available at [
|
71
|
+
available at [https://contributor-covenant.org/version/1/4][version]
|
72
72
|
|
73
|
-
[homepage]:
|
74
|
-
[version]:
|
73
|
+
[homepage]: https://contributor-covenant.org
|
74
|
+
[version]: https://contributor-covenant.org/version/1/4/
|
data/Gemfile
CHANGED
data/LICENSE.txt
CHANGED
data/README.md
CHANGED
@@ -14,7 +14,7 @@ gem 'saasagi'
|
|
14
14
|
|
15
15
|
And then execute:
|
16
16
|
|
17
|
-
$ bundle
|
17
|
+
$ bundle install
|
18
18
|
|
19
19
|
Or install it yourself as:
|
20
20
|
|
@@ -32,7 +32,8 @@ To install this gem onto your local machine, run `bundle exec rake install`. To
|
|
32
32
|
|
33
33
|
## Contributing
|
34
34
|
|
35
|
-
Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/saasagi. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [
|
35
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/saasagi. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/[USERNAME]/saasagi/blob/master/CODE_OF_CONDUCT.md).
|
36
|
+
|
36
37
|
|
37
38
|
## License
|
38
39
|
|
@@ -40,4 +41,4 @@ The gem is available as open source under the terms of the [MIT License](https:/
|
|
40
41
|
|
41
42
|
## Code of Conduct
|
42
43
|
|
43
|
-
Everyone interacting in the Saasagi project
|
44
|
+
Everyone interacting in the Saasagi project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/[USERNAME]/saasagi/blob/master/CODE_OF_CONDUCT.md).
|
data/lib/saasagi.rb
CHANGED
@@ -63,7 +63,7 @@ module Saasagi
|
|
63
63
|
open("tree_dGoal.rb", "w") { |f|
|
64
64
|
f.puts prewrite
|
65
65
|
}
|
66
|
-
|
66
|
+
|
67
67
|
open(".backup/tree_dGoal.rb", "w") { |f|
|
68
68
|
f.puts prewrite
|
69
69
|
}
|
@@ -85,18 +85,46 @@ module Saasagi
|
|
85
85
|
}
|
86
86
|
end
|
87
87
|
|
88
|
-
def self.
|
89
|
-
prewrite = File.read(".prewrite/
|
90
|
-
|
91
|
-
open("data/input/
|
88
|
+
def self.assemble_bedroom
|
89
|
+
prewrite = File.read(".prewrite/tree_test_bedroom.txt")
|
90
|
+
|
91
|
+
open("data/input/bedroom_test_ratio.txt", "w") { |f|
|
92
92
|
f.puts "0"
|
93
93
|
}
|
94
94
|
|
95
|
-
open("
|
95
|
+
open("tree_test_bedroom.rb", "w") { |f|
|
96
96
|
f.puts prewrite
|
97
97
|
}
|
98
|
-
|
99
|
-
|
98
|
+
end
|
99
|
+
|
100
|
+
def self.assemble_translator
|
101
|
+
prewrite = File.read(".prewrite/tree_translate_hafestra.txt")
|
102
|
+
|
103
|
+
open("data/input/bedroom_test_ratio.txt", "w") { |f|
|
104
|
+
f.puts "0"
|
105
|
+
}
|
106
|
+
|
107
|
+
open("tree_translate_hafestra.rb", "w") { |f|
|
108
|
+
f.puts prewrite
|
109
|
+
}
|
110
|
+
|
111
|
+
open(".backup/tree_translate_hafestra.rb", "w") { |f|
|
112
|
+
f.puts prewrite
|
113
|
+
}
|
114
|
+
end
|
115
|
+
|
116
|
+
def self.assemble_trends
|
117
|
+
prewrite = File.read(".prewrite/tree_trend_estimate.txt")
|
118
|
+
|
119
|
+
open("data/input/estimate_trends_ratio.txt", "w") { |f|
|
120
|
+
f.puts "0"
|
121
|
+
}
|
122
|
+
|
123
|
+
open("tree_trend_estimate.rb", "w") { |f|
|
124
|
+
f.puts prewrite
|
125
|
+
}
|
126
|
+
|
127
|
+
open(".backup/tree_trend_estimate.rb", "w") { |f|
|
100
128
|
f.puts prewrite
|
101
129
|
}
|
102
130
|
end
|
@@ -213,28 +241,26 @@ module Saasagi
|
|
213
241
|
f.puts "def #{method_name}#{ratio}"
|
214
242
|
f.puts " require 'decisiontree'"
|
215
243
|
f.puts " "
|
216
|
-
f.puts " def
|
217
|
-
f.puts "
|
244
|
+
f.puts " def robot_#{method_name}"
|
245
|
+
f.puts " a = ai_#{action}"
|
246
|
+
f.puts " end"
|
218
247
|
f.puts " "
|
219
|
-
f.puts "
|
220
|
-
f.puts "
|
221
|
-
f.puts "
|
222
|
-
f.puts " print 'Robot is increasingly restless, #{action} or stay? >> '"
|
223
|
-
f.puts " input = gets.chomp"
|
248
|
+
f.puts " def confirm_deny"
|
249
|
+
f.puts " print 'Robot is increasingly restless, #{action} or stay? >> '"
|
250
|
+
f.puts " input = gets.chomp"
|
224
251
|
f.puts " "
|
225
|
-
f.puts "
|
226
|
-
f.puts "
|
227
|
-
f.puts "
|
228
|
-
f.puts "
|
252
|
+
f.puts " if input == '#{action}'"
|
253
|
+
f.puts " a = ai_#{action}"
|
254
|
+
f.puts " elsif input == 'stay'"
|
255
|
+
f.puts " require 'espeak'"
|
229
256
|
f.puts " "
|
230
|
-
f.puts "
|
231
|
-
f.puts "
|
232
|
-
f.puts "
|
233
|
-
f.puts "
|
257
|
+
f.puts " speech = ESpeak::Speech.new('I chose to stay.')"
|
258
|
+
f.puts " speech.speak"
|
259
|
+
f.puts " else"
|
260
|
+
f.puts " require 'espeak'"
|
234
261
|
f.puts " "
|
235
|
-
f.puts "
|
236
|
-
f.puts "
|
237
|
-
f.puts " end"
|
262
|
+
f.puts " speech = ESpeak::Speech.new('Command not understood.')"
|
263
|
+
f.puts " speech.speak"
|
238
264
|
f.puts " end"
|
239
265
|
f.puts " end"
|
240
266
|
f.puts " "
|
@@ -251,21 +277,21 @@ module Saasagi
|
|
251
277
|
f.puts " dec_tree = DecisionTree::ID3Tree.new(attributes, training, 1, :continuous); dec_tree.train"
|
252
278
|
f.puts " test = [input]"
|
253
279
|
f.puts " "
|
254
|
-
f.puts "
|
255
|
-
f.puts "
|
280
|
+
f.puts " decision = dec_tree.predict(test)"
|
281
|
+
f.puts " true_decision = test.last"
|
256
282
|
f.puts " "
|
257
|
-
f.puts " print '#{method_name.upcase}: '; print
|
258
|
-
f.puts " puts '\n
|
283
|
+
f.puts " print '#{method_name.upcase}: '; print decision"
|
284
|
+
f.puts " puts '\n'"
|
259
285
|
f.puts " "
|
260
|
-
f.puts " if
|
261
|
-
f.puts " elsif
|
262
|
-
f.puts " elsif
|
263
|
-
f.puts " elsif
|
264
|
-
f.puts " elsif
|
265
|
-
f.puts " elsif
|
266
|
-
f.puts " elsif
|
267
|
-
f.puts " elsif
|
268
|
-
f.puts " elsif
|
286
|
+
f.puts " if decision == 'Very Low' or 13.75; c = confirm_deny"
|
287
|
+
f.puts " elsif decision == 'Somewhat Low' or 20.625; c = confirm_deny"
|
288
|
+
f.puts " elsif decision == 'Normal Low' or 67.5; c = confirm_deny"
|
289
|
+
f.puts " elsif decision == 'Medium' or 37.3125; c = confirm_deny"
|
290
|
+
f.puts " elsif decision == 'High' or 54.0; c = confirm_deny"
|
291
|
+
f.puts " elsif decision == 'Urgent' or 67.5; c = confirm_deny"
|
292
|
+
f.puts " elsif decision == 'Danger' or 81.0; c = confirm_deny"
|
293
|
+
f.puts " elsif decision == 'Critical' or 94.5; c = confirm_deny"
|
294
|
+
f.puts " elsif decision == 'Automatic' or 108.0; r = robot_#{method_name}"
|
269
295
|
f.puts " end"
|
270
296
|
f.puts " "
|
271
297
|
f.puts "end"
|
data/lib/saasagi/version.rb
CHANGED
data/saasagi.gemspec
CHANGED
@@ -6,12 +6,13 @@ Gem::Specification.new do |spec|
|
|
6
6
|
spec.name = "saasagi"
|
7
7
|
spec.version = Saasagi::VERSION
|
8
8
|
spec.authors = ["LWFlouisa"]
|
9
|
-
spec.email = ["
|
9
|
+
spec.email = ["lwflouisa@riseup.net"]
|
10
10
|
|
11
|
-
spec.summary = %q{
|
12
|
-
spec.description = %q{
|
11
|
+
spec.summary = %q{An extension of Asagi to include self-assembling on basic subroutines.}
|
12
|
+
spec.description = %q{Asagi is an AI Sequencing AGI engine. This new gem extends the Asagi codebase, and allows for completely automatic assembling of certain basic subroutines.}
|
13
13
|
spec.homepage = ""
|
14
14
|
spec.license = "MIT"
|
15
|
+
spec.required_ruby_version = Gem::Requirement.new(">= 2.3.0")
|
15
16
|
|
16
17
|
# Specify which files should be added to the gem when it is released.
|
17
18
|
# The `git ls-files -z` loads the files in the RubyGem that have been added into git.
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: saasagi
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1
|
4
|
+
version: 0.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- LWFlouisa
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-02-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -52,13 +52,10 @@ dependencies:
|
|
52
52
|
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '3.0'
|
55
|
-
description:
|
56
|
-
|
57
|
-
from backup, and the ability for the machine to program itself, with a few simple
|
58
|
-
instructions. Clone a group of them together, and you can eventually build more
|
59
|
-
complex systems at the artificial cellular level.
|
55
|
+
description: Asagi is an AI Sequencing AGI engine. This new gem extends the Asagi
|
56
|
+
codebase, and allows for completely automatic assembling of certain basic subroutines.
|
60
57
|
email:
|
61
|
-
-
|
58
|
+
- lwflouisa@riseup.net
|
62
59
|
executables: []
|
63
60
|
extensions: []
|
64
61
|
extra_rdoc_files: []
|
@@ -88,17 +85,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
88
85
|
requirements:
|
89
86
|
- - ">="
|
90
87
|
- !ruby/object:Gem::Version
|
91
|
-
version:
|
88
|
+
version: 2.3.0
|
92
89
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
93
90
|
requirements:
|
94
91
|
- - ">="
|
95
92
|
- !ruby/object:Gem::Version
|
96
93
|
version: '0'
|
97
94
|
requirements: []
|
98
|
-
|
99
|
-
rubygems_version: 2.7.6
|
95
|
+
rubygems_version: 3.0.6
|
100
96
|
signing_key:
|
101
97
|
specification_version: 4
|
102
|
-
summary:
|
103
|
-
to a single-celled organism.
|
98
|
+
summary: An extension of Asagi to include self-assembling on basic subroutines.
|
104
99
|
test_files: []
|