calfkit 0.1.1__tar.gz

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 (44) hide show
  1. calfkit-0.1.1/.github/dependabot.yml +39 -0
  2. calfkit-0.1.1/.github/workflows/build.yml +78 -0
  3. calfkit-0.1.1/.github/workflows/code-checks.yml +38 -0
  4. calfkit-0.1.1/.github/workflows/release.yml +59 -0
  5. calfkit-0.1.1/.github/workflows/security.yml +64 -0
  6. calfkit-0.1.1/.github/workflows/test.yml +57 -0
  7. calfkit-0.1.1/.gitignore +44 -0
  8. calfkit-0.1.1/.release-please-manifest.json +3 -0
  9. calfkit-0.1.1/CHANGELOG.md +35 -0
  10. calfkit-0.1.1/CLAUDE.md +1 -0
  11. calfkit-0.1.1/LICENSE +202 -0
  12. calfkit-0.1.1/Makefile +90 -0
  13. calfkit-0.1.1/PKG-INFO +129 -0
  14. calfkit-0.1.1/README.md +101 -0
  15. calfkit-0.1.1/calfkit/__init__.py +4 -0
  16. calfkit-0.1.1/calfkit/broker/__init__.py +3 -0
  17. calfkit-0.1.1/calfkit/broker/broker.py +34 -0
  18. calfkit-0.1.1/calfkit/broker/deployable.py +6 -0
  19. calfkit-0.1.1/calfkit/broker/middleware.py +15 -0
  20. calfkit-0.1.1/calfkit/experimental/rpc_worker.py +51 -0
  21. calfkit-0.1.1/calfkit/messages/__init__.py +9 -0
  22. calfkit-0.1.1/calfkit/messages/util.py +99 -0
  23. calfkit-0.1.1/calfkit/models/event_envelope.py +43 -0
  24. calfkit-0.1.1/calfkit/models/types.py +65 -0
  25. calfkit-0.1.1/calfkit/nodes/__init__.py +16 -0
  26. calfkit-0.1.1/calfkit/nodes/agent_router_node.py +194 -0
  27. calfkit-0.1.1/calfkit/nodes/base_node.py +62 -0
  28. calfkit-0.1.1/calfkit/nodes/base_tool_node.py +55 -0
  29. calfkit-0.1.1/calfkit/nodes/chat_node.py +48 -0
  30. calfkit-0.1.1/calfkit/nodes/registrator.py +11 -0
  31. calfkit-0.1.1/calfkit/providers/__init__.py +5 -0
  32. calfkit-0.1.1/calfkit/providers/pydantic_ai/__init__.py +3 -0
  33. calfkit-0.1.1/calfkit/providers/pydantic_ai/openai.py +61 -0
  34. calfkit-0.1.1/calfkit/runners/__init__.py +14 -0
  35. calfkit-0.1.1/calfkit/runners/node_runner.py +38 -0
  36. calfkit-0.1.1/calfkit/stores/__init__.py +38 -0
  37. calfkit-0.1.1/calfkit/stores/base.py +60 -0
  38. calfkit-0.1.1/calfkit/stores/in_memory.py +29 -0
  39. calfkit-0.1.1/pyproject.toml +67 -0
  40. calfkit-0.1.1/release-please-config.json +21 -0
  41. calfkit-0.1.1/tests/__init__.py +0 -0
  42. calfkit-0.1.1/tests/test_agent_runner.py +255 -0
  43. calfkit-0.1.1/tests/test_broker.py +46 -0
  44. calfkit-0.1.1/tests/utils.py +32 -0
