jigor 0.1.0__py3-none-win_amd64.whl
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.
|
Binary file
|
|
@@ -0,0 +1,278 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: jigor
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Classifier: Environment :: Console
|
|
5
|
+
Classifier: Programming Language :: Rust
|
|
6
|
+
Classifier: Topic :: Text Processing
|
|
7
|
+
License-File: LICENSE
|
|
8
|
+
Summary: System One decision gateway — local von/laya ONNX backends plus the remote jev Decisions API (OpenRouter); one wire protocol across models.
|
|
9
|
+
Keywords: system-one,decisions,onnx,gateway
|
|
10
|
+
Author-email: Iurii Zatsepin <support@zatsepin.dev>
|
|
11
|
+
Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM
|
|
12
|
+
Project-URL: Documentation, https://github.com/Partysun/jigor#readme
|
|
13
|
+
Project-URL: Homepage, https://github.com/Partysun/jigor
|
|
14
|
+
Project-URL: Repository, https://github.com/Partysun/jigor
|
|
15
|
+
|
|
16
|
+
# jigor — System One decision gateway (Rust lib)
|
|
17
|
+
|
|
18
|
+
System One decision models in Rust, one wire protocol across backends: `von`
|
|
19
|
+
and `laya` run locally as ONNX (via `ort`); `jev` runs remote on OpenRouter's
|
|
20
|
+
Decisions API.
|
|
21
|
+
|
|
22
|
+
## Models
|
|
23
|
+
|
|
24
|
+
- HF `sevenreasons/von-onnx-fp16` (`model.onnx` 759M, `tokenizer/tokenizer.json` 3.5M)
|
|
25
|
+
- HF `Mattepiu/laya-onnx` (`laya.onnx` fp32 — matches the python reference
|
|
26
|
+
bit-for-bit; `int8/laya_int8.onnx` via `LAYA_ONNX_FILE`)
|
|
27
|
+
- OpenRouter Decisions (`typesafe/jev-1.13` today) — any model there speaking
|
|
28
|
+
the same System One wire works; add it to `known_providers()` and nothing
|
|
29
|
+
else changes.
|
|
30
|
+
|
|
31
|
+
## Usage as lib
|
|
32
|
+
|
|
33
|
+
One dependency, one entry per backend — `noul`/`choice`/`score` questions
|
|
34
|
+
in, typed answers out. Identical on von, laya and any OpenRouter model.
|
|
35
|
+
|
|
36
|
+
```toml
|
|
37
|
+
[dependencies]
|
|
38
|
+
jigor = { path = "../jigor" } # local checkout
|
|
39
|
+
# jigor = { git = "https://github.com/Partysun/jigor" } # from GitHub
|
|
40
|
+
# jigor = "0.1.0" # once published
|
|
41
|
+
serde_json = { version = "1.0" } # Value, json!
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
```rust
|
|
45
|
+
use jigor::{Answer, Question, Backend, Result, VonBackend, choice, noul, score};
|
|
46
|
+
use serde_json::json;
|
|
47
|
+
|
|
48
|
+
fn main() -> Result<()> {
|
|
49
|
+
let mut von = VonBackend::new()?; // VonBackend::new, LayaBackend::new,
|
|
50
|
+
// OpenRouterBackend::for_model(...):
|
|
51
|
+
// the same answers() call on all three
|
|
52
|
+
let questions = vec![
|
|
53
|
+
noul("churn", "Is the customer likely to churn?"),
|
|
54
|
+
choice(
|
|
55
|
+
"want",
|
|
56
|
+
"What does the customer want?",
|
|
57
|
+
&["refund", "order status", "technical help"],
|
|
58
|
+
),
|
|
59
|
+
score("urgency", "How urgent is this?", &["calm", "annoyed", "angry"]),
|
|
60
|
+
];
|
|
61
|
+
let asks = von.answers(
|
|
62
|
+
&json!("Customer: I was charged twice for order #4471."),
|
|
63
|
+
&questions,
|
|
64
|
+
None,
|
|
65
|
+
)?;
|
|
66
|
+
|
|
67
|
+
match asks.get("churn").unwrap() {
|
|
68
|
+
Answer::Noul { probability } => println!("churn: {:.4}", *probability),
|
|
69
|
+
_ => {},
|
|
70
|
+
}
|
|
71
|
+
Ok(())
|
|
72
|
+
}
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
Only have a model id? `jigor::ask` resolves aliases and the provider for you:
|
|
76
|
+
|
|
77
|
+
```rust
|
|
78
|
+
let asks = jigor::ask("jev", &state, &questions, None)?; // OpenRouter jev
|
|
79
|
+
let asks = jigor::ask("laya", &state, &questions, None)?; // local laya
|
|
80
|
+
// Asks { model, backend, answers }
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
Errors are one type — `jigor::Error` (carried by
|
|
84
|
+
`jigor::Result<T>`): `UnknownModel`/`MissingApiKey`/`Remote` for
|
|
85
|
+
routing and OpenRouter responses, `Wire`/`MissingAnswer`/`MissingAnswers`
|
|
86
|
+
for malformed question/answer payloads, `Serialization` for JSON text,
|
|
87
|
+
`External`/`Internal` for everything else. No foreign error type ever
|
|
88
|
+
leaks out of the library.
|
|
89
|
+
|
|
90
|
+
```rust
|
|
91
|
+
use jigor::{Error, Result};
|
|
92
|
+
|
|
93
|
+
match von.answers(&state, &questions, None) {
|
|
94
|
+
Ok(asks) => { /* typed answers */ }
|
|
95
|
+
Err(Error::Remote { status, message }) => { /* upstream 4xx/5xx */ }
|
|
96
|
+
Err(e) => println!("{e}"),
|
|
97
|
+
}
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
## Production: library vs installed CLI/server
|
|
101
|
+
|
|
102
|
+
One workspace, two crates (`crates/jigor` + `crates/jigor-cli`), one pip
|
|
103
|
+
distribution — the same code, three ways to consume it:
|
|
104
|
+
|
|
105
|
+
- **Library** — `jigor = { version = "0.1.0" }` in your crate (see
|
|
106
|
+
`Usage as lib`). Only the library target is compiled: the CLI/server code
|
|
107
|
+
and its dependencies (hyper, tokio, ...) never enter consumer builds.
|
|
108
|
+
- **CLI + server (cargo)** — `cargo install jigor-cli` installs the `jigor`
|
|
109
|
+
binary: `jigor serve`, `jigor ask`, `jigor models`.
|
|
110
|
+
- **CLI + server (npm)** — `npm install --global jigor` (prebuilt binary,
|
|
111
|
+
per-platform packages: linux x64/arm64, macos universal2 — Intel + Apple
|
|
112
|
+
Silicon, windows x64).
|
|
113
|
+
- **CLI + server (pip)** — `pip install jigor` (maturin wheel) installs the
|
|
114
|
+
same `jigor` console script.
|
|
115
|
+
|
|
116
|
+
The local ONNX models (`von`, `laya`) download to `~/.cache/huggingface` on
|
|
117
|
+
first use; set `OPENROUTER_API_KEY` for the remote `jev` backend. Both crates
|
|
118
|
+
are published together (`make publish`) from the shared version in
|
|
119
|
+
`Cargo.toml`; the wheel and the npm binary packages are published by the
|
|
120
|
+
release pipelines (`.woodpecker/wheel-*.yml`, `.woodpecker/npm-*.yml`).
|
|
121
|
+
|
|
122
|
+
## Run examples (lib crate, no bin)
|
|
123
|
+
|
|
124
|
+
```bash
|
|
125
|
+
cargo run -p jigor --example decide # same as Python main.py
|
|
126
|
+
cargo run -p jigor --release --example bench # bench
|
|
127
|
+
cargo run -p jigor --example decide --offline
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
Expected `decide`:
|
|
131
|
+
|
|
132
|
+
```
|
|
133
|
+
infrastructure
|
|
134
|
+
0.428
|
|
135
|
+
{'infrastructure': 0.6203, 'billing': 0.1873, 'feature_request': 0.1924}
|
|
136
|
+
judge: 0.3586
|
|
137
|
+
rate score: 1.02 conf: 0.707 probs: {"1": 0.8109, "2": 0.1036, "0": 0.0855}
|
|
138
|
+
fan-out intent: payment_failure 0.539
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
Set `JIGOR_DEVICE=cuda` to try CUDA EP
|
|
142
|
+
(`ort` `cuda` feature, fallback to CPU if unavailable).
|
|
143
|
+
|
|
144
|
+
## Run as executable: `jigor`
|
|
145
|
+
|
|
146
|
+
```bash
|
|
147
|
+
cargo build -p jigor-cli --release
|
|
148
|
+
./target/release/jigor serve --host 0.0.0.0 --port 8000 # HTTP gateway
|
|
149
|
+
jigor models # provider x model pairs
|
|
150
|
+
```
|
|
151
|
+
|
|
152
|
+
The gateway mirrors the library: noul/choice/score questions in, typed
|
|
153
|
+
answers out — `von`/`laya` locally, anything else routed to the OpenRouter
|
|
154
|
+
backend selected by the `model` field:
|
|
155
|
+
|
|
156
|
+
```bash
|
|
157
|
+
jigor ask <<'JSON' # same wire over stdin, no HTTP layer
|
|
158
|
+
{
|
|
159
|
+
"state": { "error": "Disk volume /var/log at 98% capacity." },
|
|
160
|
+
"questions": {
|
|
161
|
+
"requires_intervention": {
|
|
162
|
+
"type": "noul",
|
|
163
|
+
"instructions": "Does this disk space condition require operational intervention?"
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
JSON
|
|
168
|
+
# {"model":"von-1.0.0","backend":"local","answers":{...}}
|
|
169
|
+
|
|
170
|
+
# pin the provider, or use the "jev" alias for typesafe/jev-1.13 on OpenRouter:
|
|
171
|
+
jigor ask --provider openrouter --model jev < request.json
|
|
172
|
+
jigor ask --model jev < request.json # provider inferred from the id
|
|
173
|
+
```
|
|
174
|
+
|
|
175
|
+
```bash
|
|
176
|
+
curl -X POST http://localhost:8000/v1/systemone \
|
|
177
|
+
-H "Content-Type: application/json" \
|
|
178
|
+
-d '{
|
|
179
|
+
"model": "von-1.0.0",
|
|
180
|
+
"state": { "error": "Disk volume /var/log at 98% capacity." },
|
|
181
|
+
"questions": {
|
|
182
|
+
"requires_intervention": {
|
|
183
|
+
"type": "noul",
|
|
184
|
+
"instructions": "Does this disk space condition require operational intervention?"
|
|
185
|
+
}
|
|
186
|
+
}
|
|
187
|
+
}'
|
|
188
|
+
# {"model":"von-1.0.0","backend":"local","answers":{"requires_intervention":{"type":"noul","noul":0.2739}}}
|
|
189
|
+
```
|
|
190
|
+
|
|
191
|
+
Route by provider + model pair — `typesafe/jev-1.13` (alias `jev`) goes to
|
|
192
|
+
OpenRouter, `von-1.0.0` (alias `von`) stays local; unknown pairs are rejected.
|
|
193
|
+
|
|
194
|
+
Also: `GET /healthz` returns `{"status":"ok"}`.
|
|
195
|
+
|
|
196
|
+
## Tweet Tester (example: using the lib)
|
|
197
|
+
|
|
198
|
+
`examples/tweet.rs` is a complete Tweet Tester written _only_ against the lib
|
|
199
|
+
API — it demonstrates how to build a Jev-style tool on top of
|
|
200
|
+
`noul`/`choice`/`score` questions through one `answers` interface. All
|
|
201
|
+
tweet-specific code lives in the example (the lib itself stays generic):
|
|
202
|
+
|
|
203
|
+
- the 61-question viral-score bank (question set `v1.1`, 8 families
|
|
204
|
+
EMO/CNV/SHR/TIM/CRF/IDN/FMT/ANTI);
|
|
205
|
+
- a transparent 0-100 aggregation (`0.65 * content mean + 0.35 * clean
|
|
206
|
+
anti-signal`) — scoring semantics: 50 = your account's normal post, above
|
|
207
|
+
50 beats it, below 50 does worse;
|
|
208
|
+
- per-family "fired % of N questions" radar stats, top helped/hurt, and
|
|
209
|
+
engagement `counters` (a wire JSON shape mirroring the viral-score API).
|
|
210
|
+
|
|
211
|
+
```bash
|
|
212
|
+
cargo run -p jigor --example tweet -- "We just crossed 10,000 paying customers. Thank you."
|
|
213
|
+
cargo run -p jigor --example tweet -- --json "We just crossed 10,000 paying customers."
|
|
214
|
+
# {"score":53,"beats_own_normal":0.53,
|
|
215
|
+
# "families":{"EMOTION":{"label":"Emotion","fired":0.11,"total":9},...},
|
|
216
|
+
# "counters":{"likes":{"multiple":1.1,"p75":2.1,"p90":4.6,"breakout_share":0.1,"probability":0.5,"confidence":"normal","own_median":null,"expected":null},...},
|
|
217
|
+
# "helped":[{"id":"k_concrete_numbers","family":"CRAFT","label":"Numbers that carry weight","answer":"Yes","detail":"Stronger than your usual post","effect":0.95}],
|
|
218
|
+
# "hurt":[...],"answers":[...61 items...],"engine":{"model":"von-1.0.0","question_set":"v1.1",...}}
|
|
219
|
+
```
|
|
220
|
+
|
|
221
|
+
The example resolves the backend by model, exactly like `jigor ask`: `--model
|
|
222
|
+
von` (default, local ONNX), `--model jev` (OpenRouter) or any other alias.
|
|
223
|
+
The 61-question bank, score, radar and counters are identical across
|
|
224
|
+
backends, so you can compare the same tweet side by side:
|
|
225
|
+
|
|
226
|
+
```bash
|
|
227
|
+
cargo run -p jigor --example tweet -- --model von "We just crossed 10,000 paying customers. Thank you."
|
|
228
|
+
cargo run -p jigor --example tweet -- --model jev "We just crossed 10,000 paying customers. Thank you."
|
|
229
|
+
cargo run -p jigor --example tweet -- --model jev --json "Hot take." > jev.json
|
|
230
|
+
```
|
|
231
|
+
|
|
232
|
+
For the milestone tweet the outputs line up: von gives 53/100 (conservative,
|
|
233
|
+
CRAFT 35%), jev gives 63/100 (CRAFT 73%). Scores across backends are not
|
|
234
|
+
calibrated to each other, but the shape is directly comparable.
|
|
235
|
+
|
|
236
|
+
Family `fired` is the "X% of its questions fired" radar value. The engagement
|
|
237
|
+
`counters` (multiples, p75/p90, probabilities) and the `effect` coefficients
|
|
238
|
+
are transparent placeholders for a fitted engagement model — tune the
|
|
239
|
+
weights in the example's `counter_json`/`counter_multiple` once you have
|
|
240
|
+
paired data. Von is a general decision model, so scores are a signal, not a
|
|
241
|
+
forecast; fitting an engagement model on the same answers is the calibration
|
|
242
|
+
step.
|
|
243
|
+
|
|
244
|
+
Question builders: `choice` takes plain option strings (each is both key and
|
|
245
|
+
description), `choice_pairs` takes `(key, description)` pairs, `score` takes
|
|
246
|
+
ordered level texts, `noul` a plain instruction — and all three kinds mix
|
|
247
|
+
freely in one `answers` call.
|
|
248
|
+
|
|
249
|
+
## Auto-tagger (example: using the lib)
|
|
250
|
+
|
|
251
|
+
`examples/tagger.rs` shows a `choice` workflow: given a note and a list of
|
|
252
|
+
existing tags, one question — "Which tag best matches the content of this
|
|
253
|
+
note?" — picks the best tag (or the `None of these fit well` fallback) with a
|
|
254
|
+
probability distribution. Also runs on either backend via `--model`/`--provider`.
|
|
255
|
+
|
|
256
|
+
```bash
|
|
257
|
+
cargo run -p jigor --example tagger -- --title "Hiring notes" --tags "work, ideas, personal" "Budget approved for two engineers."
|
|
258
|
+
# Best tag: work (confidence 0.440)
|
|
259
|
+
# work 60% · ideas 16% · personal 13% · None of these fit well 10%
|
|
260
|
+
cargo run -p jigor --example tagger -- --model jev --tags "bugs, docs, ship" "Fixed the retry loop that dropped webhook events."
|
|
261
|
+
cargo run -p jigor --example tagger -- --json --tags "a, b" "note text" # wire JSON out
|
|
262
|
+
```
|
|
263
|
+
|
|
264
|
+
## Integration tests
|
|
265
|
+
|
|
266
|
+
Requires [hurl](https://hurl.dev) and the local ONNX model (downloaded on
|
|
267
|
+
first run). Wire fixtures live in `tests/fixtures/` (the OpenRouter Decisions
|
|
268
|
+
request/response payloads are the reference for the wire format).
|
|
269
|
+
|
|
270
|
+
```bash
|
|
271
|
+
make test # unit tests + hurl suite + CLI tests
|
|
272
|
+
bash tests/hurl/run.sh # jigor serve: /v1/systemone (health, noul, choice,
|
|
273
|
+
# score, fan-out, error paths, backend routing)
|
|
274
|
+
bash tests/cli/ask.sh # jigor ask / jigor models over stdin fixtures
|
|
275
|
+
# or against a running server:
|
|
276
|
+
hurl --test --variable BASE_URL=http://localhost:8000 tests/hurl/*.hurl
|
|
277
|
+
```
|
|
278
|
+
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
jigor-0.1.0.data/scripts/jigor.exe,sha256=giM-GoubE4LUvxQFyWKr52fTX42eEo72aH5JF17b6Ng,25150976
|
|
2
|
+
jigor-0.1.0.dist-info/METADATA,sha256=6Wzhoh_ct04TNB9RfE8vPWVlkGDS_gvqjefU5grYPUs,11882
|
|
3
|
+
jigor-0.1.0.dist-info/WHEEL,sha256=8Aej0W0a6Cz6apA3IzJrTnxLRVLAt-w0Oh8SA3Con_c,94
|
|
4
|
+
jigor-0.1.0.dist-info/licenses/LICENSE,sha256=fPOWp7LCFa6Y_N9_kc8FhumetfRCVfXtvHRHNOQhqjs,11574
|
|
5
|
+
jigor-0.1.0.dist-info/sboms/jigor-cli.cyclonedx.json,sha256=mxcaWseC9P4NOH9emfiskmpPPNXDwoHZ0QVTBfNygoI,197734
|
|
6
|
+
jigor-0.1.0.dist-info/RECORD,,
|
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
|
|
2
|
+
Apache License
|
|
3
|
+
Version 2.0, January 2004
|
|
4
|
+
http://www.apache.org/licenses/
|
|
5
|
+
|
|
6
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
7
|
+
|
|
8
|
+
1. Definitions.
|
|
9
|
+
|
|
10
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
11
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
12
|
+
|
|
13
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
14
|
+
the copyright owner that is granting the License.
|
|
15
|
+
|
|
16
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
17
|
+
other entities that control, are controlled by, or are under common
|
|
18
|
+
control with that entity. For the purposes of this definition,
|
|
19
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
20
|
+
direction or management of such entity, whether by contract or
|
|
21
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
22
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
23
|
+
|
|
24
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
25
|
+
exercising permissions granted by this License.
|
|
26
|
+
|
|
27
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
28
|
+
including but not limited to software source code, documentation
|
|
29
|
+
source, and configuration files.
|
|
30
|
+
|
|
31
|
+
"Object" form shall mean any form resulting from mechanical
|
|
32
|
+
transformation or translation of a Source form, including but
|
|
33
|
+
not limited to compiled object code, generated documentation,
|
|
34
|
+
and conversions to other media types.
|
|
35
|
+
|
|
36
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
37
|
+
Object form, made available under the License, as indicated by a
|
|
38
|
+
copyright notice that is included in or attached to the work
|
|
39
|
+
(an example is provided in the Appendix below).
|
|
40
|
+
|
|
41
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
42
|
+
form, that is based on (or derived from) the Work and for which the
|
|
43
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
44
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
45
|
+
of this License, Derivative Works shall not include works that remain
|
|
46
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
47
|
+
the Work and Derivative Works thereof.
|
|
48
|
+
|
|
49
|
+
"Contribution" shall mean any work of authorship, including
|
|
50
|
+
the original version of the Work and any modifications or additions
|
|
51
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
52
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
53
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
54
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
55
|
+
means any form of electronic, verbal, or written communication sent
|
|
56
|
+
to the Licensor or its representatives, including but not limited to
|
|
57
|
+
communication on electronic mailing lists, source code control systems,
|
|
58
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
59
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
60
|
+
excluding communication that is conspicuously marked or otherwise
|
|
61
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
62
|
+
|
|
63
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
64
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
65
|
+
subsequently incorporated within the Work.
|
|
66
|
+
|
|
67
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
68
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
69
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
70
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
71
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
72
|
+
Work and such Derivative Works in Source or Object form.
|
|
73
|
+
|
|
74
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
75
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
76
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
77
|
+
(except as stated in this section) patent license to make, have made,
|
|
78
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
79
|
+
where such license applies only to those patent claims licensable
|
|
80
|
+
by such Contributor that are necessarily infringed by their
|
|
81
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
82
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
83
|
+
institute patent litigation against any entity (including a
|
|
84
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
85
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
86
|
+
or contributory patent infringement, then any patent licenses
|
|
87
|
+
granted to You under this License for that Work shall terminate
|
|
88
|
+
as of the date such litigation is filed.
|
|
89
|
+
|
|
90
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
91
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
92
|
+
modifications, and in Source or Object form, provided that You
|
|
93
|
+
meet the following conditions:
|
|
94
|
+
|
|
95
|
+
(a) You must give any other recipients of the Work or
|
|
96
|
+
Derivative Works a copy of this License; and
|
|
97
|
+
|
|
98
|
+
(b) You must cause any modified files to carry prominent notices
|
|
99
|
+
stating that You changed the files; and
|
|
100
|
+
|
|
101
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
102
|
+
that You distribute, all copyright, patent, trademark, and
|
|
103
|
+
attribution notices from the Source form of the Work,
|
|
104
|
+
excluding those notices that do not pertain to any part of
|
|
105
|
+
the Derivative Works; and
|
|
106
|
+
|
|
107
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
108
|
+
distribution, then any Derivative Works that You distribute must
|
|
109
|
+
include a readable copy of the attribution notices contained
|
|
110
|
+
within such NOTICE file, excluding those notices that do not
|
|
111
|
+
pertain to any part of the Derivative Works, in at least one
|
|
112
|
+
of the following places: within a NOTICE text file distributed
|
|
113
|
+
as part of the Derivative Works; within the Source form or
|
|
114
|
+
documentation, if provided along with the Derivative Works; or,
|
|
115
|
+
within a display generated by the Derivative Works, if and
|
|
116
|
+
wherever such third-party notices normally appear. The contents
|
|
117
|
+
of the NOTICE file are for informational purposes only and
|
|
118
|
+
do not modify the License. You may add Your own attribution
|
|
119
|
+
notices within Derivative Works that You distribute, alongside
|
|
120
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
121
|
+
that such additional attribution notices cannot be construed
|
|
122
|
+
as modifying the License.
|
|
123
|
+
|
|
124
|
+
You may add Your own copyright statement to Your modifications and
|
|
125
|
+
may provide additional or different license terms and conditions
|
|
126
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
127
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
128
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
129
|
+
the conditions stated in this License.
|
|
130
|
+
|
|
131
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
132
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
133
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
134
|
+
this License, without any additional terms or conditions.
|
|
135
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
136
|
+
the terms of any separate license agreement you may have executed
|
|
137
|
+
with Licensor regarding such Contributions.
|
|
138
|
+
|
|
139
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
140
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
141
|
+
except as required for reasonable and customary use in describing the
|
|
142
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
143
|
+
|
|
144
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
145
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
146
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
147
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
148
|
+
implied, including, without limitation, any warranties or conditions
|
|
149
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
150
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
151
|
+
appropriateness of using or redistributing the Work and assume any
|
|
152
|
+
risks associated with Your exercise of permissions under this License.
|
|
153
|
+
|
|
154
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
155
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
156
|
+
unless required by applicable law (such as deliberate and grossly
|
|
157
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
158
|
+
liable to You for damages, including any direct, indirect, special,
|
|
159
|
+
incidental, or consequential damages of any character arising as a
|
|
160
|
+
result of this License or out of the use or inability to use the
|
|
161
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
162
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
163
|
+
other commercial damages or losses), even if such Contributor
|
|
164
|
+
has been advised of the possibility of such damages.
|
|
165
|
+
|
|
166
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
167
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
168
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
169
|
+
or other liability obligations and/or rights consistent with this
|
|
170
|
+
License. However, in accepting such obligations, You may act only
|
|
171
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
172
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
173
|
+
defend, and hold each Contributor harmless for any liability
|
|
174
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
175
|
+
of your accepting any such warranty or additional liability.
|
|
176
|
+
|
|
177
|
+
END OF TERMS AND CONDITIONS
|
|
178
|
+
|
|
179
|
+
APPENDIX: How to apply the Apache License to your work.
|
|
180
|
+
|
|
181
|
+
To apply the Apache License to your work, attach the following
|
|
182
|
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
183
|
+
replaced with your own identifying information. (Don't include
|
|
184
|
+
the brackets!) The text should be enclosed in the appropriate
|
|
185
|
+
comment syntax for the file format. We also recommend that a
|
|
186
|
+
file or class name and description of purpose be included on the
|
|
187
|
+
same "printed page" as the copyright notice for easier
|
|
188
|
+
identification within third-party archives.
|
|
189
|
+
|
|
190
|
+
Copyright [2026] [Iurii Zatsepin (https://zatsepin.dev)]
|
|
191
|
+
|
|
192
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
193
|
+
you may not use this file except in compliance with the License.
|
|
194
|
+
You may obtain a copy of the License at
|
|
195
|
+
|
|
196
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
197
|
+
|
|
198
|
+
Unless required by applicable law or agreed to in writing, software
|
|
199
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
200
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
201
|
+
See the License for the specific language governing permissions and
|
|
202
|
+
limitations under the License.
|