sentencepiece 0.1.0 → 0.2.0
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/CHANGELOG.md +5 -3
- data/ext/sentencepiece/extconf.rb +5 -1
- data/ext/sentencepiece/sentencepiece.cpp +1 -1
- data/ext/sentencepiece/sentencepiece.hpp +2 -1
- data/lib/sentencepiece/version.rb +1 -1
- metadata +3 -6
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 45cc838c2108753b87e03e3aee4bf3665f1e8c6e0cd407e5a68355b44657c582
|
|
4
|
+
data.tar.gz: 14d29d47f2a78b57218ceaf45c12a30de270f000c5d6d756b6b66a767a2ee128
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: ac0b780ec734901f030bbfdcf91949401b40064d89480fa54d303d7d83f707e42e0ba897cf342ea4650402b350deac2da4c1017cac7c278adb1272e5cee0834e
|
|
7
|
+
data.tar.gz: b03e10826137a4d3d1002906af0e8e46014eafed08da76fb5494e7b5311deaf002b40b7771b7299ef1b39cb2349e1fa9f5f3262020479d2655a2ede9c3db4f03
|
data/CHANGELOG.md
CHANGED
|
@@ -1,11 +1,13 @@
|
|
|
1
|
-
## [
|
|
1
|
+
## [[0.2.0](https://github.com/yoshoku/sentencepiece.rb/compare/v0.1.0...v0.2.0)] - 2025-12-29
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
- Change to specify `c++17` with -std option as recent sentencepiece uses `std::string_view`.
|
|
4
|
+
|
|
5
|
+
## [[0.1.0](https://github.com/yoshoku/sentencepiece.rb/compare/v0.0.2...v0.1.0)] - 2023-03-26
|
|
4
6
|
|
|
5
7
|
- Add API documentation.
|
|
6
8
|
- Add type signatures.
|
|
7
9
|
|
|
8
|
-
## [0.0.2] - 2023-03-26
|
|
10
|
+
## [[0.0.2](https://github.com/yoshoku/sentencepiece.rb/compare/v0.0.1...v0.0.2)] - 2023-03-26
|
|
9
11
|
|
|
10
12
|
- Add SentencePieceTrainer class.
|
|
11
13
|
- Add some encoding and decoding methods to SentencePieceProcessor.
|
|
@@ -9,6 +9,10 @@ abort 'libsentencepiece_train is not found.' unless have_library('sentencepiece_
|
|
|
9
9
|
# abort 'sentencepiece_processor.h is not found.' unless have_header('sentencepiece_processor.h')
|
|
10
10
|
# abort 'sentencepiece_trainer.h is not found.' unless have_header('sentencepiece_trainer.h')
|
|
11
11
|
|
|
12
|
-
$CXXFLAGS <<
|
|
12
|
+
$CXXFLAGS << if /mswin/ =~ RUBY_PLATFORM
|
|
13
|
+
'/std:c++17'
|
|
14
|
+
else
|
|
15
|
+
' -std=c++17'
|
|
16
|
+
end
|
|
13
17
|
|
|
14
18
|
create_makefile('sentencepiece/sentencepiece')
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* sentencepiece.rb provides Ruby bindings for the SentencePiece.
|
|
3
3
|
*
|
|
4
|
-
* Copyright (c) 2023 Atsushi Tatsuma
|
|
4
|
+
* Copyright (c) 2023-2025 Atsushi Tatsuma
|
|
5
5
|
*
|
|
6
6
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
7
7
|
* you may not use this file except in compliance with the License.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* sentencepiece.rb provides Ruby bindings for the SentencePiece.
|
|
3
3
|
*
|
|
4
|
-
* Copyright (c) 2023 Atsushi Tatsuma
|
|
4
|
+
* Copyright (c) 2023-2025 Atsushi Tatsuma
|
|
5
5
|
*
|
|
6
6
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
7
7
|
* you may not use this file except in compliance with the License.
|
|
@@ -79,6 +79,7 @@ public:
|
|
|
79
79
|
rb_define_method(rb_cSentencePieceProcessor, "bos_id", RUBY_METHOD_FUNC(_sentencepiece_processor_bos_id), 0);
|
|
80
80
|
rb_define_method(rb_cSentencePieceProcessor, "eos_id", RUBY_METHOD_FUNC(_sentencepiece_processor_eos_id), 0);
|
|
81
81
|
rb_define_method(rb_cSentencePieceProcessor, "pad_id", RUBY_METHOD_FUNC(_sentencepiece_processor_pad_id), 0);
|
|
82
|
+
rb_define_alias(rb_cSentencePieceProcessor, "vocab_size", "piece_size");
|
|
82
83
|
return rb_cSentencePieceProcessor;
|
|
83
84
|
};
|
|
84
85
|
|
metadata
CHANGED
|
@@ -1,14 +1,13 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: sentencepiece
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.2.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- yoshoku
|
|
8
|
-
autorequire:
|
|
9
8
|
bindir: exe
|
|
10
9
|
cert_chain: []
|
|
11
|
-
date:
|
|
10
|
+
date: 1980-01-02 00:00:00.000000000 Z
|
|
12
11
|
dependencies: []
|
|
13
12
|
description: |
|
|
14
13
|
sentencepiece.rb provides Ruby bindings for the SentencePiece,
|
|
@@ -38,7 +37,6 @@ metadata:
|
|
|
38
37
|
changelog_uri: https://github.com/yoshoku/sentencepiece.rb/blob/main/CHANGELOG.md
|
|
39
38
|
documentation_uri: https://yoshoku.github.io/sentencepiece.rb/doc/
|
|
40
39
|
rubygems_mfa_required: 'true'
|
|
41
|
-
post_install_message:
|
|
42
40
|
rdoc_options: []
|
|
43
41
|
require_paths:
|
|
44
42
|
- lib
|
|
@@ -53,8 +51,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
53
51
|
- !ruby/object:Gem::Version
|
|
54
52
|
version: '0'
|
|
55
53
|
requirements: []
|
|
56
|
-
rubygems_version:
|
|
57
|
-
signing_key:
|
|
54
|
+
rubygems_version: 4.0.3
|
|
58
55
|
specification_version: 4
|
|
59
56
|
summary: Ruby bindings for the SentencePiece
|
|
60
57
|
test_files: []
|