open_router_enhanced 1.0.0 → 1.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: 0e01a3e4ebadd327148dc9f04efacd94166195e789adb0f77d20dbc83f70b234
4
- data.tar.gz: 902c36d9a9d243e63ab8065456526875d19bc268450720e1ee29ee24493e7e35
3
+ metadata.gz: 1e39d5924a6388355a4ecae7a76933bf429546a3a5da1975d5dd020804735d24
4
+ data.tar.gz: 220e9504b58ad511e971a8c4a13939edef2c390f0ffeb031e21dfdb30ce78941
5
5
  SHA512:
6
- metadata.gz: de0e475b38181bec11bcde85a9a571eec12306eb5a755a70fae173d4743e28ee59d232adf7d3e42efc7b2693500947678848381b36b1ae30b47bdf479e51dca0
7
- data.tar.gz: f91b409a150fae9af10bedddd9d0c22b6c3683096e9125e4f1310434795b0fea537ea39c1fbdf923e523e61fdc3a5ac9d9b8727e9b78c6d676e0a07d96a5663c
6
+ metadata.gz: 61f753aedc0057758a7cb8310ba06b5751da07ca17ed6bd433473e8ce36184286a37060cd32b2595ac9a8b5e9c798cd2db078ae5c7ddf2232c4b6c271d44623a
7
+ data.tar.gz: bb9f8c9122ddc7fc1c850b34a76ee9e209ca14ff95ff4fe2dbd68b8fccdf10021f78111cd994c0e0f3a163ee61512434b39410227ec818cbf52a1cf22aac5ff6
data/CHANGELOG.md CHANGED
@@ -1,5 +1,41 @@
1
1
  ## [Unreleased]
2
2
 
3
+ ## [1.2.0] - 2025-12-24
4
+
5
+ ### Added
6
+ - **Responses API**: Full support for OpenRouter's Responses API Beta (`/api/v1/responses`)
7
+ - Simple string or structured array input
8
+ - Reasoning with configurable effort levels (`minimal`, `low`, `medium`, `high`)
9
+ - `ResponsesResponse` wrapper with convenient accessors
10
+ - **Responses API Tool Calling**: Complete function calling support for Responses API
11
+ - `ResponsesToolCall` and `ResponsesToolResult` classes
12
+ - `execute_tool_calls` for easy tool execution with blocks
13
+ - `build_follow_up_input` for multi-turn tool conversations
14
+ - `tool_choice` parameter (`auto`, `required`, `none`)
15
+ - Automatic format conversion from Chat Completions tool format
16
+ - **Shared Tool Call Infrastructure**: Extracted `ToolCallBase` and `ToolResultBase` modules
17
+ - DRY shared behavior for argument parsing and execution
18
+ - Consistent interface across Chat Completions and Responses APIs
19
+
20
+ ### Documentation
21
+ - New `docs/responses_api.md` with comprehensive Responses API guide
22
+ - Tool calling examples with Tool DSL and hash formats
23
+
24
+ ## [1.1.0] - 2025-12-24
25
+
26
+ ### Added
27
+ - **Native Response Healing Plugin**: Automatic server-side JSON healing for structured outputs via OpenRouter's `response-healing` plugin (free, <1ms latency)
28
+ - **Plugins Parameter**: Support for OpenRouter plugins (`web-search`, `pdf-inputs`, `response-healing`) via new `plugins:` parameter
29
+ - **Prediction Parameter**: Latency optimization via `prediction:` parameter for predictable outputs
30
+ - **Auto Native Healing**: Automatically enables `response-healing` plugin when using structured outputs (configurable via `auto_native_healing` setting)
31
+
32
+ ### Changed
33
+ - Enhanced structured output workflow: native healing catches syntax errors server-side, client-side healing handles schema validation
34
+
35
+ ### Configuration
36
+ - New `auto_native_healing` config option (default: `true`)
37
+ - Environment variable: `OPENROUTER_AUTO_NATIVE_HEALING`
38
+
3
39
  ## [1.0.0] - 2025-10-07
4
40
 
5
41
  ### Major Features
data/Gemfile.lock CHANGED
@@ -1,94 +1,94 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- open_router_enhanced (1.0.0)
5
- activesupport (>= 6.0)
6
- dotenv (>= 2)
7
- faraday (>= 1)
8
- faraday-multipart (>= 1)
4
+ open_router_enhanced (1.2.0)
5
+ activesupport (>= 6.0, < 9.0)
6
+ dotenv (>= 2.0, < 4.0)
7
+ faraday (>= 1.0, < 3.0)
8
+ faraday-multipart (>= 1.0, < 2.0)
9
9
  json-schema (~> 4.0)
10
10
 
11
11
  GEM
12
12
  remote: https://rubygems.org/
13
13
  specs:
14
- activesupport (8.0.2.1)
14
+ activesupport (8.1.1)
15
15
  base64
16
- benchmark (>= 0.3)
17
16
  bigdecimal
18
17
  concurrent-ruby (~> 1.0, >= 1.3.1)
19
18
  connection_pool (>= 2.2.5)
20
19
  drb
21
20
  i18n (>= 1.6, < 2)
21
+ json
22
22
  logger (>= 1.4.2)
23
23
  minitest (>= 5.1)
24
24
  securerandom (>= 0.3)
25
25
  tzinfo (~> 2.0, >= 2.0.5)
26
26
  uri (>= 0.13.1)
27
- addressable (2.8.7)
28
- public_suffix (>= 2.0.2, < 7.0)
27
+ addressable (2.8.8)
28
+ public_suffix (>= 2.0.2, < 8.0)
29
29
  ast (2.4.3)
30
30
  base64 (0.3.0)
