big_ml 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (47) hide show
  1. data/README.md +2 -1
  2. data/big_ml.gemspec +1 -1
  3. data/lib/big_ml/util/client.rb +7 -2
  4. data/lib/big_ml/util/config.rb +7 -2
  5. data/lib/big_ml/version.rb +1 -1
  6. data/spec/spec_helper.rb +2 -2
  7. data/spec/units/client_spec.rb +37 -6
  8. data/spec/vcr_cassettes/BigML_Dataset/no_dataset/_all/must_be_empty.yml +16 -95
  9. data/spec/vcr_cassettes/BigML_Dataset/one_dataset/can_be_converted_in_a_model.yml +69 -67
  10. data/spec/vcr_cassettes/BigML_Dataset/one_dataset/must_be_able_to_be_deleted_using_the_destroy_method.yml +72 -71
  11. data/spec/vcr_cassettes/BigML_Dataset/one_dataset/must_be_able_to_be_find_using_the_reference.yml +104 -103
  12. data/spec/vcr_cassettes/BigML_Dataset/one_dataset/must_be_able_to_remove_the_dataset.yml +66 -65
  13. data/spec/vcr_cassettes/BigML_Dataset/one_dataset/must_be_able_to_update_the_name.yml +148 -147
  14. data/spec/vcr_cassettes/BigML_Dataset/one_dataset/must_be_able_to_update_the_name_from_the_instance.yml +147 -146
  15. data/spec/vcr_cassettes/BigML_Dataset/one_dataset/must_have_only_one_item.yml +83 -80
  16. data/spec/vcr_cassettes/BigML_Dataset/one_dataset/must_have_the_same_file_name.yml +119 -74
  17. data/spec/vcr_cassettes/BigML_Dataset/one_dataset/was_created_successfully.yml +36 -36
  18. data/spec/vcr_cassettes/BigML_Model/no_model/_all/must_be_empty.yml +89 -87
  19. data/spec/vcr_cassettes/BigML_Model/one_model/can_be_converted_in_a_prediction.yml +101 -99
  20. data/spec/vcr_cassettes/BigML_Model/one_model/must_be_able_to_be_deleted_using_the_destroy_method.yml +91 -89
  21. data/spec/vcr_cassettes/BigML_Model/one_model/must_be_able_to_be_find_using_the_reference.yml +191 -200
  22. data/spec/vcr_cassettes/BigML_Model/one_model/must_be_able_to_remove_the_model.yml +109 -231
  23. data/spec/vcr_cassettes/BigML_Model/one_model/must_be_able_to_update_the_name.yml +272 -252
  24. data/spec/vcr_cassettes/BigML_Model/one_model/must_be_able_to_update_the_name_from_the_instance.yml +126 -252
  25. data/spec/vcr_cassettes/BigML_Model/one_model/must_have_only_one_item.yml +117 -113
  26. data/spec/vcr_cassettes/BigML_Model/one_model/must_have_the_same_size.yml +158 -120
  27. data/spec/vcr_cassettes/BigML_Model/one_model/was_created_successfully.yml +101 -56
  28. data/spec/vcr_cassettes/BigML_Prediction/no_prediction/_all/must_be_empty.yml +96 -94
  29. data/spec/vcr_cassettes/BigML_Prediction/one_prediction/must_be_able_to_be_deleted_using_the_destroy_method.yml +126 -124
  30. data/spec/vcr_cassettes/BigML_Prediction/one_prediction/must_be_able_to_be_find_using_the_reference.yml +147 -145
  31. data/spec/vcr_cassettes/BigML_Prediction/one_prediction/must_be_able_to_remove_the_prediction.yml +141 -139
  32. data/spec/vcr_cassettes/BigML_Prediction/one_prediction/must_be_able_to_update_the_name.yml +159 -157
  33. data/spec/vcr_cassettes/BigML_Prediction/one_prediction/must_be_able_to_update_the_name_from_the_instance.yml +161 -159
  34. data/spec/vcr_cassettes/BigML_Prediction/one_prediction/must_have_only_one_item.yml +145 -143
  35. data/spec/vcr_cassettes/BigML_Prediction/one_prediction/must_have_the_same_name.yml +148 -146
  36. data/spec/vcr_cassettes/BigML_Prediction/one_prediction/was_created_successfully.yml +75 -74
  37. data/spec/vcr_cassettes/BigML_Source/no_source/_all/must_be_empty.yml +25 -24
  38. data/spec/vcr_cassettes/BigML_Source/one_source/can_be_converted_in_a_dataset.yml +32 -32
  39. data/spec/vcr_cassettes/BigML_Source/one_source/must_be_able_to_be_deleted_using_the_destroy_method.yml +21 -21
  40. data/spec/vcr_cassettes/BigML_Source/one_source/must_be_able_to_be_find_using_the_reference.yml +48 -47
  41. data/spec/vcr_cassettes/BigML_Source/one_source/must_be_able_to_remove_the_source.yml +43 -42
  42. data/spec/vcr_cassettes/BigML_Source/one_source/must_be_able_to_update_the_name.yml +77 -76
  43. data/spec/vcr_cassettes/BigML_Source/one_source/must_be_able_to_update_the_name_from_the_instance.yml +78 -77
  44. data/spec/vcr_cassettes/BigML_Source/one_source/must_have_only_one_item.yml +53 -51
  45. data/spec/vcr_cassettes/BigML_Source/one_source/must_have_the_same_file_name.yml +52 -50
  46. data/spec/vcr_cassettes/BigML_Source/one_source/was_created_successfully.yml +14 -14
  47. metadata +5 -5
