llm.rb 11.3.1 → 12.1.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.
Files changed (76) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +354 -2
  3. data/LICENSE +93 -17
  4. data/README.md +226 -616
  5. data/data/anthropic.json +322 -426
  6. data/data/bedrock.json +2634 -1144
  7. data/data/deepinfra.json +1513 -0
  8. data/data/deepseek.json +57 -28
  9. data/data/google.json +411 -771
  10. data/data/openai.json +1104 -771
  11. data/data/xai.json +141 -292
  12. data/data/zai.json +263 -141
  13. data/lib/llm/active_record/acts_as_agent.rb +3 -41
  14. data/lib/llm/active_record/acts_as_llm.rb +18 -0
  15. data/lib/llm/active_record.rb +3 -3
  16. data/lib/llm/agent.rb +25 -1
  17. data/lib/llm/context.rb +17 -5
  18. data/lib/llm/contract/completion.rb +2 -2
  19. data/lib/llm/json_adapter.rb +29 -3
  20. data/lib/llm/provider.rb +3 -3
  21. data/lib/llm/providers/deepinfra/audio.rb +66 -0
  22. data/lib/llm/providers/deepinfra/images.rb +90 -0
  23. data/lib/llm/providers/deepinfra/response_adapter.rb +36 -0
  24. data/lib/llm/providers/deepinfra.rb +100 -0
  25. data/lib/llm/providers/deepseek/images.rb +109 -0
  26. data/lib/llm/providers/deepseek/request_adapter.rb +32 -0
  27. data/lib/llm/providers/deepseek/response_adapter/image.rb +9 -0
  28. data/lib/llm/providers/deepseek/response_adapter.rb +29 -0
  29. data/lib/llm/providers/deepseek.rb +4 -2
  30. data/lib/llm/providers/google/request_adapter.rb +22 -5
  31. data/lib/llm/providers/google.rb +4 -4
  32. data/lib/llm/providers/llamacpp.rb +5 -5
  33. data/lib/llm/providers/openai/audio.rb +6 -2
  34. data/lib/llm/providers/openai/images.rb +9 -50
  35. data/lib/llm/providers/openai/request_adapter/respond.rb +38 -4
  36. data/lib/llm/providers/openai/response_adapter/audio.rb +5 -1
  37. data/lib/llm/providers/openai/response_adapter/completion.rb +1 -1
  38. data/lib/llm/providers/openai/response_adapter/image.rb +0 -4
  39. data/lib/llm/providers/openai/responses.rb +1 -0
  40. data/lib/llm/providers/openai/stream_parser.rb +5 -6
  41. data/lib/llm/providers/openai.rb +2 -2
  42. data/lib/llm/providers/xai/images.rb +49 -26
  43. data/lib/llm/providers/xai.rb +2 -2
  44. data/lib/llm/repl/input.rb +64 -0
  45. data/lib/llm/repl/status.rb +30 -0
  46. data/lib/llm/repl/stream.rb +46 -0
  47. data/lib/llm/repl/transcript.rb +61 -0
  48. data/lib/llm/repl/window.rb +107 -0
  49. data/lib/llm/repl.rb +78 -0
  50. data/lib/llm/response.rb +10 -0
  51. data/lib/llm/schema/leaf.rb +7 -1
  52. data/lib/llm/schema/renderer.rb +121 -0
  53. data/lib/llm/schema.rb +30 -0
  54. data/lib/llm/sequel/agent.rb +2 -43
  55. data/lib/llm/sequel/plugin.rb +25 -7
  56. data/lib/llm/tools/chdir.rb +23 -0
  57. data/lib/llm/tools/git.rb +41 -0
  58. data/lib/llm/tools/mkdir.rb +32 -0
  59. data/lib/llm/tools/pwd.rb +20 -0
  60. data/lib/llm/tools/read_file.rb +40 -0
  61. data/lib/llm/tools/rg.rb +46 -0
  62. data/lib/llm/tools/shell.rb +48 -0
  63. data/lib/llm/tools/swap_text.rb +25 -0
  64. data/lib/llm/tools/write_file.rb +24 -0
  65. data/lib/llm/tools.rb +5 -0
  66. data/lib/llm/tracer/telemetry.rb +4 -6
  67. data/lib/llm/tracer.rb +9 -21
  68. data/lib/llm/transport/execution.rb +16 -1
  69. data/lib/llm/transport/net_http_adapter.rb +1 -1
  70. data/lib/llm/uridata.rb +16 -0
  71. data/lib/llm/version.rb +1 -1
  72. data/lib/llm.rb +9 -0
  73. data/llm.gemspec +5 -18
  74. data/resources/deepdive.md +829 -263
  75. metadata +31 -18
  76. data/lib/llm/tracer/langsmith.rb +0 -144
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e3aad41c57654e1abef4c184da8904ae5840708e8f5ce937e1030279a5e5a240
4
- data.tar.gz: 9b03ac6a4f04190a57f2e4698eab923087febbab6a1ff8ad67f391fce4bd5c1e
3
+ metadata.gz: e4c7d2a7e0fd6a5b05cfdaaf2702f94f9a15d3e277739559f5cb676768fe6a9c
4
+ data.tar.gz: ad3081a38e1096459791ec6cffd1ae0a8550f5d4df2c6c95fd8842b78a0024f4
5
5
  SHA512:
6
- metadata.gz: f429a75d5b612eb27968b6e6451bd231f2191b5b955262503c68baa7ca27f289c01ad564558e82d7fcc732393f635c32caf883a36815b41d86f6c1289cfffb61
7
- data.tar.gz: 90924b997b5d47d74c3df6e303c890fb5d1a771bae10e63c349436bcbd061241604184f62df87cb2dee7d85405fbd53f08d279ef6b4d3a85a12b0d59b7377229
6
+ metadata.gz: 0e5a58f5b22d07b05d981423414de270b1ae760c7920452e736a55709c6c1eeee941407de8a8667365ee83943deeb0554d05bec5425b7132fe907dc62f349ffa
7
+ data.tar.gz: fabedc3aad36ba5cbaf7b126c55ddc3cbb428aadb3b2887a40e429daf35c65ff81a4d8c903583dea27c051d89f076d9d3446736e948954a6cef26065aebfa624
data/CHANGELOG.md CHANGED
@@ -1,6 +1,358 @@
1
- # Changelog
1
+ <p align="center">
2
+ <a href="https://r.uby.dev">
3
+ <img
4
+ src="https://github.com/r-uby-dev/llm.rb/raw/main/rubydev.svg"
5
+ width="400"
6
+ height="200"
7
+ border="0"
8
+ alt="a r.uby.dev project"
9
+ >
10
+ </a>
11
+ </p>
2
12
 
