runapi-minimax-h3 0.1.1 → 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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 076bab1bebdfc29bcf6e10073cd559981b5a4b86c87d93fccde2b09e6297e02e
4
- data.tar.gz: faf6feded26a0fd73015d8a76db2465a9783f9407ccf5928ff0e355b6c6ec897
3
+ metadata.gz: 861d9293430ca29136b0f65d9cd43954b62e3e984497b6c3c524a1b7b6cdc522
4
+ data.tar.gz: f268cd83d3639b8805002a39eb4d05389b9a9056c5c9a9c8d7de9ea888290f7d
5
5
  SHA512:
6
- metadata.gz: 39449c84aa1c084fe846948a8c09ee8bec9c1035fb68641ed586623ebc2cff8c987e970e7b9ac10187fd4aa30c5c06c65721487f8095723c0863fa966a68dc10
7
- data.tar.gz: 7a79314de5ecdb81610a2c1e06013a37812971a9ae408bd661d6496dec4b5b352c700451df2d2376eb40e69f2956114a77d36027bce8e4bf0c1d85f70c3b8a0c
6
+ metadata.gz: 2c03b6aabe63c0eccb76117ee967c5fb5eb1a91abf03db38e2a7aa36af7873d6a05e29ccd78639c355f9a16db02fd5e13d26220afb3c76705912f2711d654d02
7
+ data.tar.gz: df46040c19cb0b74383a86b1d7073f525a4f8058dfeaddf97ed2fef555d3ba93ce90ee3b5a8134b15314b8adc136b603324223d94e78e71d2a6f21d23e5c59d9
@@ -32,7 +32,6 @@ module RunApi
32
32
  # @return [RunApi::MiniMaxH3::Types::VideoTaskResponse] task creation result with id
33
33
  def create(options: nil, **params)
34
34
  params = compact_params(params)
35
- validate_params!(params)
36
35
  request(:post, ENDPOINT, body: params, options: options)
37
36
  end
38
37
 
@@ -43,12 +42,6 @@ module RunApi
43
42
  def get(id, options: nil)
44
43
  request(:get, "#{ENDPOINT}/#{id}", options: options)
45
44
  end
46
-
47
- private
48
-
49
- def validate_params!(params)
50
- validate_contract!(CONTRACT["image-to-video"], params)
51
- end
52
45
  end
53
46
  end
54
47
  end
@@ -32,7 +32,6 @@ module RunApi
32
32
  # @return [RunApi::MiniMaxH3::Types::VideoTaskResponse] task creation result with id
33
33
  def create(options: nil, **params)
34
34
  params = compact_params(params)
35
- validate_params!(params)
36
35
  request(:post, ENDPOINT, body: params, options: options)
37
36
  end
38
37
 
@@ -43,12 +42,6 @@ module RunApi
43
42
  def get(id, options: nil)
44
43
  request(:get, "#{ENDPOINT}/#{id}", options: options)
45
44
  end
46
-
47
- private
48
-
49
- def validate_params!(params)
50
- validate_contract!(CONTRACT["text-to-video"], params)
51
- end
52
45
  end
53
46
  end
54
47
  end
@@ -2,7 +2,6 @@
2
2
 
3
3
  require "runapi/core"
4
4
  require_relative "minimax_h3/types"
5
- require_relative "minimax_h3/contract_gen"
6
5
  require_relative "minimax_h3/resources/text_to_video"
7
6
  require_relative "minimax_h3/resources/image_to_video"
8
7
  require_relative "minimax_h3/client"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: runapi-minimax-h3
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - RunAPI
@@ -15,14 +15,14 @@ dependencies:
15
15
  requirements:
16
16
  - - "~>"
17
17
  - !ruby/object:Gem::Version
18
- version: 0.4.0
18
+ version: 0.6.0
19
19
  type: :runtime
20
20
  prerelease: false
21
21
  version_requirements: !ruby/object:Gem::Requirement
22
22
  requirements:
23
23
  - - "~>"
24
24
  - !ruby/object:Gem::Version
25
- version: 0.4.0
25
+ version: 0.6.0
26
26
  description: Use `runapi-minimax-h3` for MiniMax H3 video tasks in Ruby.
27
27
  email:
28
28
  - contact@runapi.ai
@@ -36,7 +36,6 @@ files:
36
36
  - lib/runapi-minimax-h3.rb
37
37
  - lib/runapi/minimax_h3.rb
38
38
  - lib/runapi/minimax_h3/client.rb
39
- - lib/runapi/minimax_h3/contract_gen.rb
40
39
  - lib/runapi/minimax_h3/resources/image_to_video.rb
41
40
  - lib/runapi/minimax_h3/resources/text_to_video.rb
42
41
  - lib/runapi/minimax_h3/types.rb
@@ -64,7 +63,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
64
63
  - !ruby/object:Gem::Version
65
64
  version: '0'
66
65
  requirements: []
67
- rubygems_version: 4.0.10
66
+ rubygems_version: 3.6.9
68
67
  specification_version: 4
69
68
  summary: MiniMax H3 API Ruby SDK for RunAPI
70
69
  test_files: []
@@ -1,90 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module RunApi
4
- module MiniMaxH3
5
- CONTRACT = {
6
- "image-to-video" => {
7
- "models" => ["minimax-h3"],
8
- "fields_by_model" => {
9
- "minimax-h3" => {
10
- "duration_seconds" => {
11
- "enum" => [4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15],
12
- "type" => "integer"
13
- },
14
- "model" => {
15
- "required" => true
16
- },
17
- "output_resolution" => {
18
- "enum" => ["768p", "2k"]
19
- },
20
- "prompt" => {
21
- "required" => true,
22
- "min" => 1,
23
- "max" => 7000,
24
- "length" => true
25
- }
26
- }
27
- },
28
- "rules" => [{
29
- "required_any" => ["first_frame_image_url", "last_frame_image_url"]
30
- }]
31
- },
32
- "text-to-video" => {
33
- "models" => ["minimax-h3"],
34
- "fields_by_model" => {
35
- "minimax-h3" => {
36
- "aspect_ratio" => {
37
- "enum" => ["adaptive", "21:9", "16:9", "4:3", "1:1", "3:4", "9:16"]
38
- },
39
- "duration_seconds" => {
40
- "enum" => [4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15],
41
- "type" => "integer"
42
- },
43
- "model" => {
44
- "required" => true
45
- },
46
- "output_resolution" => {
47
- "enum" => ["768p", "2k"]
48
- },
49
- "prompt" => {
50
- "required" => true,
51
- "min" => 1,
52
- "max" => 7000,
53
- "length" => true
54
- },
55
- "reference_audio_urls" => {
56
- "max_items" => 3
57
- },
58
- "reference_image_urls" => {
59
- "max_items" => 9
60
- },
61
- "reference_video_urls" => {
62
- "max_items" => 3
63
- }
64
- }
65
- },
66
- "rules" => [{
67
- "when" => {
68
- "reference_audio_urls" => {
69
- "present" => true
70
- }
71
- },
72
- "required_any" => ["reference_image_urls", "reference_video_urls"]
73
- }, {
74
- "enum" => {
75
- "aspect_ratio" => ["21:9", "16:9", "4:3", "1:1", "3:4", "9:16"]
76
- },
77
- "when" => {
78
- "reference_image_urls" => {
79
- "present" => false
80
- },
81
- "reference_video_urls" => {
82
- "present" => false
83
- }
84
- },
85
- "required" => ["aspect_ratio"]
86
- }]
87
- }
88
- }.freeze
89
- end
90
- end