data/README.md CHANGED
@@ -12,7 +12,8 @@ require 'big_ml'
12
12
 
13
13
  BigML.configure do |c|
14
14
  c.username = 'foo'
15
- c.api_key = 'bar'
15
+ c.api_key = 'bar'
16
+ c.dev_mode = true
16
17
  end
17
18
 
18
19
  # easy creation of sources
data/big_ml.gemspec CHANGED
@@ -6,7 +6,7 @@ Gem::Specification.new do |gem|
6
6
  gem.email = ["vigosan@gmail.com", "felipe.talavera@gmail.com"]
7
7
  gem.description = %q{A Ruby wrapper for the BigML REST API}
8
8
  gem.summary = %q{A Ruby wrapper for the BigML REST API}
9
- gem.homepage = "https://bigml.com"
9
+ gem.homepage = "http://vigosan.github.com/big_ml"
10
10
 
11
11
  gem.add_dependency "httmultiparty"
12
12
  gem.add_dependency "json"
@@ -11,8 +11,6 @@ module BigML
11
11
  include Request
12
12
  format :json
13
13
 
14
- base_uri Config::BIGML_ENDPOINT
15
-
16
14
  attr_accessor *Config::VALID_OPTIONS_KEYS
17
15
 
18
16
  def initialize(attrs={})
@@ -20,6 +18,13 @@ module BigML
20
18
  Config::VALID_OPTIONS_KEYS.each { |key|
21
19
  instance_variable_set("@#{key}".to_sym, attrs[key])
22
20
  }
21
+ self.class.base_uri big_ml_url
22
+ end
23
+
24
+ protected
25
+
26
+ def big_ml_url
27
+ dev_mode ? Config::BIGML_DEV_ENDPOINT : Config::BIGML_PROD_ENDPOINT
23
28
  end
24
29
  end
25
30
  end
@@ -2,13 +2,17 @@ module BigML
2
2
  module Util
3
3
  module Config
4
4
  # The endpoint that will be used to connect if none is set
5
- BIGML_ENDPOINT = "https://bigml.io/andromeda"
5
+ BIGML_PROD_ENDPOINT = "https://bigml.io/andromeda"
6
+ # The endpoint that will be used when dev_mode is enabled
7
+ BIGML_DEV_ENDPOINT = "https://bigml.io/dev/andromeda"
6
8
  # The username if none is set
7
9
  DEFAULT_BIGML_USERNAME = nil
8
10
  # The api key if none is set
9
11
  DEFAULT_BIGML_API_KEY = nil
12
+ # Set default mode to production
13
+ DEFAULT_IN_DEV_MODE = false
10
14
  # An array of valid keys in the options hash when configuring a {BigML::Client}
11
- VALID_OPTIONS_KEYS = [:username, :api_key]
15
+ VALID_OPTIONS_KEYS = [:username, :api_key, :dev_mode]
12
16
 
13
17
  attr_accessor *VALID_OPTIONS_KEYS
14
18
 
@@ -26,6 +30,7 @@ module BigML
26
30
  def reset
27
31
  self.username = DEFAULT_BIGML_USERNAME
28
32
  self.api_key = DEFAULT_BIGML_API_KEY
33
+ self.dev_mode = DEFAULT_IN_DEV_MODE
29
34
  end
30
35
  end
31
36
  end
@@ -1,3 +1,3 @@
1
1
  module BigML
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
3
3
  end
data/spec/spec_helper.rb CHANGED
@@ -4,7 +4,8 @@ require 'vcr'
4
4
 