3
- ## Unreleased
13
+ > Changelog <br>
14
+ > a [r.uby.dev](https://r.uby.dev) project
15
+
16
+ ## What's next
17
+
18
+ Changes since `v12.1.0`.
19
+
20
+ ## v12.1.0
21
+
22
+ Changes since `v12.0.0`.
23
+
24
+ This release adds `LLM::Agent#repl` with a curses-based
25
+ interactive read-eval-print loop. It requires the optional
26
+ dependency `curses` and it is probably the most notable
27
+ feature in this release.
28
+
29
+ Multiple _opt-in_ tools have been added to the `llm/tools/*.rb`
30
+ directory. They serve as examples and as general-purpose tools
31
+ that happen to power the repository's agents.
32
+
33
+ The BSL license has been extended to grant additional free waivers
34
+ for non-profits, charities and for companies with 50 or less
35
+ employees.
36
+
37
+ Other changes include small-ish bug fixes. <br>
38
+ As always, see the changelog details for a thorough overview.
39
+
40
+ ### Add
41
+
42
+ * **Add `LLM::Agent#repl`** <br>
43
+ Add a curses-based read-eval-print loop for `LLM::Agent` that lets
44
+ developers interact with an agent after it has been set up or has
45
+ performed a task. It is similar to `binding.pry`: once you exit,
46
+ you can continue with the rest of your program. It requires the
47
+ `curses` gem.
48
+
49
+ * **Add `#tracer=` setter on Provider, Context and Agent** <br>
50
+ `LLM::Provider`, `LLM::Context` and `LLM::Agent` can now configure
51
+ the tracer after initialization via the `#tracer=` setter. It accepts
52
+ a subclass of `LLM::Tracer` or `nil` to disable the tracer.
53
+
54
+ * **Add `LLM::Tool::Shell`** <br>
55
+ Add a built-in shell tool that can run a command with arguments. <br>
56
+ It must be required explicitly with `require "llm/tools/shell"` and
57
+ requires the `test-cmd.rb` gem.
58
+
59
+ * **Add `LLM::Tool::ReadFile`** <br>
60
+ Add a built-in tool for reading the contents of a file, with optional
61
+ `start` and `stop` line offsets. <br>
62
+ It must be required explicitly with `require "llm/tools/read_file"`.
63
+
64
+ * **Add `LLM::Tool::Chdir`** <br>
65
+ Add a built-in tool for changing the current working directory. <br>
66
+ It must be required explicitly with `require "llm/tools/chdir"`.
67
+
68
+ * **Add `LLM::Tool::Git`** <br>
69
+ Add a built-in tool that can perform git actions (`log`, `diff`,
70
+ `show`, `commit`, `checkout`, `branch`). <br>
71
+ It must be required explicitly with `require "llm/tools/git"` and requires the `test-cmd.rb` gem.
72
+
73
+ * **Add `LLM::Tool::Rg`** <br>
74
+ Add a built-in tool that wraps the `rg` (ripgrep) command for
75
+ recursively searching the current directory for patterns. <br>
76
+ It must be required explicitly with `require "llm/tools/rg"` and requires the `test-cmd.rb` gem.
77
+
78
+ * **Add `LLM::Tool::SwapText`** <br>
79
+ Add a built-in tool that can replace an exact snippet of text in a
80
+ file with a new piece of text. <br>
81
+ It must be required explicitly with `require "llm/tools/swap_text"`.
82
+
83
+ * **Add `LLM::Tool::Pwd`** <br>
84
+ Add a built-in tool that returns the current working directory. <br>
85
+ It must be required explicitly with `require "llm/tools/pwd"`.
86
+
87
+ * **Add `LLM::Tool::WriteFile`** <br>
88
+ Add a built-in tool that can write a given string to a given file
89
+ path. <br>
90
+ It must be required explicitly with `require "llm/tools/write_file"`.
91
+
92
+ * **Add `LLM::Tool::Mkdir`** <br>
93
+ Add a built-in tool that can create a tree of new directories. <br>
94
+ It must be required explicitly with `require "llm/tools/mkdir"` and
95
+ requires the `test-cmd.rb` gem.
96
+
97
+ ### Change
98
+
99
+ * **Extend BSL additional use grant** <br>
100
+ The Business Source License additional use grant has been extended to
101
+ include non-profits, charities, and companies with 50 or fewer
102
+ employees, in addition to the existing personal, education, and
103
+ evaluation uses.
104
+
105
+ * **Change LlamaCpp default port (8080 => 8013)** <br>
106
+ The default port for the LlamaCpp provider has changed from `8080` to
107
+ `8013` since llamacpp itself defaults to that port.
108
+
109
+ * **Change LlamaCpp default model to `nil`** <br>
110
+ The default model for LlamaCpp is now `nil`, letting whatever model
111
+ is served by the llamacpp server act as the default. Previously it
112
+ defaulted to `qwen3`.
113
+
114
+ ### Fix
115
+
116
+ * **Fix `LLM::Agent.tools` Symbol resolution** <br>
117
+ When an agent defined tools via `tools :method_name`, the resolved
118
+ symbol was incorrectly forwarded as `[:method_name]` (an array) to
119
+ `LLM::Context`. This fix copies the same pattern used by other
120
+ attribute resolvers (e.g., `skills`) so a single Symbol is resolved
121
+ through the agent instance correctly.
122
+
123
+ * **Encode strings as UTF-8 in the JSON adapter** <br>
124
+ The `json` gem will reject BINARY-encoded strings from version 3 and
125
+ beyond. The `LLM::JSONAdapter.dump` method now walks serialized data
126
+ and encodes every string into UTF-8, using `String#scrub` to replace
127
+ bytes that are not valid UTF-8.
128
+
129
+ ## v12.0.0
130
+
131
+ Changes since `v11.3.1`.
132
+
133
+ This release relicenses the project under the Business Source License,
134
+ defaults OpenAI to the Responses API and gpt-image models, adds the
135
+ DeepInfra provider with audio and image support, introduces
136
+ DeepSeek vector-graphics generation and schema support, extends xAI
137
+ image editing, adds `LLM::Schema.defaults` and schema string rendering,
138
+ and makes ActiveRecord and Sequel agent wrappers yield `LLM::Agent`
139
+ instead of polluting the model namespace.
140
+
141
+ ### Breaking
142
+
143
+ * **License change** <br>
144
+ The llm.rb runtime has been developed primarily by one
145
+ person for 3 years. That was done on my own time, and
146
+ I haven't made a dime from that work.
147
+
148
+ So when I saw a multi-million dollar company benefit from
149
+ the work and for it to become the backbone of their AI
150
+ infrastructure and then see them not contribute back or
151
+ offer any kind of support, I decided this is not sustainable,
152
+ or fair.
153
+
154
+ I assumed good faith and for people to act in the spirit of
155
+ open source but sadly, that's just not the case. I
156
+ have to choose a license that respects my time and effort.
157
+
158
+ For those reasons, llm.rb is being relicensed under the
159
+ [Business Source license](https://mariadb.com/bsl11/).
160
+ So what does that mean?
161
+
162
+ In a nutshell:
163
+
164
+ * Free for personal use.
165
+ * Free for education.
166
+ * Free for evaluation, development, and testing.
167
+ * Commercial production use requires a commercial license.
168
+ * Exemptions on a case-by-case basis
169
+
170
+ After 4 years, the license expires and it will become
171
+ available under the 0BSDL as it was before v12.0.0.
172
+ These 4 years apply to a specific version, and not the
173
+ project overall.
174
+
175
+ Going forward, v12.0.0 will be relicensed to respect
176
+ my time, energy, and effort. llm.rb took an incredible
177
+ amount of time and effort, and continues to do so, so
178
+ I want to protect myself from companies who benefit
179
+ from my work but don't respect the time or effort that
180
+ was put into it.
181
+
182
+ * **OpenAI: default to the Responses API** <br>
183
+ The responses API has both models and features that are unavailable
184
+ on the chat completions API, and the responses API appears to be
185
+ the API of the future for OpenAI.
186
+
187
+ Worth noting: the llm.rb implementation does **not** store state
188
+ server-side by default. This can be changed with the `store: true`
189
+ option. The legacy chat completions API can be accessed with the
190
+ `mode: :completions` option.
191
+
192
+ llm.rb has had support for the responses API for quite
193
+ a while but it was not the default, and a number of bugs
194
+ were found and fixed during the process of making it the
195
+ default.
196
+
197
+ * **OpenAI: use gpt-image for image generation** <br>
198
+ The `dalle` models are in the process of being deprecated, and support
199
+ has been dropped from llm.rb. The `gpt-image` models are the next-generation
200
+ image-generation models from OpenAI.
201
+
202
+ * **xAI: provide images as base64-encoded data** <br>
203
+ Both xAI, and OpenAI had the option to generate images via a URL
204
+ you can fetch, or as a base64-encoded string embedded directly
205
+ in the response.
206
+
207
+ OpenAI is moving away from the URL transport since deprecating dalle,
208
+ and with that in mind, llm.rb has dropped support for the URL transport
209
+ across all providers that supported it.
210
+
211
+ Google, xAI, and OpenAI now consistently provide generated and modified
212
+ images as a base64-encoded string.
213
+
214
+ * **ActiveRecord: yield `LLM::Agent` to `acts_as_agent`** <br>
215
+ With this change we yield an instance of `LLM::Agent` to the `acts_as_agent`
216
+ method, and drop the methods (such as `model`, `instructions`, etc) that
217
+ were previously defined directly on the model. This keeps the number of
218
+ methods that llm.rb adds to an ActiveRecord model at a minimum and retains
219
+ the same capabilities as before.
220
+
221
+ * **Sequel: yield `LLM::Agent` to `plugin(:agent)`** <br>
222
+ Ditto as above but for Sequel.
223
+
224
+ * **Remove the langsmith tracer** <br>
225
+ This code was contributed by a third party but contains
226
+ many anti-patterns that are against llm.rb conventions
227
+ and best practices. It was merged without oversight or
228
+ review, and basically against the ethos of open source.
229
+
230
+ I also don't have a langsmith account to maintain the
231
+ code. The alternative is the `LLM::Tracer::Telemetry` class
232
+ that was originally written by me, and serves as a
233
+ general-purpose OTP tracer.
234
+
235
+ ### Add
236
+
237
+ * **Add a new provider: LLM::DeepInfra** <br>
238
+ [DeepInfra](https://deepinfra.com) provide OpenAI-compatible
239
+ endpoints for a large catalog of hosted open-source and
240
+ open-weight models. <br> Capabilities like tool calling, structured outputs, and
241
+ reasoning can depend on the model.
242
+
243
+ * **Add new image provider: LLM::DeepInfra::Images** <br>
244
+ [DeepInfra](https://deepinfra.com) provide access to
245
+ diverse set of text-to-image models. <br> Learn more about the
246
+ available models on their [text-to-image models](https://deepinfra.com/models/text-to-image)
247
+ page.
248
+
249
+ * **DeepSeek: add `LLM::DeepSeek::Images#create` and `#edit`** <br>
250
+ This new API can generate and edit vector graphics (SVGs). <br>
251
+ It is an experimental approach and API.
252
+
253
+ DeepSeek does not provide an image generation model however
254
+ its text-to-text models can generate SVG documents, and
255
+ that's the approach this feature takes. It is limited
256
+ to vector graphics rather than raster images.
257
+
258
+ * **DeepSeek: attach `LLM::Response#agent` to image responses** <br>
259
+ The DeepSeek image API is built on top of
260
+ [`LLM::Agent`](https://r.uby.dev/api-docs/llm.rb/LLM/Agent.html).
261
+ Image responses now expose that agent via `res.agent`, which makes
262
+ it possible to carry the same session across multiple generations
263
+ or edits.
264
+
265
+ * **xAI: add `LLM::XAI::Images#edit`** <br>
266
+ With this change it is possible to both generate images
267
+ from a prompt, and edit an existing image with a prompt.
268
+ xAI now has the same edit and create capabilities that
269
+ OpenAI has.
270
+
271
+ * **Add `LLM::Schema.defaults`** <br>
272
+ This method lets you map multiple property names to
273
+ different default values. It is similar to `LLM::Schema.required`
274
+ in the sense that it is called after the properties of
275
+ a schema have been defined.
276
+
277
+ * **Add `LLM::Schema#to_s` and `LLM::Schema.to_s`** <br>
278
+ Schemas can now be rendered as a prompt-friendly string.
279
+ This is useful when the shape of a schema needs to be
280
+ described in natural-language instructions rather than
281
+ passed through a native structured output interface.
282
+
283
+ * **DeepSeek: add `LLM::Schema` support** <br>
284
+ DeepSeek can now use `schema:` for structured output.
285
+ llm.rb handles this by setting `response_format: {type: "json_object"}`
286
+ and describing the schema in a system message.
287
+
288
+ * **OpenAI: add local file support to the Responses API** <br>
289
+ Our responses API implementation lacked local file support. <br>
290
+ This change fixes that by supporting both image, document,
291
+ and other media types that OpenAI may support.
292
+
293
+ * **Add `LLM::Response#id` across all providers** <br>
294
+ This method was previously implemented via `method_missing`,
295
+ and the field name could change depending on the provider.
296
+ The new method is a catch-all that provides a single method
297
+ that works across all providers.
298
+
299
+ * **Add `LLM::DeepInfra::Audio`** <br>
300
+ DeepInfra implements most of the llm.rb audio interface
301
+ with both the `create_speech` and `create_transcription`
302
+ methods. The `create_translation` method is not implemented,
303
+ and the available text-to-speech and speech-to-text models
304
+ are more varied than other providers.
305
+
306
+ * **OpenAI: normalize text-to-speech responses** <br>
307
+ The `res.audio` method now returns an
308
+ [`LLM::URIData`](https://r.uby.dev/api-docs/llm.rb/LLM/URIData.html)
309
+ object for OpenAI text-to-speech responses. The object provides
310
+ `encoded`, `decoded`, `content_type`, and `encoding_type`.
311
+
312
+ * **DeepInfra: normalize text-to-speech responses** <br>
313
+ The `res.audio` method now returns an
314
+ [`LLM::URIData`](https://r.uby.dev/api-docs/llm.rb/LLM/URIData.html)
315
+ object for DeepInfra text-to-speech responses. The object provides
316
+ `encoded`, `decoded`, `content_type`, and `encoding_type`.
317
+
318
+ ### Fix
319
+
320
+ * **Fix Google `temperature` parameter fall-through** <br>
321
+ Ensure provider-level `temperature` and other `generationConfig`
322
+ parameters are forwarded to the API correctly instead of being
323
+ silently dropped.
324
+
325
+ * **Fix Google `generationConfig` collisions** <br>
326
+ Prevent duplicate or conflicting `generationConfig` keys in the
327
+ Google request adapter.
328
+
329
+ ### Change
330
+
331
+ * **Change OpenAI defaults** <br>
332
+ The default chat model is now `gpt-5.4-mini`. <br>
333
+ The default image model is now `gpt-image`.
334
+
335
+ * **Change google defaults** <br>
336
+ The default chat model is now `gemini-3.1-flash-lite` <br>
337
+ The default embeddings model is now `gemini-embedding-2`
338
+
339
+ * **Change xAI defaults** <br>
340
+ The default chat model is now `grok-4.3`. <br>
341
+ The default image model is now `grok-imagine-image-quality`.
342
+
343
+ * **Return an `LLM::Object` from `LLM::Response#content!`** <br>
344
+ The Hash-like, indifferent access data structure known as
345
+ `LLM::Object` provides a convenient interface around a Hash
346
+ object. It allows method access via `obj.key`, and decays
347
+ into a Hash in many cases.
348
+
349
+ The `LLM::Response#content!` method now wraps its content
350
+ in an `LLM::Object` but only after it has parsed its
351
+ content (a JSON string) into a Ruby data structure.
352
+
353
+ * **Refresh model metadata** <br>
354
+ Update `data/*.json` files with current provider model listings,
355
+ pricing, and capabilities.
4
356
 
5
357
  ## v11.3.1
6
358
 
data/LICENSE CHANGED
@@ -1,17 +1,93 @@
1
- Copyright (C) 2026
2
- Antar Azri <azantar@proton.me>
3
- 0x1eef <0x1eef@hardenedbsd.org>
4
-
5
- Permission to use, copy, modify, and/or distribute this
6
- software for any purpose with or without fee is hereby
7
- granted.
8
-
9
- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS
10
- ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL
11
- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO
12
- EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
13
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER
14
- RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
15
- ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
16
- ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
17
- OF THIS SOFTWARE.
1
+ Business Source License 1.1
2
+
3
+ License text copyright (c) 2024 MariaDB plc, All Rights Reserved.
4
+ "Business Source License" is a trademark of MariaDB plc.
5
+
6
+ Parameters
7
+
8
+ Licensor: Robert Gleeson
9
+
10
+ Licensed Work: llm.rb
11
+
12
+ Additional Use Grant:
13
+ - Free for personal use
14
+ - Free for students and their teachers
15
+ - Free for evaluation, development, and testing
16
+ - Free for non-profits and charities
17
+ - Free for companies with less than or equal to 50 employees
18
+
19
+ Change Date:
20
+ Four years after the first public release of each specific version of the
21
+ Licensed Work.
22
+
23
+ Change License:
24
+ BSD Zero Clause License (0BSD)
25
+
26
+ Terms
27
+
28
+ The Licensor hereby grants you the right to copy, modify, create derivative
29
+ works, redistribute, and make non-production use of the Licensed Work. The
30
+ Licensor may make an Additional Use Grant, above, permitting limited
31
+ production use.
32
+
33
+ Effective on the Change Date, or the fourth anniversary of the first publicly
34
+ available distribution of a specific version of the Licensed Work under this
35
+ License, whichever comes first, the Licensor hereby grants you rights under
36
+ the terms of the Change License, and the rights granted in the paragraph
37
+ above terminate.
38
+
39
+ If your use of the Licensed Work does not comply with the requirements
40
+ currently in effect as described in this License, you must purchase a
41
+ commercial license from the Licensor, its affiliated entities, or authorized
42
+ resellers, or you must refrain from using the Licensed Work.
43
+
44
+ All copies of the original and modified Licensed Work, and derivative works
45
+ of the Licensed Work, are subject to this License. This License applies
46
+ separately for each version of the Licensed Work and the Change Date may vary
47
+ for each version of the Licensed Work released by Licensor.
48
+
49
+ You must conspicuously display this License on each original or modified copy
50
+ of the Licensed Work. If you receive the Licensed Work in original or
51
+ modified form from a third party, the terms and conditions set forth in this
52
+ License apply to your use of that work.
53
+
54
+ Any use of the Licensed Work in violation of this License will automatically
55
+ terminate your rights under this License for the current and all other
56
+ versions of the Licensed Work.
57
+
58
+ This License does not grant you any right in any trademark or logo of
59
+ Licensor or its affiliates (provided that you may use a trademark or logo of
60
+ Licensor as expressly required by this License).
61
+
62
+ TO THE EXTENT PERMITTED BY APPLICABLE LAW, THE LICENSED WORK IS PROVIDED ON
63
+ AN "AS IS" BASIS. LICENSOR HEREBY DISCLAIMS ALL WARRANTIES AND CONDITIONS,
64
+ EXPRESS OR IMPLIED, INCLUDING (WITHOUT LIMITATION) WARRANTIES OF
65
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, NON-INFRINGEMENT, AND
66
+ TITLE.
67
+
68
+ MariaDB hereby grants you permission to use this License's text to license
69
+ your works, and to refer to it using the trademark "Business Source
70
+ License", as long as you comply with the Covenants of Licensor below.
71
+
72
+ Covenants of Licensor
73
+
74
+ In consideration of the right to use this License's text and the "Business
75
+ Source License" name and trademark, Licensor covenants to MariaDB, and to all
76
+ other recipients of the licensed work to be provided by Licensor:
77
+
78
+ To specify as the Change License the GPL Version 2.0 or any later version, or
79
+ a license that is compatible with GPL Version 2.0 or a later version, where
80
+ "compatible" means that software provided under the Change License can be
81
+ included in a program with software provided under GPL Version 2.0 or a later
82
+ version. Licensor may specify additional Change Licenses without limitation.
83
+
84
+ To either: (a) specify an additional grant of rights to use that does not
85
+ impose any additional restriction on the right granted in this License, as
86
+ the Additional Use Grant; or (b) insert the text "None" to specify a Change
87
+ Date. Not to modify this License in any other way.
88
+
89
+ Notice
90
+
91
+ The Business Source License (this document, or the "License") is not an Open
92
+ Source license. However, the Licensed Work will eventually be made available
93
+ under an Open Source License, as stated in this License.