31
- benchmark (0.4.1)
32
- bigdecimal (3.2.2)
31
+ bigdecimal (4.0.1)
33
32
  coderay (1.1.3)
34
- concurrent-ruby (1.3.5)
35
- connection_pool (2.5.3)
36
- crack (1.0.0)
33
+ concurrent-ruby (1.3.6)
34
+ connection_pool (3.0.2)
35
+ crack (1.0.1)
37
36
  bigdecimal
38
37
  rexml
39
38
  diff-lcs (1.6.2)
40
- dotenv (3.1.8)
39
+ dotenv (3.2.0)
41
40
  drb (2.2.3)
42
- faraday (2.13.4)
41
+ faraday (2.14.0)
43
42
  faraday-net_http (>= 2.0, < 3.5)
44
43
  json
45
44
  logger
46
45
  faraday-multipart (1.1.1)
47
46
  multipart-post (~> 2.0)
48
- faraday-net_http (3.4.1)
49
- net-http (>= 0.5.0)
50
- hashdiff (1.2.0)
51
- i18n (1.14.7)
47
+ faraday-net_http (3.4.2)
48
+ net-http (~> 0.5)
49
+ hashdiff (1.2.1)
50
+ i18n (1.14.8)
52
51
  concurrent-ruby (~> 1.0)
53
- json (2.13.2)
52
+ json (2.18.0)
54
53
  json-schema (4.3.1)
55
54
  addressable (>= 2.8)
56
55
  language_server-protocol (3.17.0.5)
57
56
  lint_roller (1.1.0)
58
57
  logger (1.7.0)
59
58
  method_source (1.1.0)
60
- minitest (5.25.5)
59
+ minitest (6.0.0)
60
+ prism (~> 1.5)
61
61
  multipart-post (2.4.1)
62
- net-http (0.6.0)
63
- uri
62
+ net-http (0.9.1)
63
+ uri (>= 0.11.1)
64
64
  parallel (1.27.0)
65
- parser (3.3.9.0)
65
+ parser (3.3.10.0)
66
66
  ast (~> 2.4.1)
67
67
  racc
68
- prism (1.4.0)
68
+ prism (1.7.0)
69
69
  pry (0.15.2)
70
70
  coderay (~> 1.1)
71
71
  method_source (~> 1.0)
72
- public_suffix (6.0.2)
72
+ public_suffix (7.0.0)
73
73
  racc (1.8.1)
74
74
  rainbow (3.1.1)
75
- rake (13.3.0)
76
- regexp_parser (2.11.2)
77
- rexml (3.4.1)
78
- rspec (3.13.1)
75
+ rake (13.3.1)
76
+ regexp_parser (2.11.3)
77
+ rexml (3.4.4)
78
+ rspec (3.13.2)
79
79
  rspec-core (~> 3.13.0)
80
80
  rspec-expectations (~> 3.13.0)
81
81
  rspec-mocks (~> 3.13.0)
82
- rspec-core (3.13.5)
82
+ rspec-core (3.13.6)
83
83
  rspec-support (~> 3.13.0)
84
84
  rspec-expectations (3.13.5)
85
85
  diff-lcs (>= 1.2.0, < 2.0)
86
86
  rspec-support (~> 3.13.0)
87
- rspec-mocks (3.13.5)
87
+ rspec-mocks (3.13.7)
88
88
  diff-lcs (>= 1.2.0, < 2.0)
89
89
  rspec-support (~> 3.13.0)
90
- rspec-support (3.13.4)
91
- rubocop (1.79.2)
90
+ rspec-support (3.13.6)
91
+ rubocop (1.82.1)
92
92
  json (~> 2.3)
93
93
  language_server-protocol (~> 3.17.0.2)
94
94
  lint_roller (~> 1.1.0)
@@ -96,31 +96,29 @@ GEM
96
96
  parser (>= 3.3.0.2)
97
97
  rainbow (>= 2.2.2, < 4.0)
98
98
  regexp_parser (>= 2.9.3, < 3.0)
99
- rubocop-ast (>= 1.46.0, < 2.0)
99
+ rubocop-ast (>= 1.48.0, < 2.0)
100
100
  ruby-progressbar (~> 1.7)
101
101
  unicode-display_width (>= 2.4.0, < 4.0)
102
- rubocop-ast (1.46.0)
102
+ rubocop-ast (1.48.0)
103
103
  parser (>= 3.3.7.2)
104
104
  prism (~> 1.4)
105
105
  ruby-progressbar (1.13.0)
106
106
  securerandom (0.4.1)
107
107
  tzinfo (2.0.6)
108
108
  concurrent-ruby (~> 1.0)
109
- unicode-display_width (3.1.5)
110
- unicode-emoji (~> 4.0, >= 4.0.4)
111
- unicode-emoji (4.0.4)
112
- uri (1.0.3)
113
- vcr (6.3.1)
114
- base64
115
- webmock (3.25.1)
109
+ unicode-display_width (3.2.0)
110
+ unicode-emoji (~> 4.1)
111
+ unicode-emoji (4.2.0)
112
+ uri (1.1.1)
113
+ vcr (6.4.0)
114
+ webmock (3.26.1)
116
115
  addressable (>= 2.8.0)
117
116
  crack (>= 0.3.2)
118
117
  hashdiff (>= 0.4.0, < 2.0.0)
119
118
 
120
119
  PLATFORMS
121
- arm64-darwin-21
122
120
  arm64-darwin-24
123
- x86_64-linux
121
+ ruby
124
122
 
125
123
  DEPENDENCIES
126
124
  activesupport (>= 6.0)
@@ -135,4 +133,4 @@ DEPENDENCIES
135
133
  webmock (~> 3.19)
136
134
 
137
135
  BUNDLED WITH
138
- 2.4.12
136
+ 2.6.7