5
5
  BigML.configure do |c|
6
6
  c.username = 'foo'
7
- c.api_key = 'bar'
7
+ c.api_key = 'bar'
8
+ c.dev_mode = true
8
9
  end
9
10
 
10
11
  VCR.configure do |c|
@@ -15,7 +16,6 @@ VCR.configure do |c|
15
16
  c.filter_sensitive_data('<API_KEY>') { BigML.api_key }
16
17
  end
17
18
 
18
-
19
19
  RSpec.configure do |c|
20
20
  c.mock_with :rspec
21
21
  c.treat_symbols_as_metadata_keys_with_true_values = true
@@ -19,17 +19,18 @@ describe BigML::Util::Client do
19
19
  end
20
20
 
21
21
  context "class configuration" do
22
- let(:credentials) {
22
+ let(:config) {
23
23
  {
24
24
  :username => 'user',
25
- :api_key => 'secret'
25
+ :api_key => 'secret',
26
+ :dev_mode => true
26
27
  }
27
28
  }
28
29
 
29
30
  context "during initialization" do
30
31
  it "should override module configuration" do
31
- api = BigML::Util::Client.new(credentials)
32
- keys.each { |key| api.send(key).should == credentials[key] }
32
+ api = BigML::Util::Client.new(config)
33
+ keys.each { |key| api.send(key).should == config[key] }
33
34
  end
34
35
  end
35
36
 
@@ -42,9 +43,39 @@ describe BigML::Util::Client do
42
43
 
43
44
  it "should override module configuration" do
44
45
  api = BigML::Util::Client.new
45
- credentials.each { |key, value| api.send("#{key}=", value) }
46
- keys.each { |key| api.send(key).should == credentials[key] }
46
+ config.each { |key, value| api.send("#{key}=", value) }
47
+ keys.each { |key| api.send(key).should == config[key] }
47
48
  end
48
49
  end
49
50
  end
51
+
52
+ context "reset module configuration" do
53
+ let(:api) {
54
+ BigML::Util::Client.new
55
+ }
56
+
57
+ before(:each) {
58
+ BigML.reset
59
+ }
60
+
61
+ it "sets default username to nil" do
62
+ api.username.should be_nil
63
+ end
64
+
65
+ it "sets default api key to nil" do
66
+ api.api_key.should be_nil
67
+ end
68
+ end
69
+
70
+ context "environemt mode" do
71
+ it "uses production mode as default" do
72
+ BigML::Util::Client.base_uri.should == BigML::Util::Config::BIGML_PROD_ENDPOINT
73
+ end
74
+
75
+ it "uses development when dev_mode is enabled" do
76
+ BigML::Util::Client.new({:dev_mode => true})
77
+ BigML::Util::Client.base_uri.should == BigML::Util::Config::BIGML_DEV_ENDPOINT
78
+ end
79
+ end
80
+
50
81
  end
@@ -2,7 +2,7 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: get
5
- uri: https://bigml.io/andromeda/source?username=<USERNAME>&api_key=<API_KEY>
5
+ uri: https://bigml.io/dev/andromeda/source?username=<USERNAME>&api_key=<API_KEY>
6
6
  body:
7
7
  encoding: US-ASCII
8
8
  string: ''
@@ -17,65 +17,22 @@ http_interactions:
17
17
  content-type:
18
18
  - application/json; charset=utf-8
19
19
  date:
20
- - Thu, 28 Jun 2012 22:19:04 GMT
20
+ - Sat, 14 Jul 2012 15:16:03 GMT
21
21
  server:
22
22
  - nginx/1.0.12
23
23
  content-length:
24
- - '1280'
24
+ - '101'
25
25
  connection:
26
26
  - Close
27
27
  body:
28
28
  encoding: US-ASCII
29
29
  string: ! '{"meta": {"limit": 20, "next": null, "offset": 0, "previous": null,
30
- "total_count": 1}, "objects": [{"category": 0, "code": 200, "content_type":
31
- "application/octet-stream", "created": "2012-06-27T02:29:17.948000", "credits":
32
- 0.0, "description": "", "fields": {"000000": {"column_number": 0, "name":
33
- "sepal length", "optype": "numeric"}, "000001": {"column_number": 1, "name":
34
- "sepal width", "optype": "numeric"}, "000002": {"column_number": 2, "name":
35
- "petal length", "optype": "numeric"}, "000003": {"column_number": 3, "name":
36
- "petal width", "optype": "numeric"}, "000004": {"column_number": 4, "name":
37
- "species", "optype": "categorical"}}, "file_name": "iris.csv", "md5": "d1175c032e1042bec7f974c91e4a65ae",
38
- "name": "new name", "number_of_datasets": 0, "number_of_models": 0, "number_of_predictions":
39
- 0, "private": true, "resource": "source/4fea6ffd035d0741f0001c38", "size":
40
- 4608, "source_parser": {"header": true, "locale": "en_US", "missing_tokens":
41
- ["", "N/A", "n/a", "NULL", "null", "-", "#DIV/0", "#REF!", "#NAME?", "NIL",
42
- "nil", "NA", "na", "#VALUE!", "#NULL!", "NaN", "#N/A", "#NUM!", "?"], "quote":
43
- "\"", "separator": ","}, "status": {"code": 5, "elapsed": 73, "message": "The
44
- source has been created"}, "tags": [], "type": 0, "updated": "2012-06-27T02:30:04.724000"}]}'
45
- http_version: '1.1'
46
- recorded_at: Thu, 28 Jun 2012 22:23:51 GMT
47
- - request:
48
- method: delete
49
- uri: https://bigml.io/andromeda/source/4fea6ffd035d0741f0001c38?username=<USERNAME>&api_key=<API_KEY>
50
- body:
51
- encoding: US-ASCII
52
- string: ''
53
- headers:
54
- connection:
55
- - close
56
- response:
57
- status:
58
- code: 204
59
- message: NO CONTENT
60
- headers:
61
- content-length:
62
- - '0'
63
- content-type:
64
- - text/html; charset=utf-8
65
- date:
66
- - Thu, 28 Jun 2012 22:21:40 GMT
67
- server:
68
- - nginx/1.0.12
69
- connection:
70
- - Close
71
- body:
72
- encoding: US-ASCII
73
- string: ''
30
+ "total_count": 0}, "objects": []}'
74
31
  http_version: '1.1'
75
- recorded_at: Thu, 28 Jun 2012 22:23:53 GMT
32
+ recorded_at: Sat, 14 Jul 2012 15:17:06 GMT
76
33
  - request:
77
34
  method: get
78
- uri: https://bigml.io/andromeda/dataset?username=<USERNAME>&api_key=<API_KEY>
35
+ uri: https://bigml.io/dev/andromeda/dataset?username=<USERNAME>&api_key=<API_KEY>
79
36
  body:
80
37
  encoding: US-ASCII
81
38
  string: ''
@@ -90,58 +47,22 @@ http_interactions:
90
47
  content-type:
91
48
  - application/json; charset=utf-8
92
49
  date:
93
- - Thu, 28 Jun 2012 22:19:08 GMT
50
+ - Sat, 14 Jul 2012 15:11:04 GMT
94
51
  server:
95
52
  - nginx/1.0.12
96
- transfer-encoding:
97
- - chunked
98
- connection:
99
- - Close
100
- body:
101
- encoding: US-ASCII
102
- string: ! '{"meta": {"limit": 20, "next": null, "offset": 0, "previous": null,
103
- "total_count": 1}, "objects": [{"category": 0, "code": 200, "columns": 5,
104
- "created": "2012-06-27T02:29:27.721000", "credits": 0.00439453125, "description":
105
- "", "locale": "en_US", "name": "iris'' dataset", "number_of_models": 1, "number_of_predictions":
106
- 1, "private": true, "resource": "dataset/4fea700715526875f5001bff", "rows":
107
- 150, "size": 4608, "source": "source/4fea6fd9035d0741f4001bdb", "source_status":
108
- false, "status": {"bytes": 4608, "code": 5, "elapsed": 210, "field_errors":
109
- [], "message": "The dataset has been created", "row_format_errors": [], "serialized_rows":
110
- 150}, "tags": [], "updated": "2012-06-27T02:28:47.906000"}]}'
111
- http_version: '1.1'
112
- recorded_at: Thu, 28 Jun 2012 22:23:55 GMT
113
- - request:
114
- method: delete
115
- uri: https://bigml.io/andromeda/dataset/4fea700715526875f5001bff?username=<USERNAME>&api_key=<API_KEY>
116
- body:
117
- encoding: US-ASCII
118
- string: ''
119
- headers:
120
- connection:
121
- - close
122
- response:
123
- status:
124
- code: 204
125
- message: NO CONTENT
126
- headers:
127
53
  content-length:
128
- - '0'
129
- content-type:
130
- - text/html; charset=utf-8
131
- date:
132
- - Thu, 28 Jun 2012 22:21:45 GMT
133
- server:
134
- - nginx/1.0.12
54
+ - '101'
135
55
  connection:
136
56
  - Close
137
57
  body:
138
58
  encoding: US-ASCII
139
- string: ''
59
+ string: ! '{"meta": {"limit": 20, "next": null, "offset": 0, "previous": null,
60
+ "total_count": 0}, "objects": []}'
140
61
  http_version: '1.1'
141
- recorded_at: Thu, 28 Jun 2012 22:23:58 GMT
62
+ recorded_at: Sat, 14 Jul 2012 15:17:07 GMT
142
63
  - request:
143
64
  method: get
144
- uri: https://bigml.io/andromeda/dataset?username=<USERNAME>&api_key=<API_KEY>
65
+ uri: https://bigml.io/dev/andromeda/dataset?username=<USERNAME>&api_key=<API_KEY>
145
66
  body:
146
67
  encoding: US-ASCII
147
68
  string: ''
@@ -156,11 +77,11 @@ http_interactions:
156
77
  content-type:
157
78
  - application/json; charset=utf-8
158
79
  date:
159
- - Thu, 28 Jun 2012 22:19:12 GMT
80
+ - Sat, 14 Jul 2012 15:16:05 GMT
160
81
  server:
161
82
  - nginx/1.0.12
162
- content-length:
163
- - '101'
83
+ transfer-encoding:
84
+ - chunked
164
85
  connection:
165
86
  - Close
166
87
  body:
@@ -168,5 +89,5 @@ http_interactions:
168
89
  string: ! '{"meta": {"limit": 20, "next": null, "offset": 0, "previous": null,
169
90
  "total_count": 0}, "objects": []}'
170
91
  http_version: '1.1'
171
- recorded_at: Thu, 28 Jun 2012 22:23:59 GMT
92
+ recorded_at: Sat, 14 Jul 2012 15:17:08 GMT
172
93
  recorded_with: VCR 2.2.2
@@ -2,7 +2,7 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: get
5
- uri: https://bigml.io/andromeda/source?username=<USERNAME>&api_key=<API_KEY>
5
+ uri: https://bigml.io/dev/andromeda/source?username=<USERNAME>&api_key=<API_KEY>
6
6
  body:
7
7
  encoding: US-ASCII
8
8
  string: ''
@@ -17,36 +17,37 @@ http_interactions:
17
17
  content-type:
18
18
  - application/json; charset=utf-8
19
19
  date:
20
- - Thu, 28 Jun 2012 22:21:19 GMT
20
+ - Sat, 14 Jul 2012 15:12:52 GMT
21
21
  server:
22
22
  - nginx/1.0.12
23
23
  content-length:
24
- - '1280'
24
+ - '1293'
25
25
  connection:
26
26
  - Close
27
27
  body:
28
28
  encoding: US-ASCII
29
29
  string: ! '{"meta": {"limit": 20, "next": null, "offset": 0, "previous": null,
30
30
  "total_count": 1}, "objects": [{"category": 0, "code": 200, "content_type":
31
- "application/octet-stream", "created": "2012-06-28T22:26:13.480000", "credits":
32
- 0.0, "description": "", "fields": {"000000": {"column_number": 0, "name":
33
- "sepal length", "optype": "numeric"}, "000001": {"column_number": 1, "name":
34
- "sepal width", "optype": "numeric"}, "000002": {"column_number": 2, "name":
35
- "petal length", "optype": "numeric"}, "000003": {"column_number": 3, "name":
36
- "petal width", "optype": "numeric"}, "000004": {"column_number": 4, "name":
37
- "species", "optype": "categorical"}}, "file_name": "iris.csv", "md5": "d1175c032e1042bec7f974c91e4a65ae",
38
- "name": "iris.csv", "number_of_datasets": 0, "number_of_models": 0, "number_of_predictions":
39
- 0, "private": true, "resource": "source/4fecda0515526875f800331e", "size":
40
- 4608, "source_parser": {"header": true, "locale": "en_US", "missing_tokens":
41
- ["", "N/A", "n/a", "NULL", "null", "-", "#DIV/0", "#REF!", "#NAME?", "NIL",
42
- "nil", "NA", "na", "#VALUE!", "#NULL!", "NaN", "#N/A", "#NUM!", "?"], "quote":
43
- "\"", "separator": ","}, "status": {"code": 5, "elapsed": 88, "message": "The
44
- source has been created"}, "tags": [], "type": 0, "updated": "2012-06-28T22:25:28.018000"}]}'
31
+ "application/octet-stream", "created": "2012-07-14T15:19:26.085000", "credits":
32
+ 0.0, "description": "", "dev": true, "fields": {"000000": {"column_number":
33
+ 0, "name": "sepal length", "optype": "numeric"}, "000001": {"column_number":
34
+ 1, "name": "sepal width", "optype": "numeric"}, "000002": {"column_number":
35
+ 2, "name": "petal length", "optype": "numeric"}, "000003": {"column_number":
36
+ 3, "name": "petal width", "optype": "numeric"}, "000004": {"column_number":
37
+ 4, "name": "species", "optype": "categorical"}}, "file_name": "iris.csv",
38
+ "md5": "d1175c032e1042bec7f974c91e4a65ae", "name": "iris.csv", "number_of_datasets":
39
+ 0, "number_of_models": 0, "number_of_predictions": 0, "private": true, "resource":
40
+ "source/50018dfe1552681ee400000b", "size": 4608, "source_parser": {"header":
41
+ true, "locale": "en_US", "missing_tokens": ["", "N/A", "n/a", "NULL", "null",
42
+ "-", "#DIV/0", "#REF!", "#NAME?", "NIL", "nil", "NA", "na", "#VALUE!", "#NULL!",
43
+ "NaN", "#N/A", "#NUM!", "?"], "quote": "\"", "separator": ","}, "status":
44
+ {"code": 5, "elapsed": 82, "message": "The source has been created"}, "tags":
45
+ [], "type": 0, "updated": "2012-07-14T15:18:24.901000"}]}'
45
46
  http_version: '1.1'