@@ -0,0 +1,39 @@
1
+ version: 2
2
+
3
+ updates:
4
+ # Python dependencies (pip/uv)
5
+ - package-ecosystem: "pip"
6
+ directory: "/"
7
+ schedule:
8
+ interval: "weekly"
9
+ day: "monday"
10
+ open-pull-requests-limit: 10
11
+ labels:
12
+ - "dependencies"
13
+ - "python"
14
+ commit-message:
15
+ prefix: "deps"
16
+ groups:
17
+ python-minor:
18
+ patterns:
19
+ - "*"
20
+ update-types:
21
+ - "minor"
22
+ - "patch"
23
+
24
+ # GitHub Actions
25
+ - package-ecosystem: "github-actions"
26
+ directory: "/"
27
+ schedule:
28
+ interval: "weekly"
29
+ day: "monday"
30
+ open-pull-requests-limit: 5
31
+ labels:
32
+ - "dependencies"
33
+ - "github-actions"
34
+ commit-message:
35
+ prefix: "ci"
36
+ groups:
37
+ github-actions:
38
+ patterns:
39
+ - "*"
@@ -0,0 +1,78 @@
1
+ name: Build
2
+
3
+ on:
4
+ push:
5
+ branches:
6
+ - main
7
+ pull_request:
8
+ branches:
9
+ - main
10
+
11
+ concurrency:
12
+ group: ${{ github.workflow }}-${{ github.ref }}
13
+ cancel-in-progress: true
14
+
15
+ jobs:
16
+ build:
17
+ name: Build package
18
+ runs-on: ubuntu-latest
19
+
20
+ steps:
21
+ - name: Checkout code
22
+ uses: actions/checkout@v6
23
+
24
+ - name: Set up Python
25
+ uses: actions/setup-python@v6
26
+ with:
27
+ python-version: "3.10"
28
+
29
+ - name: Install uv
30
+ uses: astral-sh/setup-uv@v7
31
+ with:
32
+ enable-cache: true
33
+
34
+ - name: Build package
35
+ run: uv build
36
+
37
+ - name: Upload artifacts
38
+ uses: actions/upload-artifact@v6
39
+ with:
40
+ name: dist
41
+ path: dist/
42
+
43
+ verify:
44
+ name: Verify ${{ matrix.os }}
45
+ needs: build
46
+ runs-on: ${{ matrix.os }}
47
+
48
+ strategy:
49
+ fail-fast: false
50
+ matrix:
51
+ os:
52
+ # Linux x64
53
+ - ubuntu-latest
54
+ # macOS Intel
55
+ - macos-15-intel
56
+ # macOS Apple Silicon
57
+ - macos-latest
58
+ # Windows x64
59
+ - windows-latest
60
+
61
+ steps:
62
+ - name: Set up Python
63
+ uses: actions/setup-python@v6
64
+ with:
65
+ python-version: "3.10"
66
+
67
+ - name: Download artifacts
68
+ uses: actions/download-artifact@v7
69
+ with:
70
+ name: dist
71
+ path: dist/
72
+
73
+ - name: Install wheel
74
+ run: pip install dist/*.whl
75
+ shell: bash
76
+
77
+ - name: Verify import
78
+ run: python -c "import calfkit; print(f'calfkit {calfkit.__version__} installed successfully')"
@@ -0,0 +1,38 @@
1
+ name: Code checks
2
+
3
+ on: push
4
+
5
+ concurrency:
6
+ group: ${{ github.workflow }}-${{ github.ref }}
7
+ cancel-in-progress: true
8
+
9
+ jobs:
10
+ lint:
11
+ name: Ruff, MyPy
12
+ runs-on: ubuntu-latest
13
+
14
+ steps:
15
+ - name: Checkout code
16
+ uses: actions/checkout@v6
17
+
18
+ - name: Set up Python
19
+ uses: actions/setup-python@v6
20
+ with:
21
+ python-version: "3.10"
22
+
23
+ - name: Install uv
24
+ uses: astral-sh/setup-uv@v7
25
+ with:
26
+ enable-cache: true
27
+
28
+ - name: Install dependencies
29
+ run: uv sync --group dev
30
+
31
+ - name: Run Ruff linter
32
+ run: uv run ruff check .
33
+
34
+ - name: Run Ruff formatter check
35
+ run: uv run ruff format --check .
36
+
37
+ - name: Run MyPy
38
+ run: uv run mypy calfkit/
@@ -0,0 +1,59 @@
1
+ name: Release
2
+
3
+ on:
4
+ push:
5
+ branches:
6
+ - main
7
+
8
+ permissions:
9
+ contents: write
10
+ pull-requests: write
11
+
12
+ jobs:
13
+ release-please:
14
+ name: Release Please
15
+ runs-on: ubuntu-latest
16
+
17
+ outputs:
18
+ release_created: ${{ steps.release.outputs.release_created }}
19
+ tag_name: ${{ steps.release.outputs.tag_name }}
20
+ version: ${{ steps.release.outputs.version }}
21
+
22
+ steps:
23
+ - name: Run release-please
24
+ id: release
25
+ uses: googleapis/release-please-action@v4
26
+ with:
27
+ token: ${{ secrets.GITHUB_TOKEN }}
28
+
29
+ publish:
30
+ name: Publish to PyPI
31
+ runs-on: ubuntu-latest
32
+ needs: release-please
33
+ # Only publish when release-please creates a release
34
+ if: needs.release-please.outputs.release_created == 'true'
35
+
36
+ environment:
37
+ name: pypi
38
+ url: https://pypi.org/project/calfkit/
39
+
40
+ permissions:
41
+ id-token: write
42
+
43
+ steps:
44
+ - name: Checkout code
45
+ uses: actions/checkout@v6
46
+
47
+ - name: Set up Python
48
+ uses: actions/setup-python@v6
49
+ with:
50
+ python-version: "3.10"
51
+
52
+ - name: Install uv
53
+ uses: astral-sh/setup-uv@v7
54
+
55
+ - name: Build package
56
+ run: uv build
57
+
58
+ - name: Publish to PyPI
59
+ uses: pypa/gh-action-pypi-publish@release/v1
@@ -0,0 +1,64 @@
1
+ name: Security
2
+
3
+ on:
4
+ push:
5
+ branches:
6
+ - main
7
+ pull_request:
8
+ branches:
9
+ - main
10
+ schedule:
11
+ # Run weekly on Monday at 00:00 UTC
12
+ - cron: "0 0 * * 1"
13
+
14
+ concurrency:
15
+ group: ${{ github.workflow }}-${{ github.ref }}
16
+ cancel-in-progress: true
17
+
18
+ # TODO: Re-enable when repo is public
19
+ jobs:
20
+ codeql:
21
+ name: CodeQL Analysis
22
+ if: false
23
+ # Disabled - repo not yet public
24
+ runs-on: ubuntu-latest
25
+
26
+ permissions:
27
+ security-events: write
28
+ contents: read
29
+ actions: read
30
+
31
+ steps:
32
+ - name: Checkout code
33
+ uses: actions/checkout@v6
34
+
35
+ - name: Initialize CodeQL
36
+ uses: github/codeql-action/init@v4
37
+ with:
38
+ languages: python
39
+ queries: security-and-quality
40
+
41
+ - name: Perform CodeQL Analysis
42
+ uses: github/codeql-action/analyze@v4
43
+ with:
44
+ category: "/language:python"
45
+
46
+ dependency-review:
47
+ name: Dependency Review
48
+ if: false
49
+ # Disabled - repo not yet public. restore github.event_name == 'pull_request'
50
+ runs-on: ubuntu-latest
51
+
52
+ permissions:
53
+ contents: read
54
+ pull-requests: write
55
+
56
+ steps:
57
+ - name: Checkout code
58
+ uses: actions/checkout@v6
59
+
60
+ - name: Dependency Review
61
+ uses: actions/dependency-review-action@v4
62
+ with:
63
+ fail-on-severity: high
64
+ deny-licenses: GPL-3.0, AGPL-3.0
@@ -0,0 +1,57 @@
1
+ name: Tests
2
+
3
+ on:
4
+ push:
5
+ branches:
6
+ - main
7
+ pull_request:
8
+ branches:
9
+ - main
10
+
11
+ concurrency:
12
+ group: ${{ github.workflow }}-${{ github.ref }}
13
+ cancel-in-progress: true
14
+
15
+ jobs:
16
+ test:
17
+ name: Python ${{ matrix.python-version }}
18
+ runs-on: ubuntu-latest
19
+
20
+ strategy:
21
+ fail-fast: false
22
+ matrix:
23
+ python-version: ["3.10", "3.11", "3.12"]
24
+
25
+ steps:
26
+ - name: Checkout code
27
+ uses: actions/checkout@v6
28
+
29
+ - name: Set up Python ${{ matrix.python-version }}
30
+ uses: actions/setup-python@v6
31
+ with:
32
+ python-version: ${{ matrix.python-version }}
33
+
34
+ - name: Install uv
35
+ uses: astral-sh/setup-uv@v7
36
+ with:
37
+ enable-cache: true
38
+
39
+ - name: Install dependencies
40
+ run: uv sync --group dev
41
+
42
+ - name: Run tests
43
+ run: uv run pytest tests/ -v --tb=short
44
+
45
+ - name: Run tests with coverage
46
+ if: matrix.python-version == '3.10'
47
+ run: |
48
+ uv add --group dev pytest-cov
49
+ uv run pytest tests/ -v --cov=calfkit --cov-report=term-missing --cov-report=xml
50
+
51
+ - name: Upload coverage report
52
+ if: matrix.python-version == '3.10'
53
+ uses: actions/upload-artifact@v6
54
+ with:
55
+ name: coverage-report
56
+ path: coverage.xml
57
+ retention-days: 7
@@ -0,0 +1,44 @@
1
+ # Python
2
+ __pycache__/
3
+ *.py[cod]
4
+ *$py.class
5
+ *.so
6
+
7
+ # Virtual environments
8
+ .venv/
9
+ venv/
10
+ ENV/
11
+
12
+ # Distribution / packaging
13
+ dist/
14
+ build/
15
+ *.egg-info/
16
+ *.egg
17
+
18
+ # Testing
19
+ .pytest_cache/
20
+ .coverage
21
+ htmlcov/
22
+ .tox/
23
+
24
+ # Type checking
25
+ .mypy_cache/
26
+
27
+ # IDEs
28
+ .idea/
29
+ .vscode/
30
+ *.swp
31
+ *.swo
32
+
33
+ # OS
34
+ .DS_Store
35
+ Thumbs.db
36
+
37
+ # Ruff
38
+ .ruff_cache/
39
+
40
+ # uv
41
+ uv.lock
42
+
43
+ # env file
44
+ .env
@@ -0,0 +1,3 @@
1
+ {
2
+ ".": "0.1.1"
3
+ }
@@ -0,0 +1,35 @@
1
+ # Changelog
2
+
3
+ ## [0.1.1](https://github.com/calf-ai/calf-sdk/compare/v0.1.0...v0.1.1) (2026-02-03)
4
+
5
+
6
+ ### Features
7
+
8
+ * add build commands and CI workflows ([#3](https://github.com/calf-ai/calf-sdk/issues/3)) ([fa66282](https://github.com/calf-ai/calf-sdk/commit/fa66282d31c139d6b6579e6e13c54ecf02ab759d))
9
+ * event-driven tool calling + agent routing node + function tool decorator ([#16](https://github.com/calf-ai/calf-sdk/issues/16)) ([5af52bd](https://github.com/calf-ai/calf-sdk/commit/5af52bd779c0b567cf80395063b622ef9d9cc388))
10
+ * high level api structure skeleton ([#8](https://github.com/calf-ai/calf-sdk/issues/8)) ([960b622](https://github.com/calf-ai/calf-sdk/commit/960b622a4966d60f018b73a4e140015c24a2f1bd))
11
+ * implement chat agent node + refactor provider layer ([#12](https://github.com/calf-ai/calf-sdk/issues/12)) ([c2e40c0](https://github.com/calf-ai/calf-sdk/commit/c2e40c0a8e0417f8d3097a786c09ed45144bc0f9))
12
+ * implement event-driven base node pieces and refactor model clients ([#10](https://github.com/calf-ai/calf-sdk/issues/10)) ([bb66af0](https://github.com/calf-ai/calf-sdk/commit/bb66af0a17380e4e892e31442ff68d3e50e4fd8f))
13
+ * implement node-based agent architecture with event-driven messaging ([#15](https://github.com/calf-ai/calf-sdk/issues/15)) ([0bfd190](https://github.com/calf-ai/calf-sdk/commit/0bfd190a60f1c5b9dbf9815c100014078106b27b))
14
+ * message history persistence ([#18](https://github.com/calf-ai/calf-sdk/issues/18)) ([ef6dfae](https://github.com/calf-ai/calf-sdk/commit/ef6dfaee10eff29e71af64bf263dd275f488a78b))
15
+ * MVP agents ([#17](https://github.com/calf-ai/calf-sdk/issues/17)) ([f6141d4](https://github.com/calf-ai/calf-sdk/commit/f6141d46d0f93ff13173cc2249bedd3fd735ecab))
16
+ * openai chat completions client and base client class implementation ([#9](https://github.com/calf-ai/calf-sdk/issues/9)) ([28f6d62](https://github.com/calf-ai/calf-sdk/commit/28f6d62e72ff287b4ee7095992c0da2c07ff5d7c))
17
+ * rename sdk to calfkit ([#26](https://github.com/calf-ai/calf-sdk/issues/26)) ([32d114f](https://github.com/calf-ai/calf-sdk/commit/32d114f14d537da279ebd3975d7df0511648ccfa))
18
+
19
+
20
+ ### Bug Fixes
21
+
22
+ * mypy ci issues ([#23](https://github.com/calf-ai/calf-sdk/issues/23)) ([4429541](https://github.com/calf-ai/calf-sdk/commit/442954193fd6a64517f5cecef005018efec13622))
23
+ * refine sdk and bug fixes ([#24](https://github.com/calf-ai/calf-sdk/issues/24)) ([89a586b](https://github.com/calf-ai/calf-sdk/commit/89a586bd40bfa5d32659a5e97c9f70fd3df38062))
24
+
25
+
26
+ ### Dependencies
27
+
28
+ * update aiokafka requirement from <0.13.0,>=0.10.0 to >=0.10.0,<0.14.0 ([#13](https://github.com/calf-ai/calf-sdk/issues/13)) ([13b5014](https://github.com/calf-ai/calf-sdk/commit/13b501411a569a44a9baadccad821174c91deac7))
29
+ * update typer requirement from <0.20 to <0.22 ([#14](https://github.com/calf-ai/calf-sdk/issues/14)) ([c7ef948](https://github.com/calf-ai/calf-sdk/commit/c7ef9483d75b5cc2cbcfb57dc32e0a01b15b82ab))
30
+
31
+
32
+ ### Documentation
33
+
34
+ * high-level agents, teams, tools API documentation and example code usage snippets ([#6](https://github.com/calf-ai/calf-sdk/issues/6)) ([de81b63](https://github.com/calf-ai/calf-sdk/commit/de81b6353c4659f47302f8f37c78607ce6154f44))
35
+ * update readme consistency ([#7](https://github.com/calf-ai/calf-sdk/issues/7)) ([279ccd1](https://github.com/calf-ai/calf-sdk/commit/279ccd1f5f2b6632ca27fb527e781a588205a419))
@@ -0,0 +1 @@
1
+ This project uses uv for dependency management.
calfkit-0.1.1/LICENSE ADDED
@@ -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 Ryan Yu
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.