interscript 3.0.0 → 3.0.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a04dd91ecaf1ba6e202f6d61ddae77a1fa97afe3ae2f40874dac43142e09baa3
4
- data.tar.gz: 7315cdfb66bfae1620920ae97f3cc363ace436d8506c227dbb449a48cb7fac10
3
+ metadata.gz: 420389cb34a86a2f6b94abf9bd55367da2a92bea023426d45132e30cd14bb90d
4
+ data.tar.gz: 85dde2d6ac474fecfcb7cb27683f164727cb9aa83fb4c68b9c025e3437a2ec32
5
5
  SHA512:
6
- metadata.gz: df34de55722a54f9942b0d24eef322bc1b2e54fa4cb587249e98da56fb6bad21e839038922ca9555edbe0ccdb0f8a278dcbd15026dff3160e91ce5fd334c3220
7
- data.tar.gz: a88b209689466f418cd6af6c31cca544e656c4df98215120cdc2d1f5131aa8781c67803c3729da1aa3c7e7d8da47f438ccfee84203e3568f6c44c88843def7c2
6
+ metadata.gz: 86d6895fdefc229d99a4eb993d3aa32380dc72515d5fb8dce8757b5b636ffb1b39b0995e8592f6be27a0cbe84bebafff3e7265019dfc059089da08bec44dd39d
7
+ data.tar.gz: da833c4f4aa295e7f2d6c557908196c85eef26206bbd2ce89904a04ca5ca7eb0590d4b03bfb9b85334b07716f0617012b0117cb9e8234b37c25cd2820ee72b5a
@@ -14,7 +14,7 @@ module Interscript::ML
14
14
  EOS_ID = 1
15
15
  UNK_ID = 2
16
16
 
17
- DEFAULT_INDEX_URL = "https://github.com/interscript/interscript-ml/releases/download/index-v7/models-index.yaml"
17
+ DEFAULT_INDEX_URL = "https://github.com/interscript/interscript-models/releases/download/index-v8/models-index.yaml"
18
18
 
19
19
  class FormatError < StandardError; end
20
20
  class RegistryError < StandardError; end
@@ -27,12 +27,7 @@ module Interscript::ML
27
27
  # we use it to store the Secryst data we need. Otherwise, we try the following
28
28
  # paths:
29
29
 
30
- possible_paths = [
31
- "/var/lib/secryst",
32
- "/usr/local/share/secryst",
33
- "/usr/share/secryst",
34
- File.join(Dir.home, ".local/share/secryst")
35
- ]
30
+ possible_paths = candidate_paths
36
31
 
37
32
  # We find the first writable path to become the primary one. The remaining
38
33
  # ones will be used read-only if they exist
@@ -95,6 +90,13 @@ module Interscript::ML
95
90
  @preload_models.each { |i| locate(i) }
96
91
  end
97
92
 
93
+ def self.candidate_paths
94
+ [
95
+ File.join(Dir.home, ".local/share/interscript-ml"),
96
+ File.join(Dir.home, ".local/share/secryst") # legacy fallback
97
+ ]
98
+ end
99
+
98
100
  def locate(name)
99
101
  # Shortcut this if user gave a filename.
100
102
  return name if name =~ %r{[.\\/]}
@@ -1,3 +1,3 @@
1
1
  module Interscript
2
- VERSION = "3.0.0"
2
+ VERSION = "3.0.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: interscript
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.0
4
+ version: 3.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.