46
- recorded_at: Thu, 28 Jun 2012 22:26:06 GMT
47
+ recorded_at: Sat, 14 Jul 2012 15:18:55 GMT
47
48
  - request:
48
49
  method: delete
49
- uri: https://bigml.io/andromeda/source/4fecda0515526875f800331e?username=<USERNAME>&api_key=<API_KEY>
50
+ uri: https://bigml.io/dev/andromeda/source/50018dfe1552681ee400000b?username=<USERNAME>&api_key=<API_KEY>
50
51
  body:
51
52
  encoding: US-ASCII
52
53
  string: ''
@@ -63,7 +64,7 @@ http_interactions:
63
64
  content-type:
64
65
  - text/html; charset=utf-8
65
66
  date:
66
- - Thu, 28 Jun 2012 22:23:55 GMT
67
+ - Sat, 14 Jul 2012 15:17:58 GMT
67
68
  server:
68
69
  - nginx/1.0.12
69
70
  connection:
@@ -72,10 +73,10 @@ http_interactions:
72
73
  encoding: US-ASCII
73
74
  string: ''
74
75
  http_version: '1.1'
75
- recorded_at: Thu, 28 Jun 2012 22:26:08 GMT
76
+ recorded_at: Sat, 14 Jul 2012 15:19:01 GMT
76
77
  - request:
77
78
  method: get
78
- uri: https://bigml.io/andromeda/dataset?username=<USERNAME>&api_key=<API_KEY>
79
+ uri: https://bigml.io/dev/andromeda/dataset?username=<USERNAME>&api_key=<API_KEY>
79
80
  body:
80
81
  encoding: US-ASCII
81
82
  string: ''
@@ -90,7 +91,7 @@ http_interactions:
90
91
  content-type:
91
92
  - application/json; charset=utf-8
92
93
  date:
93
- - Thu, 28 Jun 2012 22:21:23 GMT
94
+ - Sat, 14 Jul 2012 15:12:59 GMT
94
95
  server:
95
96
  - nginx/1.0.12
96
97
  content-length:
@@ -102,10 +103,10 @@ http_interactions:
102
103
  string: ! '{"meta": {"limit": 20, "next": null, "offset": 0, "previous": null,
103
104
  "total_count": 0}, "objects": []}'
104
105
  http_version: '1.1'
105
- recorded_at: Thu, 28 Jun 2012 22:26:09 GMT
106
+ recorded_at: Sat, 14 Jul 2012 15:19:02 GMT
106
107
  - request:
107
108
  method: post
108
- uri: https://bigml.io/andromeda/source
109
+ uri: https://bigml.io/dev/andromeda/source
109
110
  body:
110
111
  encoding: US-ASCII
111
112
  string: ''
@@ -113,7 +114,7 @@ http_interactions:
113
114
  content-type:
114
115
  - multipart/form-data; boundary=-----------RubyMultipartPost
115
116
  content-length:
116
- - '5147'
117
+ - '5149'
117
118
  connection:
118
119
  - close
119
120
  response:
@@ -124,33 +125,33 @@ http_interactions:
124
125
  content-type:
125
126
  - application/json; charset=utf-8
126
127
  date:
127
- - Thu, 28 Jun 2012 22:23:58 GMT
128
+ - Sat, 14 Jul 2012 15:18:00 GMT
128
129
  location:
129
- - http://bigml.io/andromeda/source/4fecda1315526875f8003320
130
+ - http://bigml.io/andromeda/source/50018e0c155268794e000016
130
131
  server:
131
132
  - nginx/1.0.12
132
133
  content-length:
133
- - '567'
134
+ - '580'
134
135
  connection:
135
136
  - Close
136
137
  body:
137
138
  encoding: US-ASCII
138
139
  string: ! '{"category": 0, "code": 201, "content_type": "application/octet-stream",
139
- "created": "2012-06-28T22:26:27.886251", "credits": 0.0, "description": "",
140
- "file_name": "iris.csv", "md5": "d1175c032e1042bec7f974c91e4a65ae", "name":
141
- "iris.csv", "number_of_datasets": 0, "number_of_models": 0, "number_of_predictions":
142
- 0, "private": true, "resource": "source/4fecda1315526875f8003320", "size":
140
+ "created": "2012-07-14T15:19:40.726139", "credits": 0.0, "description": "",
141
+ "dev": true, "file_name": "iris.csv", "md5": "d1175c032e1042bec7f974c91e4a65ae",
142
+ "name": "iris.csv", "number_of_datasets": 0, "number_of_models": 0, "number_of_predictions":
143
+ 0, "private": true, "resource": "source/50018e0c155268794e000016", "size":
143
144
  4608, "source_parser": {}, "status": {"code": 1, "message": "The request has
144
145
  been queued and will be processed soon"}, "tags": [], "type": 0, "updated":
145
- "2012-06-28T22:26:27.886278"}'
146
+ "2012-07-14T15:19:40.726170"}'
146
147
  http_version: '1.1'
147
- recorded_at: Thu, 28 Jun 2012 22:26:11 GMT
148
+ recorded_at: Sat, 14 Jul 2012 15:19:03 GMT
148
149
  - request:
149
150
  method: post
150
- uri: https://bigml.io/andromeda/dataset?username=<USERNAME>&api_key=<API_KEY>
151
+ uri: https://bigml.io/dev/andromeda/dataset?username=<USERNAME>&api_key=<API_KEY>
151
152
  body:
152
153
  encoding: UTF-8
153
- string: ! '{"source":"source/4fecda1315526875f8003320"}'
154
+ string: ! '{"source":"source/50018e0c155268794e000016"}'
154
155
  headers:
155
156
  content-type:
156
157
  - application/json
@@ -164,37 +165,37 @@ http_interactions:
164
165
  content-type:
165
166
  - application/json; charset=utf-8
166
167
  date:
167
- - Thu, 28 Jun 2012 22:21:27 GMT
168
+ - Sat, 14 Jul 2012 15:13:03 GMT
168
169
  location:
169
- - http://bigml.io/andromeda/dataset/4fecd9e4035d0741f000335b
170
+ - http://bigml.io/andromeda/dataset/50018e0e1552681d6800001a
170
171
  server:
171
172
  - nginx/1.0.12
172
173
  content-length:
173
- - '921'
174
+ - '934'
174
175
  connection:
175
176
  - Close
176
177
  body:
177
178
  encoding: US-ASCII
178
- string: ! '{"category": 0, "code": 201, "columns": 5, "created": "2012-06-28T22:25:40.755873",
179
- "credits": 0.00439453125, "description": "", "fields": {"000000": {"column_number":
180
- 0, "name": "sepal length", "optype": "numeric"}, "000001": {"column_number":
181
- 1, "name": "sepal width", "optype": "numeric"}, "000002": {"column_number":
182
- 2, "name": "petal length", "optype": "numeric"}, "000003": {"column_number":
183
- 3, "name": "petal width", "optype": "numeric"}, "000004": {"column_number":
184
- 4, "name": "species", "optype": "categorical"}}, "locale": "en_US", "name":
185
- "iris'' dataset", "number_of_models": 0, "number_of_predictions": 0, "private":
186
- true, "resource": "dataset/4fecd9e4035d0741f000335b", "rows": 0, "size": 4608,
187
- "source": "source/4fecda1315526875f8003320", "source_status": true, "status":
188
- {"code": 1, "message": "The dataset is being processed and will be created
189
- soon"}, "tags": [], "updated": "2012-06-28T22:25:40.755900"}'
179
+ string: ! '{"category": 0, "code": 201, "columns": 5, "created": "2012-07-14T15:19:42.928241",
180
+ "credits": 0.00439453125, "description": "", "dev": true, "fields": {"000000":
181
+ {"column_number": 0, "name": "sepal length", "optype": "numeric"}, "000001":
182
+ {"column_number": 1, "name": "sepal width", "optype": "numeric"}, "000002":
183
+ {"column_number": 2, "name": "petal length", "optype": "numeric"}, "000003":
184
+ {"column_number": 3, "name": "petal width", "optype": "numeric"}, "000004":
185
+ {"column_number": 4, "name": "species", "optype": "categorical"}}, "locale":
186
+ "en_US", "name": "iris'' dataset", "number_of_models": 0, "number_of_predictions":
187
+ 0, "private": true, "resource": "dataset/50018e0e1552681d6800001a", "rows":
188
+ 0, "size": 4608, "source": "source/50018e0c155268794e000016", "source_status":
189
+ true, "status": {"code": 1, "message": "The dataset is being processed and
190
+ will be created soon"}, "tags": [], "updated": "2012-07-14T15:19:42.928275"}'
190
191
  http_version: '1.1'
191
- recorded_at: Thu, 28 Jun 2012 22:26:13 GMT
192
+ recorded_at: Sat, 14 Jul 2012 15:19:06 GMT
192
193
  - request:
193
194
  method: post
194
- uri: https://bigml.io/andromeda/model?username=<USERNAME>&api_key=<API_KEY>
195
+ uri: https://bigml.io/dev/andromeda/model?username=<USERNAME>&api_key=<API_KEY>
195
196
  body:
196
197
  encoding: UTF-8
197
- string: ! '{"dataset":"dataset/4fecd9e4035d0741f000335b"}'
198
+ string: ! '{"dataset":"dataset/50018e0e1552681d6800001a"}'
198
199
  headers:
199
200
  content-type:
200
201
  - application/json
@@ -208,25 +209,26 @@ http_interactions:
208
209
  content-type:
209
210
  - application/json; charset=utf-8
210
211
  date:
211
- - Thu, 28 Jun 2012 22:24:02 GMT
212
+ - Sat, 14 Jul 2012 15:18:04 GMT
212
213
  location:
213
- - http://bigml.io/andromeda/model/4fecd9e6035d0741f000335e
214
+ - http://bigml.io/andromeda/model/50018dd0035d0741ca000012
214
215
  server:
215
216
  - nginx/1.0.12
216
217
  content-length:
217
- - '691'
218
+ - '704'
218
219
  connection:
219
220
  - Close
220
221
  body:
221
222
  encoding: US-ASCII
222
- string: ! '{"category": 0, "code": 201, "columns": 5, "created": "2012-06-28T22:25:42.532787",
223
- "credits": 0.017578125, "dataset": "dataset/4fecd9e4035d0741f000335b", "dataset_status":
224
- true, "description": "", "holdout": 0.0, "input_fields": [], "locale": "en_US",
225
- "max_columns": 5, "max_rows": 150, "name": "iris'' dataset model", "number_of_predictions":
226
- 0, "objective_fields": [], "private": true, "range": [1, 150], "resource":
227
- "model/4fecd9e6035d0741f000335e", "rows": 150, "size": 4608, "source": "source/4fecda1315526875f8003320",
228
- "source_status": true, "status": {"code": 1, "message": "The model is being
229
- processed and will be created soon"}, "tags": [], "updated": "2012-06-28T22:25:42.532812"}'
223
+ string: ! '{"category": 0, "code": 201, "columns": 5, "created": "2012-07-14T15:18:40.347897",
224
+ "credits": 0.017578125, "dataset": "dataset/50018e0e1552681d6800001a", "dataset_status":
225
+ true, "description": "", "dev": true, "holdout": 0.0, "input_fields": [],
226
+ "locale": "en_US", "max_columns": 5, "max_rows": 150, "name": "iris'' dataset
227
+ model", "number_of_predictions": 0, "objective_fields": [], "private": true,
228
+ "range": [1, 150], "resource": "model/50018dd0035d0741ca000012", "rows": 150,
229
+ "size": 4608, "source": "source/50018e0c155268794e000016", "source_status":
230
+ true, "status": {"code": 1, "message": "The model is being processed and will
231
+ be created soon"}, "tags": [], "updated": "2012-07-14T15:18:40.347920"}'
230
232
  http_version: '1.1'
231
- recorded_at: Thu, 28 Jun 2012 22:26:15 GMT
233
+ recorded_at: Sat, 14 Jul 2012 15:19:07 GMT
232
234
  recorded_with: VCR 2.2.2