Update original file workflows and audit tasks
Browse filesThis view is limited to 50 files because it contains too many changes. See raw diff
- LICENSES/CC-BY-4.0.txt +0 -395
- LICENSES/MIT-Python-Repair.txt +0 -21
- LICENSES/MIT-adapters.txt +0 -21
- LICENSES/ODC-BY-1.0.txt +0 -428
- LICENSES/README.txt +5 -10
- LICENSES/TMax-NOTICE.txt +0 -6
- MANIFEST.json +387 -733
- README.md +10 -17
- REGISTRATION.json +0 -24
- SHA256SUMS +115 -202
- SOURCE_LOCK.json +0 -0
- components/audit/Dockerfile +12 -0
- components/audit/NOTICE +3 -0
- components/audit/README.md +1 -0
- components/audit/SOURCE.json +22 -0
- components/audit/config.json +44 -0
- components/audit/runtime/audit/__init__.py +0 -0
- components/audit/runtime/audit/environment.py +128 -0
- components/{math/runtime/native_shell → audit/runtime/audit}/server.py +5 -5
- components/{awm/runtime/awm → audit/runtime/common}/__init__.py +0 -0
- components/{awm → audit}/runtime/common/contracts.py +0 -0
- components/{pdbthink → audit}/runtime/common/models.py +3 -2
- components/audit/tasks/auth-05/instruction.md +1 -0
- components/audit/tasks/ledger-01/instruction.md +1 -0
- LICENSES/Apache-2.0-PDBThink.txt → components/audit/upstream/LICENSE +1 -0
- components/audit/upstream/audit_trail/__init__.py +10 -0
- components/audit/upstream/audit_trail/models.py +33 -0
- components/audit/upstream/audit_trail/server/__init__.py +7 -0
- components/audit/upstream/audit_trail/server/audit_trail_environment.py +111 -0
- components/audit/upstream/audit_trail/tasks.py +381 -0
- components/audit/upstream/dataset/README.md +57 -0
- components/audit/upstream/dataset/tasks.jsonl +24 -0
- components/awm/ADAPTATIONS.txt +0 -4
- components/awm/Dockerfile +0 -5
- components/awm/LICENSE_SCOPE.json +0 -22
- components/awm/NOTICE +0 -6
- components/awm/SOURCE_CREDITS.json +0 -9
- components/awm/TASKS.json +0 -36
- components/awm/awm-requirements.lock +0 -44
- components/awm/config.json +0 -15
- components/awm/private/tasks/awm-accounting-1-invoice/SOURCE.json +0 -11
- components/awm/private/tasks/awm-accounting-1-invoice/initial.db +0 -3
- components/awm/private/tasks/awm-accounting-1-invoice/original_api.py +0 -1767
- components/awm/private/tasks/awm-accounting-1-invoice/original_verifier.py +0 -145
- components/awm/requirements.lock +0 -112
- components/awm/runtime/awm/adapter.py +0 -92
- components/awm/runtime/awm/launch_service.py +0 -52
- components/awm/runtime/awm/openenv_app.py +0 -95
- components/awm/runtime/awm/server.py +0 -31
- components/awm/runtime/awm/wire_client.py +0 -123
LICENSES/CC-BY-4.0.txt
DELETED
|
@@ -1,395 +0,0 @@
|
|
| 1 |
-
Attribution 4.0 International
|
| 2 |
-
|
| 3 |
-
=======================================================================
|
| 4 |
-
|
| 5 |
-
Creative Commons Corporation ("Creative Commons") is not a law firm and
|
| 6 |
-
does not provide legal services or legal advice. Distribution of
|
| 7 |
-
Creative Commons public licenses does not create a lawyer-client or
|
| 8 |
-
other relationship. Creative Commons makes its licenses and related
|
| 9 |
-
information available on an "as-is" basis. Creative Commons gives no
|
| 10 |
-
warranties regarding its licenses, any material licensed under their
|
| 11 |
-
terms and conditions, or any related information. Creative Commons
|
| 12 |
-
disclaims all liability for damages resulting from their use to the
|
| 13 |
-
fullest extent possible.
|
| 14 |
-
|
| 15 |
-
Using Creative Commons Public Licenses
|
| 16 |
-
|
| 17 |
-
Creative Commons public licenses provide a standard set of terms and
|
| 18 |
-
conditions that creators and other rights holders may use to share
|
| 19 |
-
original works of authorship and other material subject to copyright
|
| 20 |
-
and certain other rights specified in the public license below. The
|
| 21 |
-
following considerations are for informational purposes only, are not
|
| 22 |
-
exhaustive, and do not form part of our licenses.
|
| 23 |
-
|
| 24 |
-
Considerations for licensors: Our public licenses are
|
| 25 |
-
intended for use by those authorized to give the public
|
| 26 |
-
permission to use material in ways otherwise restricted by
|
| 27 |
-
copyright and certain other rights. Our licenses are
|
| 28 |
-
irrevocable. Licensors should read and understand the terms
|
| 29 |
-
and conditions of the license they choose before applying it.
|
| 30 |
-
Licensors should also secure all rights necessary before
|
| 31 |
-
applying our licenses so that the public can reuse the
|
| 32 |
-
material as expected. Licensors should clearly mark any
|
| 33 |
-
material not subject to the license. This includes other CC-
|
| 34 |
-
licensed material, or material used under an exception or
|
| 35 |
-
limitation to copyright. More considerations for licensors:
|
| 36 |
-
wiki.creativecommons.org/Considerations_for_licensors
|
| 37 |
-
|
| 38 |
-
Considerations for the public: By using one of our public
|
| 39 |
-
licenses, a licensor grants the public permission to use the
|
| 40 |
-
licensed material under specified terms and conditions. If
|
| 41 |
-
the licensor's permission is not necessary for any reason--for
|
| 42 |
-
example, because of any applicable exception or limitation to
|
| 43 |
-
copyright--then that use is not regulated by the license. Our
|
| 44 |
-
licenses grant only permissions under copyright and certain
|
| 45 |
-
other rights that a licensor has authority to grant. Use of
|
| 46 |
-
the licensed material may still be restricted for other
|
| 47 |
-
reasons, including because others have copyright or other
|
| 48 |
-
rights in the material. A licensor may make special requests,
|
| 49 |
-
such as asking that all changes be marked or described.
|
| 50 |
-
Although not required by our licenses, you are encouraged to
|
| 51 |
-
respect those requests where reasonable. More considerations
|
| 52 |
-
for the public:
|
| 53 |
-
wiki.creativecommons.org/Considerations_for_licensees
|
| 54 |
-
|
| 55 |
-
=======================================================================
|
| 56 |
-
|
| 57 |
-
Creative Commons Attribution 4.0 International Public License
|
| 58 |
-
|
| 59 |
-
By exercising the Licensed Rights (defined below), You accept and agree
|
| 60 |
-
to be bound by the terms and conditions of this Creative Commons
|
| 61 |
-
Attribution 4.0 International Public License ("Public License"). To the
|
| 62 |
-
extent this Public License may be interpreted as a contract, You are
|
| 63 |
-
granted the Licensed Rights in consideration of Your acceptance of
|
| 64 |
-
these terms and conditions, and the Licensor grants You such rights in
|
| 65 |
-
consideration of benefits the Licensor receives from making the
|
| 66 |
-
Licensed Material available under these terms and conditions.
|
| 67 |
-
|
| 68 |
-
|
| 69 |
-
Section 1 -- Definitions.
|
| 70 |
-
|
| 71 |
-
a. Adapted Material means material subject to Copyright and Similar
|
| 72 |
-
Rights that is derived from or based upon the Licensed Material
|
| 73 |
-
and in which the Licensed Material is translated, altered,
|
| 74 |
-
arranged, transformed, or otherwise modified in a manner requiring
|
| 75 |
-
permission under the Copyright and Similar Rights held by the
|
| 76 |
-
Licensor. For purposes of this Public License, where the Licensed
|
| 77 |
-
Material is a musical work, performance, or sound recording,
|
| 78 |
-
Adapted Material is always produced where the Licensed Material is
|
| 79 |
-
synched in timed relation with a moving image.
|
| 80 |
-
|
| 81 |
-
b. Adapter's License means the license You apply to Your Copyright
|
| 82 |
-
and Similar Rights in Your contributions to Adapted Material in
|
| 83 |
-
accordance with the terms and conditions of this Public License.
|
| 84 |
-
|
| 85 |
-
c. Copyright and Similar Rights means copyright and/or similar rights
|
| 86 |
-
closely related to copyright including, without limitation,
|
| 87 |
-
performance, broadcast, sound recording, and Sui Generis Database
|
| 88 |
-
Rights, without regard to how the rights are labeled or
|
| 89 |
-
categorized. For purposes of this Public License, the rights
|
| 90 |
-
specified in Section 2(b)(1)-(2) are not Copyright and Similar
|
| 91 |
-
Rights.
|
| 92 |
-
|
| 93 |
-
d. Effective Technological Measures means those measures that, in the
|
| 94 |
-
absence of proper authority, may not be circumvented under laws
|
| 95 |
-
fulfilling obligations under Article 11 of the WIPO Copyright
|
| 96 |
-
Treaty adopted on December 20, 1996, and/or similar international
|
| 97 |
-
agreements.
|
| 98 |
-
|
| 99 |
-
e. Exceptions and Limitations means fair use, fair dealing, and/or
|
| 100 |
-
any other exception or limitation to Copyright and Similar Rights
|
| 101 |
-
that applies to Your use of the Licensed Material.
|
| 102 |
-
|
| 103 |
-
f. Licensed Material means the artistic or literary work, database,
|
| 104 |
-
or other material to which the Licensor applied this Public
|
| 105 |
-
License.
|
| 106 |
-
|
| 107 |
-
g. Licensed Rights means the rights granted to You subject to the
|
| 108 |
-
terms and conditions of this Public License, which are limited to
|
| 109 |
-
all Copyright and Similar Rights that apply to Your use of the
|
| 110 |
-
Licensed Material and that the Licensor has authority to license.
|
| 111 |
-
|
| 112 |
-
h. Licensor means the individual(s) or entity(ies) granting rights
|
| 113 |
-
under this Public License.
|
| 114 |
-
|
| 115 |
-
i. Share means to provide material to the public by any means or
|
| 116 |
-
process that requires permission under the Licensed Rights, such
|
| 117 |
-
as reproduction, public display, public performance, distribution,
|
| 118 |
-
dissemination, communication, or importation, and to make material
|
| 119 |
-
available to the public including in ways that members of the
|
| 120 |
-
public may access the material from a place and at a time
|
| 121 |
-
individually chosen by them.
|
| 122 |
-
|
| 123 |
-
j. Sui Generis Database Rights means rights other than copyright
|
| 124 |
-
resulting from Directive 96/9/EC of the European Parliament and of
|
| 125 |
-
the Council of 11 March 1996 on the legal protection of databases,
|
| 126 |
-
as amended and/or succeeded, as well as other essentially
|
| 127 |
-
equivalent rights anywhere in the world.
|
| 128 |
-
|
| 129 |
-
k. You means the individual or entity exercising the Licensed Rights
|
| 130 |
-
under this Public License. Your has a corresponding meaning.
|
| 131 |
-
|
| 132 |
-
|
| 133 |
-
Section 2 -- Scope.
|
| 134 |
-
|
| 135 |
-
a. License grant.
|
| 136 |
-
|
| 137 |
-
1. Subject to the terms and conditions of this Public License,
|
| 138 |
-
the Licensor hereby grants You a worldwide, royalty-free,
|
| 139 |
-
non-sublicensable, non-exclusive, irrevocable license to
|
| 140 |
-
exercise the Licensed Rights in the Licensed Material to:
|
| 141 |
-
|
| 142 |
-
a. reproduce and Share the Licensed Material, in whole or
|
| 143 |
-
in part; and
|
| 144 |
-
|
| 145 |
-
b. produce, reproduce, and Share Adapted Material.
|
| 146 |
-
|
| 147 |
-
2. Exceptions and Limitations. For the avoidance of doubt, where
|
| 148 |
-
Exceptions and Limitations apply to Your use, this Public
|
| 149 |
-
License does not apply, and You do not need to comply with
|
| 150 |
-
its terms and conditions.
|
| 151 |
-
|
| 152 |
-
3. Term. The term of this Public License is specified in Section
|
| 153 |
-
6(a).
|
| 154 |
-
|
| 155 |
-
4. Media and formats; technical modifications allowed. The
|
| 156 |
-
Licensor authorizes You to exercise the Licensed Rights in
|
| 157 |
-
all media and formats whether now known or hereafter created,
|
| 158 |
-
and to make technical modifications necessary to do so. The
|
| 159 |
-
Licensor waives and/or agrees not to assert any right or
|
| 160 |
-
authority to forbid You from making technical modifications
|
| 161 |
-
necessary to exercise the Licensed Rights, including
|
| 162 |
-
technical modifications necessary to circumvent Effective
|
| 163 |
-
Technological Measures. For purposes of this Public License,
|
| 164 |
-
simply making modifications authorized by this Section 2(a)
|
| 165 |
-
(4) never produces Adapted Material.
|
| 166 |
-
|
| 167 |
-
5. Downstream recipients.
|
| 168 |
-
|
| 169 |
-
a. Offer from the Licensor -- Licensed Material. Every
|
| 170 |
-
recipient of the Licensed Material automatically
|
| 171 |
-
receives an offer from the Licensor to exercise the
|
| 172 |
-
Licensed Rights under the terms and conditions of this
|
| 173 |
-
Public License.
|
| 174 |
-
|
| 175 |
-
b. No downstream restrictions. You may not offer or impose
|
| 176 |
-
any additional or different terms or conditions on, or
|
| 177 |
-
apply any Effective Technological Measures to, the
|
| 178 |
-
Licensed Material if doing so restricts exercise of the
|
| 179 |
-
Licensed Rights by any recipient of the Licensed
|
| 180 |
-
Material.
|
| 181 |
-
|
| 182 |
-
6. No endorsement. Nothing in this Public License constitutes or
|
| 183 |
-
may be construed as permission to assert or imply that You
|
| 184 |
-
are, or that Your use of the Licensed Material is, connected
|
| 185 |
-
with, or sponsored, endorsed, or granted official status by,
|
| 186 |
-
the Licensor or others designated to receive attribution as
|
| 187 |
-
provided in Section 3(a)(1)(A)(i).
|
| 188 |
-
|
| 189 |
-
b. Other rights.
|
| 190 |
-
|
| 191 |
-
1. Moral rights, such as the right of integrity, are not
|
| 192 |
-
licensed under this Public License, nor are publicity,
|
| 193 |
-
privacy, and/or other similar personality rights; however, to
|
| 194 |
-
the extent possible, the Licensor waives and/or agrees not to
|
| 195 |
-
assert any such rights held by the Licensor to the limited
|
| 196 |
-
extent necessary to allow You to exercise the Licensed
|
| 197 |
-
Rights, but not otherwise.
|
| 198 |
-
|
| 199 |
-
2. Patent and trademark rights are not licensed under this
|
| 200 |
-
Public License.
|
| 201 |
-
|
| 202 |
-
3. To the extent possible, the Licensor waives any right to
|
| 203 |
-
collect royalties from You for the exercise of the Licensed
|
| 204 |
-
Rights, whether directly or through a collecting society
|
| 205 |
-
under any voluntary or waivable statutory or compulsory
|
| 206 |
-
licensing scheme. In all other cases the Licensor expressly
|
| 207 |
-
reserves any right to collect such royalties.
|
| 208 |
-
|
| 209 |
-
|
| 210 |
-
Section 3 -- License Conditions.
|
| 211 |
-
|
| 212 |
-
Your exercise of the Licensed Rights is expressly made subject to the
|
| 213 |
-
following conditions.
|
| 214 |
-
|
| 215 |
-
a. Attribution.
|
| 216 |
-
|
| 217 |
-
1. If You Share the Licensed Material (including in modified
|
| 218 |
-
form), You must:
|
| 219 |
-
|
| 220 |
-
a. retain the following if it is supplied by the Licensor
|
| 221 |
-
with the Licensed Material:
|
| 222 |
-
|
| 223 |
-
i. identification of the creator(s) of the Licensed
|
| 224 |
-
Material and any others designated to receive
|
| 225 |
-
attribution, in any reasonable manner requested by
|
| 226 |
-
the Licensor (including by pseudonym if
|
| 227 |
-
designated);
|
| 228 |
-
|
| 229 |
-
ii. a copyright notice;
|
| 230 |
-
|
| 231 |
-
iii. a notice that refers to this Public License;
|
| 232 |
-
|
| 233 |
-
iv. a notice that refers to the disclaimer of
|
| 234 |
-
warranties;
|
| 235 |
-
|
| 236 |
-
v. a URI or hyperlink to the Licensed Material to the
|
| 237 |
-
extent reasonably practicable;
|
| 238 |
-
|
| 239 |
-
b. indicate if You modified the Licensed Material and
|
| 240 |
-
retain an indication of any previous modifications; and
|
| 241 |
-
|
| 242 |
-
c. indicate the Licensed Material is licensed under this
|
| 243 |
-
Public License, and include the text of, or the URI or
|
| 244 |
-
hyperlink to, this Public License.
|
| 245 |
-
|
| 246 |
-
2. You may satisfy the conditions in Section 3(a)(1) in any
|
| 247 |
-
reasonable manner based on the medium, means, and context in
|
| 248 |
-
which You Share the Licensed Material. For example, it may be
|
| 249 |
-
reasonable to satisfy the conditions by providing a URI or
|
| 250 |
-
hyperlink to a resource that includes the required
|
| 251 |
-
information.
|
| 252 |
-
|
| 253 |
-
3. If requested by the Licensor, You must remove any of the
|
| 254 |
-
information required by Section 3(a)(1)(A) to the extent
|
| 255 |
-
reasonably practicable.
|
| 256 |
-
|
| 257 |
-
4. If You Share Adapted Material You produce, the Adapter's
|
| 258 |
-
License You apply must not prevent recipients of the Adapted
|
| 259 |
-
Material from complying with this Public License.
|
| 260 |
-
|
| 261 |
-
|
| 262 |
-
Section 4 -- Sui Generis Database Rights.
|
| 263 |
-
|
| 264 |
-
Where the Licensed Rights include Sui Generis Database Rights that
|
| 265 |
-
apply to Your use of the Licensed Material:
|
| 266 |
-
|
| 267 |
-
a. for the avoidance of doubt, Section 2(a)(1) grants You the right
|
| 268 |
-
to extract, reuse, reproduce, and Share all or a substantial
|
| 269 |
-
portion of the contents of the database;
|
| 270 |
-
|
| 271 |
-
b. if You include all or a substantial portion of the database
|
| 272 |
-
contents in a database in which You have Sui Generis Database
|
| 273 |
-
Rights, then the database in which You have Sui Generis Database
|
| 274 |
-
Rights (but not its individual contents) is Adapted Material; and
|
| 275 |
-
|
| 276 |
-
c. You must comply with the conditions in Section 3(a) if You Share
|
| 277 |
-
all or a substantial portion of the contents of the database.
|
| 278 |
-
|
| 279 |
-
For the avoidance of doubt, this Section 4 supplements and does not
|
| 280 |
-
replace Your obligations under this Public License where the Licensed
|
| 281 |
-
Rights include other Copyright and Similar Rights.
|
| 282 |
-
|
| 283 |
-
|
| 284 |
-
Section 5 -- Disclaimer of Warranties and Limitation of Liability.
|
| 285 |
-
|
| 286 |
-
a. UNLESS OTHERWISE SEPARATELY UNDERTAKEN BY THE LICENSOR, TO THE
|
| 287 |
-
EXTENT POSSIBLE, THE LICENSOR OFFERS THE LICENSED MATERIAL AS-IS
|
| 288 |
-
AND AS-AVAILABLE, AND MAKES NO REPRESENTATIONS OR WARRANTIES OF
|
| 289 |
-
ANY KIND CONCERNING THE LICENSED MATERIAL, WHETHER EXPRESS,
|
| 290 |
-
IMPLIED, STATUTORY, OR OTHER. THIS INCLUDES, WITHOUT LIMITATION,
|
| 291 |
-
WARRANTIES OF TITLE, MERCHANTABILITY, FITNESS FOR A PARTICULAR
|
| 292 |
-
PURPOSE, NON-INFRINGEMENT, ABSENCE OF LATENT OR OTHER DEFECTS,
|
| 293 |
-
ACCURACY, OR THE PRESENCE OR ABSENCE OF ERRORS, WHETHER OR NOT
|
| 294 |
-
KNOWN OR DISCOVERABLE. WHERE DISCLAIMERS OF WARRANTIES ARE NOT
|
| 295 |
-
ALLOWED IN FULL OR IN PART, THIS DISCLAIMER MAY NOT APPLY TO YOU.
|
| 296 |
-
|
| 297 |
-
b. TO THE EXTENT POSSIBLE, IN NO EVENT WILL THE LICENSOR BE LIABLE
|
| 298 |
-
TO YOU ON ANY LEGAL THEORY (INCLUDING, WITHOUT LIMITATION,
|
| 299 |
-
NEGLIGENCE) OR OTHERWISE FOR ANY DIRECT, SPECIAL, INDIRECT,
|
| 300 |
-
INCIDENTAL, CONSEQUENTIAL, PUNITIVE, EXEMPLARY, OR OTHER LOSSES,
|
| 301 |
-
COSTS, EXPENSES, OR DAMAGES ARISING OUT OF THIS PUBLIC LICENSE OR
|
| 302 |
-
USE OF THE LICENSED MATERIAL, EVEN IF THE LICENSOR HAS BEEN
|
| 303 |
-
ADVISED OF THE POSSIBILITY OF SUCH LOSSES, COSTS, EXPENSES, OR
|
| 304 |
-
DAMAGES. WHERE A LIMITATION OF LIABILITY IS NOT ALLOWED IN FULL OR
|
| 305 |
-
IN PART, THIS LIMITATION MAY NOT APPLY TO YOU.
|
| 306 |
-
|
| 307 |
-
c. The disclaimer of warranties and limitation of liability provided
|
| 308 |
-
above shall be interpreted in a manner that, to the extent
|
| 309 |
-
possible, most closely approximates an absolute disclaimer and
|
| 310 |
-
waiver of all liability.
|
| 311 |
-
|
| 312 |
-
|
| 313 |
-
Section 6 -- Term and Termination.
|
| 314 |
-
|
| 315 |
-
a. This Public License applies for the term of the Copyright and
|
| 316 |
-
Similar Rights licensed here. However, if You fail to comply with
|
| 317 |
-
this Public License, then Your rights under this Public License
|
| 318 |
-
terminate automatically.
|
| 319 |
-
|
| 320 |
-
b. Where Your right to use the Licensed Material has terminated under
|
| 321 |
-
Section 6(a), it reinstates:
|
| 322 |
-
|
| 323 |
-
1. automatically as of the date the violation is cured, provided
|
| 324 |
-
it is cured within 30 days of Your discovery of the
|
| 325 |
-
violation; or
|
| 326 |
-
|
| 327 |
-
2. upon express reinstatement by the Licensor.
|
| 328 |
-
|
| 329 |
-
For the avoidance of doubt, this Section 6(b) does not affect any
|
| 330 |
-
right the Licensor may have to seek remedies for Your violations
|
| 331 |
-
of this Public License.
|
| 332 |
-
|
| 333 |
-
c. For the avoidance of doubt, the Licensor may also offer the
|
| 334 |
-
Licensed Material under separate terms or conditions or stop
|
| 335 |
-
distributing the Licensed Material at any time; however, doing so
|
| 336 |
-
will not terminate this Public License.
|
| 337 |
-
|
| 338 |
-
d. Sections 1, 5, 6, 7, and 8 survive termination of this Public
|
| 339 |
-
License.
|
| 340 |
-
|
| 341 |
-
|
| 342 |
-
Section 7 -- Other Terms and Conditions.
|
| 343 |
-
|
| 344 |
-
a. The Licensor shall not be bound by any additional or different
|
| 345 |
-
terms or conditions communicated by You unless expressly agreed.
|
| 346 |
-
|
| 347 |
-
b. Any arrangements, understandings, or agreements regarding the
|
| 348 |
-
Licensed Material not stated herein are separate from and
|
| 349 |
-
independent of the terms and conditions of this Public License.
|
| 350 |
-
|
| 351 |
-
|
| 352 |
-
Section 8 -- Interpretation.
|
| 353 |
-
|
| 354 |
-
a. For the avoidance of doubt, this Public License does not, and
|
| 355 |
-
shall not be interpreted to, reduce, limit, restrict, or impose
|
| 356 |
-
conditions on any use of the Licensed Material that could lawfully
|
| 357 |
-
be made without permission under this Public License.
|
| 358 |
-
|
| 359 |
-
b. To the extent possible, if any provision of this Public License is
|
| 360 |
-
deemed unenforceable, it shall be automatically reformed to the
|
| 361 |
-
minimum extent necessary to make it enforceable. If the provision
|
| 362 |
-
cannot be reformed, it shall be severed from this Public License
|
| 363 |
-
without affecting the enforceability of the remaining terms and
|
| 364 |
-
conditions.
|
| 365 |
-
|
| 366 |
-
c. No term or condition of this Public License will be waived and no
|
| 367 |
-
failure to comply consented to unless expressly agreed to by the
|
| 368 |
-
Licensor.
|
| 369 |
-
|
| 370 |
-
d. Nothing in this Public License constitutes or may be interpreted
|
| 371 |
-
as a limitation upon, or waiver of, any privileges and immunities
|
| 372 |
-
that apply to the Licensor or You, including from the legal
|
| 373 |
-
processes of any jurisdiction or authority.
|
| 374 |
-
|
| 375 |
-
|
| 376 |
-
=======================================================================
|
| 377 |
-
|
| 378 |
-
Creative Commons is not a party to its public
|
| 379 |
-
licenses. Notwithstanding, Creative Commons may elect to apply one of
|
| 380 |
-
its public licenses to material it publishes and in those instances
|
| 381 |
-
will be considered the “Licensor.” The text of the Creative Commons
|
| 382 |
-
public licenses is dedicated to the public domain under the CC0 Public
|
| 383 |
-
Domain Dedication. Except for the limited purpose of indicating that
|
| 384 |
-
material is shared under a Creative Commons public license or as
|
| 385 |
-
otherwise permitted by the Creative Commons policies published at
|
| 386 |
-
creativecommons.org/policies, Creative Commons does not authorize the
|
| 387 |
-
use of the trademark "Creative Commons" or any other trademark or logo
|
| 388 |
-
of Creative Commons without its prior written consent including,
|
| 389 |
-
without limitation, in connection with any unauthorized modifications
|
| 390 |
-
to any of its public licenses or any other arrangements,
|
| 391 |
-
understandings, or agreements concerning use of licensed material. For
|
| 392 |
-
the avoidance of doubt, this paragraph does not form part of the
|
| 393 |
-
public licenses.
|
| 394 |
-
|
| 395 |
-
Creative Commons may be contacted at creativecommons.org.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
LICENSES/MIT-Python-Repair.txt
DELETED
|
@@ -1,21 +0,0 @@
|
|
| 1 |
-
MIT License
|
| 2 |
-
|
| 3 |
-
Copyright (c) 2026 Louis Grenard
|
| 4 |
-
|
| 5 |
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
| 6 |
-
of this software and associated documentation files (the "Software"), to deal
|
| 7 |
-
in the Software without restriction, including without limitation the rights
|
| 8 |
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
| 9 |
-
copies of the Software, and to permit persons to whom the Software is
|
| 10 |
-
furnished to do so, subject to the following conditions:
|
| 11 |
-
|
| 12 |
-
The above copyright notice and this permission notice shall be included in all
|
| 13 |
-
copies or substantial portions of the Software.
|
| 14 |
-
|
| 15 |
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
| 16 |
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
| 17 |
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
| 18 |
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
| 19 |
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
| 20 |
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
| 21 |
-
SOFTWARE.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
LICENSES/MIT-adapters.txt
DELETED
|
@@ -1,21 +0,0 @@
|
|
| 1 |
-
MIT License
|
| 2 |
-
|
| 3 |
-
Copyright (c) 2026 Complete Work contributors
|
| 4 |
-
|
| 5 |
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
| 6 |
-
of this software and associated documentation files (the "Software"), to deal
|
| 7 |
-
in the Software without restriction, including without limitation the rights
|
| 8 |
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
| 9 |
-
copies of the Software, and to permit persons to whom the Software is
|
| 10 |
-
furnished to do so, subject to the following conditions:
|
| 11 |
-
|
| 12 |
-
The above copyright notice and this permission notice shall be included in all
|
| 13 |
-
copies or substantial portions of the Software.
|
| 14 |
-
|
| 15 |
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
| 16 |
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
| 17 |
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
| 18 |
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
| 19 |
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
| 20 |
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
| 21 |
-
SOFTWARE.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
LICENSES/ODC-BY-1.0.txt
DELETED
|
@@ -1,428 +0,0 @@
|
|
| 1 |
-
# ODC Attribution License (ODC-By)
|
| 2 |
-
|
| 3 |
-
### Preamble
|
| 4 |
-
|
| 5 |
-
The Open Data Commons Attribution License is a license agreement
|
| 6 |
-
intended to allow users to freely share, modify, and use this Database
|
| 7 |
-
subject only to the attribution requirements set out in Section 4.
|
| 8 |
-
|
| 9 |
-
Databases can contain a wide variety of types of content (images,
|
| 10 |
-
audiovisual material, and sounds all in the same database, for example),
|
| 11 |
-
and so this license only governs the rights over the Database, and not
|
| 12 |
-
the contents of the Database individually. Licensors may therefore wish
|
| 13 |
-
to use this license together with another license for the contents.
|
| 14 |
-
|
| 15 |
-
Sometimes the contents of a database, or the database itself, can be
|
| 16 |
-
covered by other rights not addressed here (such as private contracts,
|
| 17 |
-
trademark over the name, or privacy rights / data protection rights
|
| 18 |
-
over information in the contents), and so you are advised that you may
|
| 19 |
-
have to consult other documents or clear other rights before doing
|
| 20 |
-
activities not covered by this License.
|
| 21 |
-
|
| 22 |
-
------
|
| 23 |
-
|
| 24 |
-
The Licensor (as defined below)
|
| 25 |
-
|
| 26 |
-
and
|
| 27 |
-
|
| 28 |
-
You (as defined below)
|
| 29 |
-
|
| 30 |
-
agree as follows:
|
| 31 |
-
|
| 32 |
-
### 1.0 Definitions of Capitalised Words
|
| 33 |
-
|
| 34 |
-
"Collective Database" - Means this Database in unmodified form as part
|
| 35 |
-
of a collection of independent databases in themselves that together are
|
| 36 |
-
assembled into a collective whole. A work that constitutes a Collective
|
| 37 |
-
Database will not be considered a Derivative Database.
|
| 38 |
-
|
| 39 |
-
"Convey" - As a verb, means Using the Database, a Derivative Database,
|
| 40 |
-
or the Database as part of a Collective Database in any way that enables
|
| 41 |
-
a Person to make or receive copies of the Database or a Derivative
|
| 42 |
-
Database. Conveying does not include interaction with a user through a
|
| 43 |
-
computer network, or creating and Using a Produced Work, where no
|
| 44 |
-
transfer of a copy of the Database or a Derivative Database occurs.
|
| 45 |
-
|
| 46 |
-
"Contents" - The contents of this Database, which includes the
|
| 47 |
-
information, independent works, or other material collected into the
|
| 48 |
-
Database. For example, the contents of the Database could be factual
|
| 49 |
-
data or works such as images, audiovisual material, text, or sounds.
|
| 50 |
-
|
| 51 |
-
"Database" - A collection of material (the Contents) arranged in a
|
| 52 |
-
systematic or methodical way and individually accessible by electronic
|
| 53 |
-
or other means offered under the terms of this License.
|
| 54 |
-
|
| 55 |
-
"Database Directive" - Means Directive 96/9/EC of the European
|
| 56 |
-
Parliament and of the Council of 11 March 1996 on the legal protection
|
| 57 |
-
of databases, as amended or succeeded.
|
| 58 |
-
|
| 59 |
-
"Database Right" - Means rights resulting from the Chapter III ("sui
|
| 60 |
-
generis") rights in the Database Directive (as amended and as transposed
|
| 61 |
-
by member states), which includes the Extraction and Re-utilisation of
|
| 62 |
-
the whole or a Substantial part of the Contents, as well as any similar
|
| 63 |
-
rights available in the relevant jurisdiction under Section 10.4.
|
| 64 |
-
|
| 65 |
-
"Derivative Database" - Means a database based upon the Database, and
|
| 66 |
-
includes any translation, adaptation, arrangement, modification, or any
|
| 67 |
-
other alteration of the Database or of a Substantial part of the
|
| 68 |
-
Contents. This includes, but is not limited to, Extracting or
|
| 69 |
-
Re-utilising the whole or a Substantial part of the Contents in a new
|
| 70 |
-
Database.
|
| 71 |
-
|
| 72 |
-
"Extraction" - Means the permanent or temporary transfer of all or a
|
| 73 |
-
Substantial part of the Contents to another medium by any means or in
|
| 74 |
-
any form.
|
| 75 |
-
|
| 76 |
-
"License" - Means this license agreement and is both a license of rights
|
| 77 |
-
such as copyright and Database Rights and an agreement in contract.
|
| 78 |
-
|
| 79 |
-
"Licensor" - Means the Person that offers the Database under the terms
|
| 80 |
-
of this License.
|
| 81 |
-
|
| 82 |
-
"Person" - Means a natural or legal person or a body of persons
|
| 83 |
-
corporate or incorporate.
|
| 84 |
-
|
| 85 |
-
"Produced Work" - a work (such as an image, audiovisual material, text,
|
| 86 |
-
or sounds) resulting from using the whole or a Substantial part of the
|
| 87 |
-
Contents (via a search or other query) from this Database, a Derivative
|
| 88 |
-
Database, or this Database as part of a Collective Database.
|
| 89 |
-
|
| 90 |
-
"Publicly" - means to Persons other than You or under Your control by
|
| 91 |
-
either more than 50% ownership or by the power to direct their
|
| 92 |
-
activities (such as contracting with an independent consultant).
|
| 93 |
-
|
| 94 |
-
"Re-utilisation" - means any form of making available to the public all
|
| 95 |
-
or a Substantial part of the Contents by the distribution of copies, by
|
| 96 |
-
renting, by online or other forms of transmission.
|
| 97 |
-
|
| 98 |
-
"Substantial" - Means substantial in terms of quantity or quality or a
|
| 99 |
-
combination of both. The repeated and systematic Extraction or
|
| 100 |
-
Re-utilisation of insubstantial parts of the Contents may amount to the
|
| 101 |
-
Extraction or Re-utilisation of a Substantial part of the Contents.
|
| 102 |
-
|
| 103 |
-
"Use" - As a verb, means doing any act that is restricted by copyright
|
| 104 |
-
or Database Rights whether in the original medium or any other; and
|
| 105 |
-
includes without limitation distributing, copying, publicly performing,
|
| 106 |
-
publicly displaying, and preparing derivative works of the Database, as
|
| 107 |
-
well as modifying the Database as may be technically necessary to use it
|
| 108 |
-
in a different mode or format.
|
| 109 |
-
|
| 110 |
-
"You" - Means a Person exercising rights under this License who has not
|
| 111 |
-
previously violated the terms of this License with respect to the
|
| 112 |
-
Database, or who has received express permission from the Licensor to
|
| 113 |
-
exercise rights under this License despite a previous violation.
|
| 114 |
-
|
| 115 |
-
Words in the singular include the plural and vice versa.
|
| 116 |
-
|
| 117 |
-
### 2.0 What this License covers
|
| 118 |
-
|
| 119 |
-
2.1. Legal effect of this document. This License is:
|
| 120 |
-
|
| 121 |
-
a. A license of applicable copyright and neighbouring rights;
|
| 122 |
-
|
| 123 |
-
b. A license of the Database Right; and
|
| 124 |
-
|
| 125 |
-
c. An agreement in contract between You and the Licensor.
|
| 126 |
-
|
| 127 |
-
2.2 Legal rights covered. This License covers the legal rights in the
|
| 128 |
-
Database, including:
|
| 129 |
-
|
| 130 |
-
a. Copyright. Any copyright or neighbouring rights in the Database.
|
| 131 |
-
The copyright licensed includes any individual elements of the
|
| 132 |
-
Database, but does not cover the copyright over the Contents
|
| 133 |
-
independent of this Database. See Section 2.4 for details. Copyright
|
| 134 |
-
law varies between jurisdictions, but is likely to cover: the Database
|
| 135 |
-
model or schema, which is the structure, arrangement, and organisation
|
| 136 |
-
of the Database, and can also include the Database tables and table
|
| 137 |
-
indexes; the data entry and output sheets; and the Field names of
|
| 138 |
-
Contents stored in the Database;
|
| 139 |
-
|
| 140 |
-
b. Database Rights. Database Rights only extend to the Extraction and
|
| 141 |
-
Re-utilisation of the whole or a Substantial part of the Contents.
|
| 142 |
-
Database Rights can apply even when there is no copyright over the
|
| 143 |
-
Database. Database Rights can also apply when the Contents are removed
|
| 144 |
-
from the Database and are selected and arranged in a way that would
|
| 145 |
-
not infringe any applicable copyright; and
|
| 146 |
-
|
| 147 |
-
c. Contract. This is an agreement between You and the Licensor for
|
| 148 |
-
access to the Database. In return you agree to certain conditions of
|
| 149 |
-
use on this access as outlined in this License.
|
| 150 |
-
|
| 151 |
-
2.3 Rights not covered.
|
| 152 |
-
|
| 153 |
-
a. This License does not apply to computer programs used in the making
|
| 154 |
-
or operation of the Database;
|
| 155 |
-
|
| 156 |
-
b. This License does not cover any patents over the Contents or the
|
| 157 |
-
Database; and
|
| 158 |
-
|
| 159 |
-
c. This License does not cover any trademarks associated with the
|
| 160 |
-
Database.
|
| 161 |
-
|
| 162 |
-
2.4 Relationship to Contents in the Database. The individual items of
|
| 163 |
-
the Contents contained in this Database may be covered by other rights,
|
| 164 |
-
including copyright, patent, data protection, privacy, or personality
|
| 165 |
-
rights, and this License does not cover any rights (other than Database
|
| 166 |
-
Rights or in contract) in individual Contents contained in the Database.
|
| 167 |
-
For example, if used on a Database of images (the Contents), this
|
| 168 |
-
License would not apply to copyright over individual images, which could
|
| 169 |
-
have their own separate licenses, or one single license covering all of
|
| 170 |
-
the rights over the images.
|
| 171 |
-
|
| 172 |
-
### 3.0 Rights granted
|
| 173 |
-
|
| 174 |
-
3.1 Subject to the terms and conditions of this License, the Licensor
|
| 175 |
-
grants to You a worldwide, royalty-free, non-exclusive, terminable (but
|
| 176 |
-
only under Section 9) license to Use the Database for the duration of
|
| 177 |
-
any applicable copyright and Database Rights. These rights explicitly
|
| 178 |
-
include commercial use, and do not exclude any field of endeavour. To
|
| 179 |
-
the extent possible in the relevant jurisdiction, these rights may be
|
| 180 |
-
exercised in all media and formats whether now known or created in the
|
| 181 |
-
future.
|
| 182 |
-
|
| 183 |
-
The rights granted cover, for example:
|
| 184 |
-
|
| 185 |
-
a. Extraction and Re-utilisation of the whole or a Substantial part of
|
| 186 |
-
the Contents;
|
| 187 |
-
|
| 188 |
-
b. Creation of Derivative Databases;
|
| 189 |
-
|
| 190 |
-
c. Creation of Collective Databases;
|
| 191 |
-
|
| 192 |
-
d. Creation of temporary or permanent reproductions by any means and
|
| 193 |
-
in any form, in whole or in part, including of any Derivative
|
| 194 |
-
Databases or as a part of Collective Databases; and
|
| 195 |
-
|
| 196 |
-
e. Distribution, communication, display, lending, making available, or
|
| 197 |
-
performance to the public by any means and in any form, in whole or in
|
| 198 |
-
part, including of any Derivative Database or as a part of Collective
|
| 199 |
-
Databases.
|
| 200 |
-
|
| 201 |
-
3.2 Compulsory license schemes. For the avoidance of doubt:
|
| 202 |
-
|
| 203 |
-
a. Non-waivable compulsory license schemes. In those jurisdictions in
|
| 204 |
-
which the right to collect royalties through any statutory or
|
| 205 |
-
compulsory licensing scheme cannot be waived, the Licensor reserves
|
| 206 |
-
the exclusive right to collect such royalties for any exercise by You
|
| 207 |
-
of the rights granted under this License;
|
| 208 |
-
|
| 209 |
-
b. Waivable compulsory license schemes. In those jurisdictions in
|
| 210 |
-
which the right to collect royalties through any statutory or
|
| 211 |
-
compulsory licensing scheme can be waived, the Licensor waives the
|
| 212 |
-
exclusive right to collect such royalties for any exercise by You of
|
| 213 |
-
the rights granted under this License; and,
|
| 214 |
-
|
| 215 |
-
c. Voluntary license schemes. The Licensor waives the right to collect
|
| 216 |
-
royalties, whether individually or, in the event that the Licensor is
|
| 217 |
-
a member of a collecting society that administers voluntary licensing
|
| 218 |
-
schemes, via that society, from any exercise by You of the rights
|
| 219 |
-
granted under this License.
|
| 220 |
-
|
| 221 |
-
3.3 The right to release the Database under different terms, or to stop
|
| 222 |
-
distributing or making available the Database, is reserved. Note that
|
| 223 |
-
this Database may be multiple-licensed, and so You may have the choice
|
| 224 |
-
of using alternative licenses for this Database. Subject to Section
|
| 225 |
-
10.4, all other rights not expressly granted by Licensor are reserved.
|
| 226 |
-
|
| 227 |
-
### 4.0 Conditions of Use
|
| 228 |
-
|
| 229 |
-
4.1 The rights granted in Section 3 above are expressly made subject to
|
| 230 |
-
Your complying with the following conditions of use. These are important
|
| 231 |
-
conditions of this License, and if You fail to follow them, You will be
|
| 232 |
-
in material breach of its terms.
|
| 233 |
-
|
| 234 |
-
4.2 Notices. If You Publicly Convey this Database, any Derivative
|
| 235 |
-
Database, or the Database as part of a Collective Database, then You
|
| 236 |
-
must:
|
| 237 |
-
|
| 238 |
-
a. Do so only under the terms of this License;
|
| 239 |
-
|
| 240 |
-
b. Include a copy of this License or its Uniform Resource Identifier (URI)
|
| 241 |
-
with the Database or Derivative Database, including both in the
|
| 242 |
-
Database or Derivative Database and in any relevant documentation;
|
| 243 |
-
|
| 244 |
-
c. Keep intact any copyright or Database Right notices and notices
|
| 245 |
-
that refer to this License; and
|
| 246 |
-
|
| 247 |
-
d. If it is not possible to put the required notices in a particular
|
| 248 |
-
file due to its structure, then You must include the notices in a
|
| 249 |
-
location (such as a relevant directory) where users would be likely to
|
| 250 |
-
look for it.
|
| 251 |
-
|
| 252 |
-
4.3 Notice for using output (Contents). Creating and Using a Produced
|
| 253 |
-
Work does not require the notice in Section 4.2. However, if you
|
| 254 |
-
Publicly Use a Produced Work, You must include a notice associated with
|
| 255 |
-
the Produced Work reasonably calculated to make any Person that uses,
|
| 256 |
-
views, accesses, interacts with, or is otherwise exposed to the Produced
|
| 257 |
-
Work aware that Content was obtained from the Database, Derivative
|
| 258 |
-
Database, or the Database as part of a Collective Database, and that it
|
| 259 |
-
is available under this License.
|
| 260 |
-
|
| 261 |
-
a. Example notice. The following text will satisfy notice under
|
| 262 |
-
Section 4.3:
|
| 263 |
-
|
| 264 |
-
Contains information from DATABASE NAME which is made available
|
| 265 |
-
under the ODC Attribution License.
|
| 266 |
-
|
| 267 |
-
DATABASE NAME should be replaced with the name of the Database and a
|
| 268 |
-
hyperlink to the location of the Database. "ODC Attribution License"
|
| 269 |
-
should contain a hyperlink to the URI of the text of this License. If
|
| 270 |
-
hyperlinks are not possible, You should include the plain text of the
|
| 271 |
-
required URI's with the above notice.
|
| 272 |
-
|
| 273 |
-
4.4 Licensing of others. You may not sublicense the Database. Each time
|
| 274 |
-
You communicate the Database, the whole or Substantial part of the
|
| 275 |
-
Contents, or any Derivative Database to anyone else in any way, the
|
| 276 |
-
Licensor offers to the recipient a license to the Database on the same
|
| 277 |
-
terms and conditions as this License. You are not responsible for
|
| 278 |
-
enforcing compliance by third parties with this License, but You may
|
| 279 |
-
enforce any rights that You have over a Derivative Database. You are
|
| 280 |
-
solely responsible for any modifications of a Derivative Database made
|
| 281 |
-
by You or another Person at Your direction. You may not impose any
|
| 282 |
-
further restrictions on the exercise of the rights granted or affirmed
|
| 283 |
-
under this License.
|
| 284 |
-
|
| 285 |
-
### 5.0 Moral rights
|
| 286 |
-
|
| 287 |
-
5.1 Moral rights. This section covers moral rights, including any rights
|
| 288 |
-
to be identified as the author of the Database or to object to treatment
|
| 289 |
-
that would otherwise prejudice the author's honour and reputation, or
|
| 290 |
-
any other derogatory treatment:
|
| 291 |
-
|
| 292 |
-
a. For jurisdictions allowing waiver of moral rights, Licensor waives
|
| 293 |
-
all moral rights that Licensor may have in the Database to the fullest
|
| 294 |
-
extent possible by the law of the relevant jurisdiction under Section
|
| 295 |
-
10.4;
|
| 296 |
-
|
| 297 |
-
b. If waiver of moral rights under Section 5.1 a in the relevant
|
| 298 |
-
jurisdiction is not possible, Licensor agrees not to assert any moral
|
| 299 |
-
rights over the Database and waives all claims in moral rights to the
|
| 300 |
-
fullest extent possible by the law of the relevant jurisdiction under
|
| 301 |
-
Section 10.4; and
|
| 302 |
-
|
| 303 |
-
c. For jurisdictions not allowing waiver or an agreement not to assert
|
| 304 |
-
moral rights under Section 5.1 a and b, the author may retain their
|
| 305 |
-
moral rights over certain aspects of the Database.
|
| 306 |
-
|
| 307 |
-
Please note that some jurisdictions do not allow for the waiver of moral
|
| 308 |
-
rights, and so moral rights may still subsist over the Database in some
|
| 309 |
-
jurisdictions.
|
| 310 |
-
|
| 311 |
-
### 6.0 Fair dealing, Database exceptions, and other rights not affected
|
| 312 |
-
|
| 313 |
-
6.1 This License does not affect any rights that You or anyone else may
|
| 314 |
-
independently have under any applicable law to make any use of this
|
| 315 |
-
Database, including without limitation:
|
| 316 |
-
|
| 317 |
-
a. Exceptions to the Database Right including: Extraction of Contents
|
| 318 |
-
from non-electronic Databases for private purposes, Extraction for
|
| 319 |
-
purposes of illustration for teaching or scientific research, and
|
| 320 |
-
Extraction or Re-utilisation for public security or an administrative
|
| 321 |
-
or judicial procedure.
|
| 322 |
-
|
| 323 |
-
b. Fair dealing, fair use, or any other legally recognised limitation
|
| 324 |
-
or exception to infringement of copyright or other applicable laws.
|
| 325 |
-
|
| 326 |
-
6.2 This License does not affect any rights of lawful users to Extract
|
| 327 |
-
and Re-utilise insubstantial parts of the Contents, evaluated
|
| 328 |
-
quantitatively or qualitatively, for any purposes whatsoever, including
|
| 329 |
-
creating a Derivative Database (subject to other rights over the
|
| 330 |
-
Contents, see Section 2.4). The repeated and systematic Extraction or
|
| 331 |
-
Re-utilisation of insubstantial parts of the Contents may however amount
|
| 332 |
-
to the Extraction or Re-utilisation of a Substantial part of the
|
| 333 |
-
Contents.
|
| 334 |
-
|
| 335 |
-
### 7.0 Warranties and Disclaimer
|
| 336 |
-
|
| 337 |
-
7.1 The Database is licensed by the Licensor "as is" and without any
|
| 338 |
-
warranty of any kind, either express, implied, or arising by statute,
|
| 339 |
-
custom, course of dealing, or trade usage. Licensor specifically
|
| 340 |
-
disclaims any and all implied warranties or conditions of title,
|
| 341 |
-
non-infringement, accuracy or completeness, the presence or absence of
|
| 342 |
-
errors, fitness for a particular purpose, merchantability, or otherwise.
|
| 343 |
-
Some jurisdictions do not allow the exclusion of implied warranties, so
|
| 344 |
-
this exclusion may not apply to You.
|
| 345 |
-
|
| 346 |
-
### 8.0 Limitation of liability
|
| 347 |
-
|
| 348 |
-
8.1 Subject to any liability that may not be excluded or limited by law,
|
| 349 |
-
the Licensor is not liable for, and expressly excludes, all liability
|
| 350 |
-
for loss or damage however and whenever caused to anyone by any use
|
| 351 |
-
under this License, whether by You or by anyone else, and whether caused
|
| 352 |
-
by any fault on the part of the Licensor or not. This exclusion of
|
| 353 |
-
liability includes, but is not limited to, any special, incidental,
|
| 354 |
-
consequential, punitive, or exemplary damages such as loss of revenue,
|
| 355 |
-
data, anticipated profits, and lost business. This exclusion applies
|
| 356 |
-
even if the Licensor has been advised of the possibility of such
|
| 357 |
-
damages.
|
| 358 |
-
|
| 359 |
-
8.2 If liability may not be excluded by law, it is limited to actual and
|
| 360 |
-
direct financial loss to the extent it is caused by proved negligence on
|
| 361 |
-
the part of the Licensor.
|
| 362 |
-
|
| 363 |
-
### 9.0 Termination of Your rights under this License
|
| 364 |
-
|
| 365 |
-
9.1 Any breach by You of the terms and conditions of this License
|
| 366 |
-
automatically terminates this License with immediate effect and without
|
| 367 |
-
notice to You. For the avoidance of doubt, Persons who have received the
|
| 368 |
-
Database, the whole or a Substantial part of the Contents, Derivative
|
| 369 |
-
Databases, or the Database as part of a Collective Database from You
|
| 370 |
-
under this License will not have their licenses terminated provided
|
| 371 |
-
their use is in full compliance with this License or a license granted
|
| 372 |
-
under Section 4.8 of this License. Sections 1, 2, 7, 8, 9 and 10 will
|
| 373 |
-
survive any termination of this License.
|
| 374 |
-
|
| 375 |
-
9.2 If You are not in breach of the terms of this License, the Licensor
|
| 376 |
-
will not terminate Your rights under it.
|
| 377 |
-
|
| 378 |
-
9.3 Unless terminated under Section 9.1, this License is granted to You
|
| 379 |
-
for the duration of applicable rights in the Database.
|
| 380 |
-
|
| 381 |
-
9.4 Reinstatement of rights. If you cease any breach of the terms and
|
| 382 |
-
conditions of this License, then your full rights under this License
|
| 383 |
-
will be reinstated:
|
| 384 |
-
|
| 385 |
-
a. Provisionally and subject to permanent termination until the 60th
|
| 386 |
-
day after cessation of breach;
|
| 387 |
-
|
| 388 |
-
b. Permanently on the 60th day after cessation of breach unless
|
| 389 |
-
otherwise reasonably notified by the Licensor; or
|
| 390 |
-
|
| 391 |
-
c. Permanently if reasonably notified by the Licensor of the
|
| 392 |
-
violation, this is the first time You have received notice of
|
| 393 |
-
violation of this License from the Licensor, and You cure the
|
| 394 |
-
violation prior to 30 days after your receipt of the notice.
|
| 395 |
-
|
| 396 |
-
9.5 Notwithstanding the above, Licensor reserves the right to release
|
| 397 |
-
the Database under different license terms or to stop distributing or
|
| 398 |
-
making available the Database. Releasing the Database under different
|
| 399 |
-
license terms or stopping the distribution of the Database will not
|
| 400 |
-
withdraw this License (or any other license that has been, or is
|
| 401 |
-
required to be, granted under the terms of this License), and this
|
| 402 |
-
License will continue in full force and effect unless terminated as
|
| 403 |
-
stated above.
|
| 404 |
-
|
| 405 |
-
### 10.0 General
|
| 406 |
-
|
| 407 |
-
10.1 If any provision of this License is held to be invalid or
|
| 408 |
-
unenforceable, that must not affect the validity or enforceability of
|
| 409 |
-
the remainder of the terms and conditions of this License and each
|
| 410 |
-
remaining provision of this License shall be valid and enforced to the
|
| 411 |
-
fullest extent permitted by law.
|
| 412 |
-
|
| 413 |
-
10.2 This License is the entire agreement between the parties with
|
| 414 |
-
respect to the rights granted here over the Database. It replaces any
|
| 415 |
-
earlier understandings, agreements or representations with respect to
|
| 416 |
-
the Database.
|
| 417 |
-
|
| 418 |
-
10.3 If You are in breach of the terms of this License, You will not be
|
| 419 |
-
entitled to rely on the terms of this License or to complain of any
|
| 420 |
-
breach by the Licensor.
|
| 421 |
-
|
| 422 |
-
10.4 Choice of law. This License takes effect in and will be governed by
|
| 423 |
-
the laws of the relevant jurisdiction in which the License terms are
|
| 424 |
-
sought to be enforced. If the standard suite of rights granted under
|
| 425 |
-
applicable copyright law and Database Rights in the relevant
|
| 426 |
-
jurisdiction includes additional rights not granted under this License,
|
| 427 |
-
these additional rights are granted in this License in order to meet the
|
| 428 |
-
terms of this License.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
LICENSES/README.txt
CHANGED
|
@@ -1,10 +1,5 @@
|
|
| 1 |
-
|
| 2 |
-
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
Python repair tasks: Louistiti, MIT. Original tasks, generators and scoring code are preserved in components/loui/upstream/.
|
| 7 |
-
AgentWorldModel: Zhaoyang Wang, Canwen Xu, Boyi Liu, Yite Wang, Siwei Han, Zhewei Yao, Huaxiu Yao, and Yuxiong He, CC BY 4.0. See CC-BY-4.0.txt, components/awm/NOTICE, and LICENSE_SCOPE.json.
|
| 8 |
-
The project's existing MIT license applies to the new adapters and packaging documentation only. It does not replace or alter any upstream license.
|
| 9 |
-
|
| 10 |
-
OpenEnv SDK commit: 86a180ede21e044f7929b9a7783ad83aa67d83a3. The operating systems, Python, and third-party libraries retain their respective licenses. Original distribution notices remain in the images. Dependency records support reproduction and do not relicense those dependencies.
|
|
|
|
| 1 |
+
Terminal Desk: Apache-2.0, components/dnakhla/LICENSE and NOTICE.
|
| 2 |
+
MetaHarness: MIT, components/metaharness/LICENSE and NOTICE.
|
| 3 |
+
Python Repair Lab: MIT, components/loui/upstream/LICENSE and component attribution.
|
| 4 |
+
Audit Trail: Apache-2.0, components/audit/upstream/LICENSE and NOTICE.
|
| 5 |
+
Each component retains its original task and grader sources.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
LICENSES/TMax-NOTICE.txt
DELETED
|
@@ -1,6 +0,0 @@
|
|
| 1 |
-
Contains information from allenai/TMax-15K (https://huggingface.co/datasets/allenai/TMax-15K), declared under the Open Data Commons Attribution License: https://opendatacommons.org/licenses/by/1-0/ .
|
| 2 |
-
Harbor task conversion: TMaxxx/TMax-15K-Harbor, revision 48a77eb0b017606c643ed905f96db41672914798.
|
| 3 |
-
The six selected tasks retain their original instructions, scoring assertions and fixed input assets. The OpenEnv adapter changes execution and transport and protects original inputs and private checkers.
|
| 4 |
-
The original dataset card also states research/education use, Ai2 Responsible Use Guidelines and applicable upstream terms for generated content; retain those statements with the component source notices.
|
| 5 |
-
See components/tmax/SOURCE.json and licenses/ for the original Ai2 revision and full source attribution.
|
| 6 |
-
OpenEnv SDK revision: 86a180ede21e044f7929b9a7783ad83aa67d83a3. Ubuntu, CPython and installed packages retain their upstream notices and licenses in the runtime image.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
MANIFEST.json
CHANGED
|
@@ -1,874 +1,528 @@
|
|
| 1 |
{
|
| 2 |
-
"format": "multidomain-file-manifest-v1",
|
| 3 |
-
"selected_task_count": 11,
|
| 4 |
"files": {
|
| 5 |
-
".gitattributes": {
|
| 6 |
-
"sha256": "24641eca9bbd24aa8a02bda3cd37dcfb8445345df9b7b4997116ffd62746201e",
|
| 7 |
-
"bytes": 2710
|
| 8 |
-
},
|
| 9 |
-
"LICENSE": {
|
| 10 |
-
"sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
|
| 11 |
-
"bytes": 0
|
| 12 |
-
},
|
| 13 |
-
"LICENSES/Apache-2.0-PDBThink.txt": {
|
| 14 |
-
"sha256": "c71d239df91726fc519c6eb72d318ec65820627232b2f796219e87dcf35d0ab4",
|
| 15 |
-
"bytes": 11357
|
| 16 |
-
},
|
| 17 |
-
"LICENSES/CC-BY-4.0.txt": {
|
| 18 |
-
"sha256": "9e5f1b3c610b9c2da5c313bf81d577a7d1acec686bdb0384edefa6df0f90cd94",
|
| 19 |
-
"bytes": 18656
|
| 20 |
-
},
|
| 21 |
-
"LICENSES/MIT-Python-Repair.txt": {
|
| 22 |
-
"sha256": "a5958627f5ebeaf73b280a5b983d86d79c2144c988d761ea7769158788a90de6",
|
| 23 |
-
"bytes": 1070
|
| 24 |
-
},
|
| 25 |
-
"LICENSES/MIT-adapters.txt": {
|
| 26 |
-
"sha256": "c9d5f2c24789a4ee7502fd1426c6a2090ba766b24f20d0ef663d3b149b7466d3",
|
| 27 |
-
"bytes": 1083
|
| 28 |
-
},
|
| 29 |
-
"LICENSES/ODC-BY-1.0.txt": {
|
| 30 |
-
"sha256": "11a6d83734845ad09d809667aa219857a5b985b28c258a2eebf5677668a6bd3b",
|
| 31 |
-
"bytes": 19977
|
| 32 |
-
},
|
| 33 |
"LICENSES/README.txt": {
|
| 34 |
-
"
|
| 35 |
-
"
|
| 36 |
-
},
|
| 37 |
-
"LICENSES/TMax-NOTICE.txt": {
|
| 38 |
-
"sha256": "85da239bb4104a67e515dca538d1a4b345eed77c5d460fe76625bae905b431ed",
|
| 39 |
-
"bytes": 982
|
| 40 |
},
|
| 41 |
"README.md": {
|
| 42 |
-
"
|
| 43 |
-
"
|
| 44 |
-
},
|
| 45 |
-
"REGISTRATION.json": {
|
| 46 |
-
"sha256": "1bcb19ab0927ecf8e0aeb7a11fff5fca73cf62387ecf56ac358ac294a09a7d36",
|
| 47 |
-
"bytes": 524
|
| 48 |
},
|
| 49 |
"SOURCE_LOCK.json": {
|
| 50 |
-
"
|
| 51 |
-
"
|
| 52 |
-
},
|
| 53 |
-
"components/awm/ADAPTATIONS.txt": {
|
| 54 |
-
"sha256": "9338fe69c7472bfb396c70489e4edf64d6a30cf696da9a4579d30c743414c529",
|
| 55 |
-
"bytes": 444
|
| 56 |
-
},
|
| 57 |
-
"components/awm/Dockerfile": {
|
| 58 |
-
"sha256": "c2b8e74a2b134a9efcbc78332d6688b4d44c0e9039f64b0e664f281824886060",
|
| 59 |
-
"bytes": 323
|
| 60 |
-
},
|
| 61 |
-
"components/awm/LICENSE_SCOPE.json": {
|
| 62 |
-
"sha256": "1ea6a4d0c80da30d5f658364aaef2664cf09f32da0bce23c448e1fc1e4c4a7a6",
|
| 63 |
-
"bytes": 908
|
| 64 |
-
},
|
| 65 |
-
"components/awm/NOTICE": {
|
| 66 |
-
"sha256": "1aeed83147ee7f0ef0e0ab8bf92ab49404b86a135436bd32772e4e89e007b702",
|
| 67 |
-
"bytes": 642
|
| 68 |
-
},
|
| 69 |
-
"components/awm/SOURCE_CREDITS.json": {
|
| 70 |
-
"sha256": "ae057f0e66d0e924e81f553e729148cd98161bf070283928ef4fb658e9cf3546",
|
| 71 |
-
"bytes": 469
|
| 72 |
-
},
|
| 73 |
-
"components/awm/TASKS.json": {
|
| 74 |
-
"sha256": "9696c2ccb89108c6d7edaa0fec84092ae3251ef049e5d43252341c29f03ce88e",
|
| 75 |
-
"bytes": 1480
|
| 76 |
-
},
|
| 77 |
-
"components/awm/awm-requirements.lock": {
|
| 78 |
-
"sha256": "65d41089191536d5940648213b09924ba93e55d92df0080634e16d13615fd1ac",
|
| 79 |
-
"bytes": 4276
|
| 80 |
-
},
|
| 81 |
-
"components/awm/config.json": {
|
| 82 |
-
"sha256": "679c2e8e5ca63963ab80b2e89a14df5204fb0b70dad25714efb1f0b89cad8424",
|
| 83 |
-
"bytes": 542
|
| 84 |
-
},
|
| 85 |
-
"components/awm/private/tasks/awm-accounting-1-invoice/SOURCE.json": {
|
| 86 |
-
"sha256": "3a1cc59eece46232d3ebb39df3cbfedd0625ab85bcf5e1d6cb090ea6ecec0e58",
|
| 87 |
-
"bytes": 657
|
| 88 |
-
},
|
| 89 |
-
"components/awm/private/tasks/awm-accounting-1-invoice/initial.db": {
|
| 90 |
-
"sha256": "8ad2959536e44caba47bcbeca9018e47e7157783194d19b429aa8f22a60f4771",
|
| 91 |
-
"bytes": 331776
|
| 92 |
-
},
|
| 93 |
-
"components/awm/private/tasks/awm-accounting-1-invoice/original_api.py": {
|
| 94 |
-
"sha256": "57362b907a2d454bbd29b95dfebb7d84207ce9d7e22533eaf54853ee4fb84990",
|
| 95 |
-
"bytes": 87054
|
| 96 |
-
},
|
| 97 |
-
"components/awm/private/tasks/awm-accounting-1-invoice/original_verifier.py": {
|
| 98 |
-
"sha256": "3cd0d63022caa900e32bda0b0d3ae5c9948ce3c195b77ba1906c7ddebea9c58b",
|
| 99 |
-
"bytes": 5951
|
| 100 |
-
},
|
| 101 |
-
"components/awm/requirements.lock": {
|
| 102 |
-
"sha256": "0078892ae5870080b3417677926bc64f4f87ba9e8110ff400f18954e361455fc",
|
| 103 |
-
"bytes": 10799
|
| 104 |
-
},
|
| 105 |
-
"components/awm/runtime/awm/__init__.py": {
|
| 106 |
-
"sha256": "01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b",
|
| 107 |
-
"bytes": 1
|
| 108 |
-
},
|
| 109 |
-
"components/awm/runtime/awm/adapter.py": {
|
| 110 |
-
"sha256": "887e81b7aab249861166099b3b4f0778f9041324640b904140d1b055d5a0bff1",
|
| 111 |
-
"bytes": 5277
|
| 112 |
-
},
|
| 113 |
-
"components/awm/runtime/awm/launch_service.py": {
|
| 114 |
-
"sha256": "0638af1cd1c6a311ee85109143ec6a59646a5f3d41c4b30312526dec561da33d",
|
| 115 |
-
"bytes": 2413
|
| 116 |
-
},
|
| 117 |
-
"components/awm/runtime/awm/openenv_app.py": {
|
| 118 |
-
"sha256": "f47b0cc104a7a962fc932c4d3f3bb8bfcf1524dec049b9c2c33161924038b94e",
|
| 119 |
-
"bytes": 3995
|
| 120 |
-
},
|
| 121 |
-
"components/awm/runtime/awm/server.py": {
|
| 122 |
-
"sha256": "484c7caeaa301b91f468a9e55a251a6b529c6f9d0f2e4951c9602071c40ebcea",
|
| 123 |
-
"bytes": 820
|
| 124 |
-
},
|
| 125 |
-
"components/awm/runtime/awm/wire_client.py": {
|
| 126 |
-
"sha256": "b5267c0f1cc015a68154affade8d89f6b6a01e9e4cc47a2dbdb74020e108ab5f",
|
| 127 |
-
"bytes": 4987
|
| 128 |
-
},
|
| 129 |
-
"components/awm/runtime/awm/worker.py": {
|
| 130 |
-
"sha256": "b02f482ee9e55df0998b9fcc839a6172cbd1daf40701082062fa49416b31d6e0",
|
| 131 |
-
"bytes": 6514
|
| 132 |
-
},
|
| 133 |
-
"components/awm/runtime/common/__init__.py": {
|
| 134 |
-
"sha256": "01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b",
|
| 135 |
-
"bytes": 1
|
| 136 |
-
},
|
| 137 |
-
"components/awm/runtime/common/contracts.py": {
|
| 138 |
-
"sha256": "b1e1429208e84aefc2422ee1d2400ad793c43cd5c0e8db213a3b669fe0947ce1",
|
| 139 |
-
"bytes": 1015
|
| 140 |
-
},
|
| 141 |
-
"components/awm/runtime/common/http_routes.py": {
|
| 142 |
-
"sha256": "7263c04e9175faf66501ed9b2ac2f9a637557a8b1966d839fb9944eb01abac0e",
|
| 143 |
-
"bytes": 2380
|
| 144 |
-
},
|
| 145 |
-
"components/awm/runtime/common/models.py": {
|
| 146 |
-
"sha256": "26e7a67537ce7ae34909b724243c37242b9c8055cbfe0c717179dac74347786a",
|
| 147 |
-
"bytes": 1815
|
| 148 |
-
},
|
| 149 |
-
"components/awm/upstream/README.md": {
|
| 150 |
-
"sha256": "12a0f7eb70edfb5e6fb02f9904c3e06daea24eab392ff4d6cef229ce18237810",
|
| 151 |
-
"bytes": 3917
|
| 152 |
-
},
|
| 153 |
-
"components/awm/upstream/accounting_1-gen_db.jsonl": {
|
| 154 |
-
"sha256": "1cd23311c95c9919621b226c99dcab54faf815300c72cd542a394a5e69463a6e",
|
| 155 |
-
"bytes": 13948
|
| 156 |
-
},
|
| 157 |
-
"components/awm/upstream/accounting_1-gen_envs.jsonl": {
|
| 158 |
-
"sha256": "99f1883338fa6f4827cb9c6c4c9cf9222c28a2a9842202cbe524921921de3ae3",
|
| 159 |
-
"bytes": 90440
|
| 160 |
-
},
|
| 161 |
-
"components/awm/upstream/accounting_1-gen_sample.jsonl": {
|
| 162 |
-
"sha256": "28cf8d5611b0d63b9e17d0e991e328c2970cfef5595c08d084f2b1bad7a441fd",
|
| 163 |
-
"bytes": 32317
|
| 164 |
-
},
|
| 165 |
-
"components/loui/.dockerignore": {
|
| 166 |
-
"sha256": "05cc6ae53cfd6129f1d7010aa874c6cf0a6019b1adfeff3f4fab27f2d04f43ca",
|
| 167 |
-
"bytes": 18
|
| 168 |
-
},
|
| 169 |
-
"components/loui/Dockerfile": {
|
| 170 |
-
"sha256": "0b1054575ac49a8a80a9777e67280b41549b7ff6da909301b0fa8d87c1d8833d",
|
| 171 |
-
"bytes": 801
|
| 172 |
-
},
|
| 173 |
-
"components/loui/README.md": {
|
| 174 |
-
"sha256": "6321514f0aac58cdcd022b38f1be9c499d70b1f82a57a45a6878d816a4bcf293",
|
| 175 |
-
"bytes": 672
|
| 176 |
-
},
|
| 177 |
-
"components/loui/SOURCE.json": {
|
| 178 |
-
"sha256": "77ce88ca01b6eaad2babc63f0bc078674597336451275db2d72e282bf84b2592",
|
| 179 |
-
"bytes": 1133
|
| 180 |
-
},
|
| 181 |
-
"components/loui/config.json": {
|
| 182 |
-
"sha256": "93e90e21198aa146280df24300947b36561b3c41fb51494f0bf5c2b793fc7330",
|
| 183 |
-
"bytes": 2363
|
| 184 |
-
},
|
| 185 |
-
"components/loui/runtime/common/__init__.py": {
|
| 186 |
-
"sha256": "01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b",
|
| 187 |
-
"bytes": 1
|
| 188 |
-
},
|
| 189 |
-
"components/loui/runtime/common/contracts.py": {
|
| 190 |
-
"sha256": "b1e1429208e84aefc2422ee1d2400ad793c43cd5c0e8db213a3b669fe0947ce1",
|
| 191 |
-
"bytes": 1015
|
| 192 |
-
},
|
| 193 |
-
"components/loui/runtime/common/models.py": {
|
| 194 |
-
"sha256": "26e7a67537ce7ae34909b724243c37242b9c8055cbfe0c717179dac74347786a",
|
| 195 |
-
"bytes": 1815
|
| 196 |
-
},
|
| 197 |
-
"components/loui/runtime/loui/__init__.py": {
|
| 198 |
-
"sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
|
| 199 |
-
"bytes": 0
|
| 200 |
-
},
|
| 201 |
-
"components/loui/runtime/loui/child.py": {
|
| 202 |
-
"sha256": "c4774351bdbd8a044cd20bcd7111ac4db7403feccb9444acf663e71140b27888",
|
| 203 |
-
"bytes": 3172
|
| 204 |
-
},
|
| 205 |
-
"components/loui/runtime/loui/environment.py": {
|
| 206 |
-
"sha256": "edd467b474dc0982c9b6c91a9f0150432fa8b9a5c6b62c8187bc9cc9f440a22a",
|
| 207 |
-
"bytes": 7292
|
| 208 |
-
},
|
| 209 |
-
"components/loui/runtime/loui/executor.py": {
|
| 210 |
-
"sha256": "7c70a736ee8c5afbb3b5cf3e8113242e4dbb9efc3abe3a2027948474121d59f8",
|
| 211 |
-
"bytes": 2741
|
| 212 |
-
},
|
| 213 |
-
"components/loui/runtime/loui/server.py": {
|
| 214 |
-
"sha256": "c3ae4e00495724083e73085bd4dccdf3493094ef2e14c0bb017f6502d264244b",
|
| 215 |
-
"bytes": 411
|
| 216 |
-
},
|
| 217 |
-
"components/loui/tasks/expression-3/instruction.md": {
|
| 218 |
-
"sha256": "09ef2d8fc856ca3dc5662c279df705e9accc827f4472dc34758ffe769d116128",
|
| 219 |
-
"bytes": 955
|
| 220 |
-
},
|
| 221 |
-
"components/loui/tasks/incident-3/instruction.md": {
|
| 222 |
-
"sha256": "682c7db0f0911e85174652574349fbe957c1cc235a68d224c569e405d9674452",
|
| 223 |
-
"bytes": 812
|
| 224 |
-
},
|
| 225 |
-
"components/loui/upstream/LICENSE": {
|
| 226 |
-
"sha256": "a5958627f5ebeaf73b280a5b983d86d79c2144c988d761ea7769158788a90de6",
|
| 227 |
-
"bytes": 1070
|
| 228 |
-
},
|
| 229 |
-
"components/loui/upstream/v3/README.md": {
|
| 230 |
-
"sha256": "bf5da0c7b871459278ad174cfd3c4ba90de9fbe74d35decce007bed13535d32d",
|
| 231 |
-
"bytes": 7857
|
| 232 |
-
},
|
| 233 |
-
"components/loui/upstream/v3/execution.py": {
|
| 234 |
-
"sha256": "578814be5152b9b00c7eeae387544a94db159c9e8e3456e5cb56b31b6a731e9a",
|
| 235 |
-
"bytes": 8431
|
| 236 |
-
},
|
| 237 |
-
"components/loui/upstream/v3/hard_tasks.py": {
|
| 238 |
-
"sha256": "f140fcf554e97b67afb14e961affc46c14320cb784fe1f7444585e77ceb89ea0",
|
| 239 |
-
"bytes": 8476
|
| 240 |
-
},
|
| 241 |
-
"components/loui/upstream/v3/server.py": {
|
| 242 |
-
"sha256": "67f546daef6e7902c12754cbbd883657e57d2cb21e109275af123c552cc93422",
|
| 243 |
-
"bytes": 4068
|
| 244 |
-
},
|
| 245 |
-
"components/loui/upstream/v3/tasks.jsonl": {
|
| 246 |
-
"sha256": "9715cdabe6e67287399a3fe2bad435852510bf854982d2f6695b3d87db395c88",
|
| 247 |
-
"bytes": 87084
|
| 248 |
-
},
|
| 249 |
-
"components/loui/upstream/v3/tasks.py": {
|
| 250 |
-
"sha256": "71caf0175532025bf138398229d466f18e5e03365b48853efd92f61f6dae2d66",
|
| 251 |
-
"bytes": 22139
|
| 252 |
-
},
|
| 253 |
-
"components/math/ADAPTATIONS.txt": {
|
| 254 |
-
"sha256": "83af5f0a6ae61c968b666a5d1854020a8ee8cf174562ca9d59afc397f46444ae",
|
| 255 |
-
"bytes": 193
|
| 256 |
-
},
|
| 257 |
-
"components/math/Dockerfile": {
|
| 258 |
-
"sha256": "f6f0505f720c1b8bb8202cbdc8c5d16f270646dc006b47fdbc1d8852f757c848",
|
| 259 |
-
"bytes": 477
|
| 260 |
-
},
|
| 261 |
-
"components/math/NOTICE.txt": {
|
| 262 |
-
"sha256": "a4650234425608cbdb194ace7ba22812b4c14c1609a8a7808c2997bf92cdd2c7",
|
| 263 |
-
"bytes": 328
|
| 264 |
-
},
|
| 265 |
-
"components/math/SDK_DEPENDENCIES.json": {
|
| 266 |
-
"sha256": "a037cf3ce617aa3e0216bf5e0677d229679bfffdd30dba9057b58bb413c39732",
|
| 267 |
-
"bytes": 25904
|
| 268 |
-
},
|
| 269 |
-
"components/math/SOURCE.json": {
|
| 270 |
-
"sha256": "4d29eba8369ddbcbeab51dabe14f411512b1117b3787f59c1d406938f0b927ac",
|
| 271 |
-
"bytes": 913
|
| 272 |
-
},
|
| 273 |
-
"components/math/TASKS.json": {
|
| 274 |
-
"sha256": "5b232f75ae416ebe7094f0c85010ac6cb41dfecfd601aa7b5ed51712e75dc29a",
|
| 275 |
-
"bytes": 1164
|
| 276 |
-
},
|
| 277 |
-
"components/math/config.json": {
|
| 278 |
-
"sha256": "a0707b688bdabc7c7634d41bcd9031b6639896a2fc4b04ec6a06c2ac11dfb68c",
|
| 279 |
-
"bytes": 1600
|
| 280 |
-
},
|
| 281 |
-
"components/math/licenses/MathConstraint-LICENSE": {
|
| 282 |
-
"sha256": "9e5f1b3c610b9c2da5c313bf81d577a7d1acec686bdb0384edefa6df0f90cd94",
|
| 283 |
-
"bytes": 18656
|
| 284 |
-
},
|
| 285 |
-
"components/math/licenses/RLVE-LICENSE": {
|
| 286 |
-
"sha256": "10afac3400d1abccc7ec2322e07563a3e495c13ac39d3865564aa2e2423b398e",
|
| 287 |
-
"bytes": 1069
|
| 288 |
-
},
|
| 289 |
-
"components/math/licenses/UPSTREAM_COLLECTION_LICENSES.md": {
|
| 290 |
-
"sha256": "200b2ce93f2a5b9671165f9aea3cc4d89db995352c1e1e3db6d418262b058516",
|
| 291 |
-
"bytes": 462
|
| 292 |
-
},
|
| 293 |
-
"components/math/runtime/common/__init__.py": {
|
| 294 |
-
"sha256": "01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b",
|
| 295 |
-
"bytes": 1
|
| 296 |
-
},
|
| 297 |
-
"components/math/runtime/common/contracts.py": {
|
| 298 |
-
"sha256": "b1e1429208e84aefc2422ee1d2400ad793c43cd5c0e8db213a3b669fe0947ce1",
|
| 299 |
-
"bytes": 1015
|
| 300 |
-
},
|
| 301 |
-
"components/math/runtime/common/http_routes.py": {
|
| 302 |
-
"sha256": "7263c04e9175faf66501ed9b2ac2f9a637557a8b1966d839fb9944eb01abac0e",
|
| 303 |
-
"bytes": 2380
|
| 304 |
-
},
|
| 305 |
-
"components/math/runtime/common/models.py": {
|
| 306 |
-
"sha256": "26e7a67537ce7ae34909b724243c37242b9c8055cbfe0c717179dac74347786a",
|
| 307 |
-
"bytes": 1815
|
| 308 |
-
},
|
| 309 |
-
"components/math/runtime/native_shell/__init__.py": {
|
| 310 |
-
"sha256": "01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b",
|
| 311 |
-
"bytes": 1
|
| 312 |
-
},
|
| 313 |
-
"components/math/runtime/native_shell/actor_launcher.py": {
|
| 314 |
-
"sha256": "80eb3b90287840668e72040dc55ba115bfc3f4251a25cb2b94af0ed3759dd6b3",
|
| 315 |
-
"bytes": 5012
|
| 316 |
},
|
| 317 |
-
"components/
|
| 318 |
-
"
|
| 319 |
-
"
|
| 320 |
},
|
| 321 |
-
"components/
|
| 322 |
-
"
|
| 323 |
-
"
|
| 324 |
},
|
| 325 |
-
"components/
|
| 326 |
-
"
|
| 327 |
-
"
|
| 328 |
},
|
| 329 |
-
"components/
|
| 330 |
-
"
|
| 331 |
-
"
|
| 332 |
},
|
| 333 |
-
"components/
|
| 334 |
-
"
|
| 335 |
-
"
|
| 336 |
},
|
| 337 |
-
"components/
|
| 338 |
-
"
|
| 339 |
-
"
|
| 340 |
},
|
| 341 |
-
"components/
|
| 342 |
-
"
|
| 343 |
-
"
|
| 344 |
},
|
| 345 |
-
"components/
|
| 346 |
-
"
|
| 347 |
-
"
|
| 348 |
},
|
| 349 |
-
"components/
|
| 350 |
-
"
|
| 351 |
-
"
|
| 352 |
},
|
| 353 |
-
"components/
|
| 354 |
-
"
|
| 355 |
-
"
|
| 356 |
},
|
| 357 |
-
"components/
|
| 358 |
-
"
|
| 359 |
-
"
|
| 360 |
},
|
| 361 |
-
"components/
|
| 362 |
-
"
|
| 363 |
-
"
|
| 364 |
},
|
| 365 |
-
"components/
|
| 366 |
-
"
|
| 367 |
-
"
|
| 368 |
},
|
| 369 |
-
"components/
|
| 370 |
-
"
|
| 371 |
-
"
|
| 372 |
},
|
| 373 |
-
"components/
|
| 374 |
-
"
|
| 375 |
-
"
|
| 376 |
},
|
| 377 |
-
"components/
|
| 378 |
-
"
|
| 379 |
-
"
|
| 380 |
},
|
| 381 |
-
"components/
|
| 382 |
-
"
|
| 383 |
-
"
|
| 384 |
},
|
| 385 |
-
"components/
|
| 386 |
-
"
|
| 387 |
-
"
|
| 388 |
},
|
| 389 |
-
"components/
|
| 390 |
-
"
|
| 391 |
-
"
|
| 392 |
},
|
| 393 |
-
"components/
|
| 394 |
-
"
|
| 395 |
-
"
|
| 396 |
},
|
| 397 |
-
"components/
|
| 398 |
-
"
|
| 399 |
-
"
|
| 400 |
},
|
| 401 |
-
"components/
|
| 402 |
-
"
|
| 403 |
-
"
|
| 404 |
},
|
| 405 |
-
"components/
|
| 406 |
-
"
|
| 407 |
-
"
|
| 408 |
},
|
| 409 |
-
"components/
|
| 410 |
-
"
|
| 411 |
-
"
|
| 412 |
},
|
| 413 |
-
"components/
|
| 414 |
-
"
|
| 415 |
-
"
|
| 416 |
},
|
| 417 |
-
"components/
|
| 418 |
-
"
|
| 419 |
-
"
|
| 420 |
},
|
| 421 |
-
"components/
|
| 422 |
-
"
|
| 423 |
-
"
|
| 424 |
},
|
| 425 |
-
"components/
|
| 426 |
-
"
|
| 427 |
-
"
|
| 428 |
},
|
| 429 |
-
"components/
|
| 430 |
-
"
|
| 431 |
-
"
|
| 432 |
},
|
| 433 |
-
"components/
|
| 434 |
-
"
|
| 435 |
-
"
|
| 436 |
},
|
| 437 |
-
"components/
|
| 438 |
-
"
|
| 439 |
-
"
|
| 440 |
},
|
| 441 |
-
"components/
|
| 442 |
-
"
|
| 443 |
-
"
|
| 444 |
},
|
| 445 |
-
"components/
|
| 446 |
-
"
|
| 447 |
-
"
|
| 448 |
},
|
| 449 |
-
"components/
|
| 450 |
-
"
|
| 451 |
-
"
|
| 452 |
},
|
| 453 |
-
"components/
|
| 454 |
-
"
|
| 455 |
-
"
|
| 456 |
},
|
| 457 |
-
"components/
|
| 458 |
-
"
|
| 459 |
-
"
|
| 460 |
},
|
| 461 |
-
"components/
|
| 462 |
-
"
|
| 463 |
-
"
|
| 464 |
},
|
| 465 |
-
"components/
|
| 466 |
-
"
|
| 467 |
-
"
|
| 468 |
},
|
| 469 |
-
"components/
|
| 470 |
-
"
|
| 471 |
-
"
|
| 472 |
},
|
| 473 |
-
"components/
|
| 474 |
-
"
|
| 475 |
-
"
|
| 476 |
},
|
| 477 |
-
"components/
|
| 478 |
-
"
|
| 479 |
-
"
|
| 480 |
},
|
| 481 |
-
"components/
|
| 482 |
-
"
|
| 483 |
-
"
|
| 484 |
},
|
| 485 |
-
"components/
|
| 486 |
-
"
|
| 487 |
-
"
|
| 488 |
},
|
| 489 |
-
"components/
|
| 490 |
-
"
|
| 491 |
-
"
|
| 492 |
},
|
| 493 |
-
"components/
|
| 494 |
-
"
|
| 495 |
-
"
|
| 496 |
},
|
| 497 |
-
"components/
|
| 498 |
-
"
|
| 499 |
-
"
|
| 500 |
},
|
| 501 |
-
"components/
|
| 502 |
-
"
|
| 503 |
-
"
|
| 504 |
},
|
| 505 |
-
"components/
|
| 506 |
-
"
|
| 507 |
-
"
|
| 508 |
},
|
| 509 |
-
"components/
|
| 510 |
-
"
|
| 511 |
-
"
|
| 512 |
},
|
| 513 |
-
"components/
|
| 514 |
-
"
|
| 515 |
-
"
|
| 516 |
},
|
| 517 |
-
"components/
|
| 518 |
-
"
|
| 519 |
-
"
|
| 520 |
},
|
| 521 |
-
"components/
|
| 522 |
-
"
|
| 523 |
-
"
|
| 524 |
},
|
| 525 |
-
"components/
|
| 526 |
-
"
|
| 527 |
-
"
|
| 528 |
},
|
| 529 |
-
"components/
|
| 530 |
-
"
|
| 531 |
-
"
|
| 532 |
},
|
| 533 |
-
"components/
|
| 534 |
-
"
|
| 535 |
-
"
|
| 536 |
},
|
| 537 |
-
"components/
|
| 538 |
-
"
|
| 539 |
-
"
|
| 540 |
},
|
| 541 |
-
"components/
|
| 542 |
-
"
|
| 543 |
-
"
|
| 544 |
},
|
| 545 |
-
"components/
|
| 546 |
-
"
|
| 547 |
-
"
|
| 548 |
},
|
| 549 |
-
"components/
|
| 550 |
-
"
|
| 551 |
-
"
|
| 552 |
},
|
| 553 |
-
"components/
|
| 554 |
-
"
|
| 555 |
-
"
|
| 556 |
},
|
| 557 |
-
"components/
|
| 558 |
-
"
|
| 559 |
-
"
|
| 560 |
},
|
| 561 |
-
"components/
|
| 562 |
-
"
|
| 563 |
-
"
|
| 564 |
},
|
| 565 |
-
"components/
|
| 566 |
-
"
|
| 567 |
-
"
|
| 568 |
},
|
| 569 |
-
"components/
|
| 570 |
-
"
|
| 571 |
-
"
|
| 572 |
},
|
| 573 |
-
"components/
|
| 574 |
-
"
|
| 575 |
-
"
|
| 576 |
},
|
| 577 |
-
"components/
|
| 578 |
-
"
|
| 579 |
-
"
|
| 580 |
},
|
| 581 |
-
"components/
|
| 582 |
-
"
|
| 583 |
-
"
|
| 584 |
},
|
| 585 |
-
"components/
|
| 586 |
-
"
|
| 587 |
-
"
|
| 588 |
},
|
| 589 |
-
"components/
|
| 590 |
-
"
|
| 591 |
-
"
|
| 592 |
},
|
| 593 |
-
"components/
|
| 594 |
-
"
|
| 595 |
-
"
|
| 596 |
},
|
| 597 |
-
"components/
|
| 598 |
-
"
|
| 599 |
-
"
|
| 600 |
},
|
| 601 |
-
"components/
|
| 602 |
-
"
|
| 603 |
-
"
|
| 604 |
},
|
| 605 |
-
"components/
|
| 606 |
-
"
|
| 607 |
-
"
|
| 608 |
},
|
| 609 |
-
"components/
|
| 610 |
-
"
|
| 611 |
-
"
|
| 612 |
},
|
| 613 |
-
"components/
|
| 614 |
-
"
|
| 615 |
-
"
|
| 616 |
},
|
| 617 |
-
"components/
|
| 618 |
-
"
|
| 619 |
-
"
|
| 620 |
},
|
| 621 |
-
"components/
|
| 622 |
-
"
|
| 623 |
-
"
|
| 624 |
},
|
| 625 |
-
"components/
|
| 626 |
-
"
|
| 627 |
-
"
|
| 628 |
},
|
| 629 |
-
"components/
|
| 630 |
-
"
|
| 631 |
-
"
|
| 632 |
},
|
| 633 |
-
"components/
|
| 634 |
-
"
|
| 635 |
-
"
|
| 636 |
},
|
| 637 |
-
"components/
|
| 638 |
-
"
|
| 639 |
-
"
|
| 640 |
},
|
| 641 |
-
"components/
|
| 642 |
-
"
|
| 643 |
-
"
|
| 644 |
},
|
| 645 |
-
"components/
|
| 646 |
-
"
|
| 647 |
-
"
|
| 648 |
},
|
| 649 |
-
"components/
|
| 650 |
-
"
|
| 651 |
-
"
|
| 652 |
},
|
| 653 |
-
"components/
|
| 654 |
-
"
|
| 655 |
-
"
|
| 656 |
},
|
| 657 |
-
"components/
|
| 658 |
-
"
|
| 659 |
-
"
|
| 660 |
},
|
| 661 |
-
"components/
|
| 662 |
-
"
|
| 663 |
-
"
|
| 664 |
},
|
| 665 |
-
"components/
|
| 666 |
-
"
|
| 667 |
-
"
|
| 668 |
},
|
| 669 |
-
"components/
|
| 670 |
-
"
|
| 671 |
-
"
|
| 672 |
},
|
| 673 |
-
"components/
|
| 674 |
-
"
|
| 675 |
-
"
|
| 676 |
},
|
| 677 |
-
"components/
|
| 678 |
-
"
|
| 679 |
-
"
|
| 680 |
},
|
| 681 |
-
"components/
|
| 682 |
-
"
|
| 683 |
-
"
|
| 684 |
},
|
| 685 |
-
"components/
|
| 686 |
-
"
|
| 687 |
-
"
|
| 688 |
},
|
| 689 |
-
"components/
|
| 690 |
-
"
|
| 691 |
-
"
|
| 692 |
},
|
| 693 |
-
"components/
|
| 694 |
-
"
|
| 695 |
-
"
|
| 696 |
},
|
| 697 |
-
"components/
|
| 698 |
-
"
|
| 699 |
-
"
|
| 700 |
},
|
| 701 |
-
"components/
|
| 702 |
-
"
|
| 703 |
-
"
|
| 704 |
},
|
| 705 |
-
"components/
|
| 706 |
-
"
|
| 707 |
-
"
|
| 708 |
},
|
| 709 |
-
"components/
|
| 710 |
-
"
|
| 711 |
-
"
|
| 712 |
},
|
| 713 |
-
"components/
|
| 714 |
-
"
|
| 715 |
-
"
|
| 716 |
},
|
| 717 |
-
"components/
|
| 718 |
-
"
|
| 719 |
-
"
|
| 720 |
},
|
| 721 |
-
"components/
|
| 722 |
-
"
|
| 723 |
-
"
|
| 724 |
},
|
| 725 |
-
"components/
|
| 726 |
-
"
|
| 727 |
-
"
|
| 728 |
},
|
| 729 |
-
"components/
|
| 730 |
-
"
|
| 731 |
-
"
|
| 732 |
},
|
| 733 |
-
"components/
|
| 734 |
-
"
|
| 735 |
-
"
|
| 736 |
},
|
| 737 |
-
"components/
|
| 738 |
-
"
|
| 739 |
-
"
|
| 740 |
},
|
| 741 |
-
"components/
|
| 742 |
-
"
|
| 743 |
-
"
|
| 744 |
},
|
| 745 |
-
"components/
|
| 746 |
-
"
|
| 747 |
-
"
|
| 748 |
},
|
| 749 |
-
"components/
|
| 750 |
-
"
|
| 751 |
-
"
|
| 752 |
},
|
| 753 |
-
"components/
|
| 754 |
-
"
|
| 755 |
-
"
|
| 756 |
},
|
| 757 |
-
"components/
|
| 758 |
-
"
|
| 759 |
-
"
|
| 760 |
},
|
| 761 |
-
"components/
|
| 762 |
-
"
|
| 763 |
-
"
|
| 764 |
},
|
| 765 |
-
"components/
|
| 766 |
-
"
|
| 767 |
-
"
|
| 768 |
},
|
| 769 |
-
"components/
|
| 770 |
-
"
|
| 771 |
-
"
|
| 772 |
},
|
| 773 |
-
"components/
|
| 774 |
-
"
|
| 775 |
-
"
|
| 776 |
},
|
| 777 |
-
"components/
|
| 778 |
-
"
|
| 779 |
-
"
|
| 780 |
},
|
| 781 |
-
"components/
|
| 782 |
-
"
|
| 783 |
-
"
|
| 784 |
},
|
| 785 |
-
"components/
|
| 786 |
-
"
|
| 787 |
-
"
|
| 788 |
},
|
| 789 |
-
"components/
|
| 790 |
-
"
|
| 791 |
-
"
|
| 792 |
},
|
| 793 |
-
"components/
|
| 794 |
-
"
|
| 795 |
-
"
|
| 796 |
},
|
| 797 |
-
"components/
|
| 798 |
-
"
|
| 799 |
-
"
|
| 800 |
},
|
| 801 |
-
"components/
|
| 802 |
-
"
|
| 803 |
-
"
|
| 804 |
},
|
| 805 |
-
"components/
|
| 806 |
-
"
|
| 807 |
-
"
|
| 808 |
},
|
| 809 |
-
"components/
|
| 810 |
-
"
|
| 811 |
-
"
|
| 812 |
},
|
| 813 |
-
"
|
| 814 |
-
"
|
| 815 |
-
"
|
| 816 |
},
|
| 817 |
"schema.json": {
|
| 818 |
-
"
|
| 819 |
-
"
|
| 820 |
},
|
| 821 |
"tasks.jsonl": {
|
| 822 |
-
"
|
| 823 |
-
"
|
| 824 |
-
},
|
| 825 |
-
"upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/environment/Dockerfile": {
|
| 826 |
-
"sha256": "66b564f58a409177999eda6eea1e5c8009d88c6d72faffa1bac7c497b800a460",
|
| 827 |
-
"bytes": 144
|
| 828 |
-
},
|
| 829 |
-
"upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/instruction.md": {
|
| 830 |
-
"sha256": "21dc586748f23a8630118831399e1c40d62443444d454bf6f5e7f60ba334b06f",
|
| 831 |
-
"bytes": 8121
|
| 832 |
-
},
|
| 833 |
-
"upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/prompt.json": {
|
| 834 |
-
"sha256": "97d07b9814fff65f7cd78bf968d4854aa2aa75e8535ceb574b35a93dbf087db0",
|
| 835 |
-
"bytes": 8269
|
| 836 |
-
},
|
| 837 |
-
"upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/task.toml": {
|
| 838 |
-
"sha256": "45af241c0dc3ed0b71fff4db4b2f334760bc387aaff0a74a6dc9543cce2effe1",
|
| 839 |
-
"bytes": 561
|
| 840 |
-
},
|
| 841 |
-
"upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/tests/coordinate_scoring/__init__.py": {
|
| 842 |
-
"sha256": "8f8067d6fbd793412dd078f35617d367999a644cf040ef4996dfd96c2b2e936f",
|
| 843 |
-
"bytes": 2383
|
| 844 |
-
},
|
| 845 |
-
"upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/tests/coordinate_scoring/parse.py": {
|
| 846 |
-
"sha256": "72035a296ec599f0e4743141a76f8dc908be5ac6a7fd500d36fcbb29b8b3687c",
|
| 847 |
-
"bytes": 15164
|
| 848 |
-
},
|
| 849 |
-
"upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/tests/coordinate_scoring/scorers.py": {
|
| 850 |
-
"sha256": "8046af2d8ca0e74d40ca60624ea3c678b81fa3b76b634818fd96757282f12c34",
|
| 851 |
-
"bytes": 6699
|
| 852 |
-
},
|
| 853 |
-
"upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/tests/gold.json": {
|
| 854 |
-
"sha256": "4ed8e4260bc71b5a863888cd3fa2c7bca6210fc5138f96fd2207462c348318b7",
|
| 855 |
-
"bytes": 253
|
| 856 |
-
},
|
| 857 |
-
"upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/tests/test.sh": {
|
| 858 |
-
"sha256": "bf3f533beddf0e9db369e092e297d2905013f2aedad52919cb1db76ed7a566f7",
|
| 859 |
-
"bytes": 42
|
| 860 |
-
},
|
| 861 |
-
"upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/tests/verifier.toml": {
|
| 862 |
-
"sha256": "628bca2d87aa70d0176cb3a79879c64bbfb07fc53dd094fd3060173b24a76ef4",
|
| 863 |
-
"bytes": 160
|
| 864 |
-
},
|
| 865 |
-
"upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/tests/verify.py": {
|
| 866 |
-
"sha256": "91441587561c00649cec98159d22f64d11b01fff459601cce79579737f0fa37c",
|
| 867 |
-
"bytes": 1558
|
| 868 |
},
|
| 869 |
"validate_dataset.py": {
|
| 870 |
-
"
|
| 871 |
-
"
|
| 872 |
}
|
| 873 |
}
|
| 874 |
}
|
|
|
|
| 1 |
{
|
|
|
|
|
|
|
| 2 |
"files": {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 3 |
"LICENSES/README.txt": {
|
| 4 |
+
"bytes": 343,
|
| 5 |
+
"sha256": "e50227e76c5f0c86594f7fd55d13414bc1615800f93e01f4d4a3d3dd869533d5"
|
|
|
|
|
|
|
|
|
|
|
|
|
| 6 |
},
|
| 7 |
"README.md": {
|
| 8 |
+
"bytes": 1698,
|
| 9 |
+
"sha256": "9b0b7c94692144732a7e73d09b8875feb4734276e42b46656615e07ac99c8142"
|
|
|
|
|
|
|
|
|
|
|
|
|
| 10 |
},
|
| 11 |
"SOURCE_LOCK.json": {
|
| 12 |
+
"bytes": 1979,
|
| 13 |
+
"sha256": "8a55fa76364ae1cd88b1a1da39137400a318c40df4f1ff2941616c51cf5c4f17"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 14 |
},
|
| 15 |
+
"components/audit/Dockerfile": {
|
| 16 |
+
"bytes": 751,
|
| 17 |
+
"sha256": "7c94b391b9d5738860b9270f471e27a99e17255f473b96f7bd1bf46a1d0c82da"
|
| 18 |
},
|
| 19 |
+
"components/audit/NOTICE": {
|
| 20 |
+
"bytes": 226,
|
| 21 |
+
"sha256": "5d85c4ca9560bf6be77c0389e21719d726ff9442c7bc73e37a40d79c021eec47"
|
| 22 |
},
|
| 23 |
+
"components/audit/README.md": {
|
| 24 |
+
"bytes": 194,
|
| 25 |
+
"sha256": "eea2ab8b6a11c6f41afce2488eeaa6d87a6c30f752cb60e76104c83ee02ab074"
|
| 26 |
},
|
| 27 |
+
"components/audit/SOURCE.json": {
|
| 28 |
+
"bytes": 1388,
|
| 29 |
+
"sha256": "0b0eafe25ffa560829dafcdd3ade2625043d5eaa03d725d153f40e6cacc15397"
|
| 30 |
},
|
| 31 |
+
"components/audit/config.json": {
|
| 32 |
+
"bytes": 2342,
|
| 33 |
+
"sha256": "6da4b8c7351046b8bfdb7e1ffe47dd6f40401c008497f2e8245673f356ab142d"
|
| 34 |
},
|
| 35 |
+
"components/audit/runtime/audit/__init__.py": {
|
| 36 |
+
"bytes": 0,
|
| 37 |
+
"sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"
|
| 38 |
},
|
| 39 |
+
"components/audit/runtime/audit/environment.py": {
|
| 40 |
+
"bytes": 5603,
|
| 41 |
+
"sha256": "3ff3233f5b306f1ce9f1db748820711148d5e0cbd663e8691f4163d6b9548d03"
|
| 42 |
},
|
| 43 |
+
"components/audit/runtime/audit/server.py": {
|
| 44 |
+
"bytes": 413,
|
| 45 |
+
"sha256": "dc79acae9a5d8abc4c816377745390421d50f317b5b307a76e64634b886ab8b6"
|
| 46 |
},
|
| 47 |
+
"components/audit/runtime/common/__init__.py": {
|
| 48 |
+
"bytes": 1,
|
| 49 |
+
"sha256": "01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b"
|
| 50 |
},
|
| 51 |
+
"components/audit/runtime/common/contracts.py": {
|
| 52 |
+
"bytes": 1015,
|
| 53 |
+
"sha256": "b1e1429208e84aefc2422ee1d2400ad793c43cd5c0e8db213a3b669fe0947ce1"
|
| 54 |
},
|
| 55 |
+
"components/audit/runtime/common/models.py": {
|
| 56 |
+
"bytes": 1941,
|
| 57 |
+
"sha256": "6a1ac8e55af6168d3fdd6b17c700a15cf0546b6154773aa3c59c97d6bffa2ffd"
|
| 58 |
},
|
| 59 |
+
"components/audit/tasks/auth-05/instruction.md": {
|
| 60 |
+
"bytes": 377,
|
| 61 |
+
"sha256": "e58b70774d5f729ae49c59cb82c019972e889b7353dabe1d6b9eefc085993119"
|
| 62 |
},
|
| 63 |
+
"components/audit/tasks/ledger-01/instruction.md": {
|
| 64 |
+
"bytes": 401,
|
| 65 |
+
"sha256": "141f54a8f1dc40c48f5a691cb2cdc9b15e8f3c029c7c3d500b8f8a054e82152b"
|
| 66 |
},
|
| 67 |
+
"components/audit/upstream/LICENSE": {
|
| 68 |
+
"bytes": 11358,
|
| 69 |
+
"sha256": "cfc7749b96f63bd31c3c42b5c471bf756814053e847c10f3eb003417bc523d30"
|
| 70 |
},
|
| 71 |
+
"components/audit/upstream/audit_trail/__init__.py": {
|
| 72 |
+
"bytes": 199,
|
| 73 |
+
"sha256": "638536fc5897e3dd2aea2ce4671bf321e45d6de0ece20bc857ea38126f058dc8"
|
| 74 |
},
|
| 75 |
+
"components/audit/upstream/audit_trail/models.py": {
|
| 76 |
+
"bytes": 1106,
|
| 77 |
+
"sha256": "5156b42a8bebe5bf119a654f8e081eea0c7614f32933b2fd262c078b66e54276"
|
| 78 |
},
|
| 79 |
+
"components/audit/upstream/audit_trail/server/__init__.py": {
|
| 80 |
+
"bytes": 185,
|
| 81 |
+
"sha256": "c27b096b1833ae60a6dff6108164d107cd5ecd50524a38ba22dd695733011aeb"
|
| 82 |
},
|
| 83 |
+
"components/audit/upstream/audit_trail/server/audit_trail_environment.py": {
|
| 84 |
+
"bytes": 3957,
|
| 85 |
+
"sha256": "5428cf74f5d6a6ea75e67ad2eb061d96ed391bff146c01ece422b984273d1125"
|
| 86 |
},
|
| 87 |
+
"components/audit/upstream/audit_trail/tasks.py": {
|
| 88 |
+
"bytes": 14059,
|
| 89 |
+
"sha256": "c2f1193259d9c0dfecc2645bcc7ba36b01d336cad2aa5cc3c7ed358f9aa27b2a"
|
| 90 |
},
|
| 91 |
+
"components/audit/upstream/dataset/README.md": {
|
| 92 |
+
"bytes": 2214,
|
| 93 |
+
"sha256": "d70f12d0207ac89da7804330af5a207e1784e6603b565b73e40d786de75364b0"
|
| 94 |
},
|
| 95 |
+
"components/audit/upstream/dataset/tasks.jsonl": {
|
| 96 |
+
"bytes": 2104,
|
| 97 |
+
"sha256": "dcb67aca547276783eb5f0da148ebcbd55d69d13cbb6dd437e0108ae971be1e8"
|
| 98 |
},
|
| 99 |
+
"components/dnakhla/.dockerignore": {
|
| 100 |
+
"bytes": 49,
|
| 101 |
+
"sha256": "c04a2771c0665225047882b2da49d452e20d7cc9bc0ea024a48f1cd31411c504"
|
| 102 |
},
|
| 103 |
+
"components/dnakhla/Dockerfile": {
|
| 104 |
+
"bytes": 409,
|
| 105 |
+
"sha256": "a2464ca6190e49c967ccb0b521c8190dba35d94b9b2208e31562161f20f535b8"
|
| 106 |
},
|
| 107 |
+
"components/dnakhla/LICENSE": {
|
| 108 |
+
"bytes": 11358,
|
| 109 |
+
"sha256": "cfc7749b96f63bd31c3c42b5c471bf756814053e847c10f3eb003417bc523d30"
|
| 110 |
},
|
| 111 |
+
"components/dnakhla/NOTICE": {
|
| 112 |
+
"bytes": 351,
|
| 113 |
+
"sha256": "c306489df6e0c1049ff449d672d81e2aa5a78c66665c97b1b4448584be62f8f3"
|
| 114 |
},
|
| 115 |
+
"components/dnakhla/README.md": {
|
| 116 |
+
"bytes": 429,
|
| 117 |
+
"sha256": "f06b54055f7f780cd3bdf94dc3a5fb7d5e8e48f083a29727261fcf51e8f5d209"
|
| 118 |
},
|
| 119 |
+
"components/dnakhla/SOURCE_MANIFEST.json": {
|
| 120 |
+
"bytes": 6280,
|
| 121 |
+
"sha256": "6c0c97d7de7fa1381099f380cd5554d584ed7581e50b0dc2d43d15cd6ae5c1de"
|
| 122 |
},
|
| 123 |
+
"components/dnakhla/runtime/common/__init__.py": {
|
| 124 |
+
"bytes": 1,
|
| 125 |
+
"sha256": "01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b"
|
| 126 |
},
|
| 127 |
+
"components/dnakhla/runtime/common/contracts.py": {
|
| 128 |
+
"bytes": 1015,
|
| 129 |
+
"sha256": "b1e1429208e84aefc2422ee1d2400ad793c43cd5c0e8db213a3b669fe0947ce1"
|
| 130 |
},
|
| 131 |
+
"components/dnakhla/runtime/common/models.py": {
|
| 132 |
+
"bytes": 1941,
|
| 133 |
+
"sha256": "6a1ac8e55af6168d3fdd6b17c700a15cf0546b6154773aa3c59c97d6bffa2ffd"
|
| 134 |
},
|
| 135 |
+
"components/dnakhla/runtime/dnakhla_compat/__init__.py": {
|
| 136 |
+
"bytes": 80,
|
| 137 |
+
"sha256": "adb5e5e6b8d1c5f4d2ff5bbfd4b66038c3d52e4ae50b0d3430c56a196d5ae5c3"
|
| 138 |
},
|
| 139 |
+
"components/dnakhla/runtime/dnakhla_compat/environment.py": {
|
| 140 |
+
"bytes": 6952,
|
| 141 |
+
"sha256": "eaa4d0c0f293f3d53630eda1ad71921a8c1308b1ae375be3041bd3d0afc41369"
|
| 142 |
},
|
| 143 |
+
"components/dnakhla/runtime/dnakhla_compat/server.py": {
|
| 144 |
+
"bytes": 460,
|
| 145 |
+
"sha256": "d64b7539b8cc9f5dcc170dcd0c4c48e6673da923ce0f22b754c7859770032bd8"
|
| 146 |
},
|
| 147 |
+
"components/dnakhla/upstream/openenv.yaml": {
|
| 148 |
+
"bytes": 626,
|
| 149 |
+
"sha256": "8c68fdfde651ec70155ec1a8d4b15f5c14cdd1f9d98197fc5037b49d6dc74524"
|
| 150 |
},
|
| 151 |
+
"components/dnakhla/upstream/terminal_desk/__init__.py": {
|
| 152 |
+
"bytes": 0,
|
| 153 |
+
"sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"
|
| 154 |
},
|
| 155 |
+
"components/dnakhla/upstream/terminal_desk/core/__init__.py": {
|
| 156 |
+
"bytes": 0,
|
| 157 |
+
"sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"
|
| 158 |
},
|
| 159 |
+
"components/dnakhla/upstream/terminal_desk/core/grading.py": {
|
| 160 |
+
"bytes": 16512,
|
| 161 |
+
"sha256": "8606129c5aa3f99cc540a7c8269b65e9bb6c42e81bca36085c16963a0cccd2bd"
|
| 162 |
},
|
| 163 |
+
"components/dnakhla/upstream/terminal_desk/core/shell.py": {
|
| 164 |
+
"bytes": 5014,
|
| 165 |
+
"sha256": "59b4b07b0d59e01792c8dbbf7877555e2da2346ddf5d2c17df3bbd4e17cb847f"
|
| 166 |
},
|
| 167 |
+
"components/dnakhla/upstream/terminal_desk/families/__init__.py": {
|
| 168 |
+
"bytes": 966,
|
| 169 |
+
"sha256": "2ca3d4eda1fb04a84a236fbb43b71d13d46ea68109f545e036842211be3e3958"
|
| 170 |
},
|
| 171 |
+
"components/dnakhla/upstream/terminal_desk/families/base.py": {
|
| 172 |
+
"bytes": 2632,
|
| 173 |
+
"sha256": "d76cab459096d3748d2c4198753853d85418de61f64436cf4772b89345fdcf17"
|
| 174 |
},
|
| 175 |
+
"components/dnakhla/upstream/terminal_desk/families/finance.py": {
|
| 176 |
+
"bytes": 9887,
|
| 177 |
+
"sha256": "312a26e2d48ac10a07716384d3059a697f75f16e5b37fcabb8c07fcac3397f6f"
|
| 178 |
},
|
| 179 |
+
"components/dnakhla/upstream/terminal_desk/families/finance3.py": {
|
| 180 |
+
"bytes": 23433,
|
| 181 |
+
"sha256": "a4839540c7a54198ea8e480248428e9ca65bdaf45adea5ae9f81cad71cbb1311"
|
| 182 |
},
|
| 183 |
+
"components/dnakhla/upstream/terminal_desk/families/industrial.py": {
|
| 184 |
+
"bytes": 8865,
|
| 185 |
+
"sha256": "9140985ca44b1bcfc78b853f44496b7a9b77288284675f3656898de5be70d6aa"
|
| 186 |
},
|
| 187 |
+
"components/dnakhla/upstream/terminal_desk/families/industrial3.py": {
|
| 188 |
+
"bytes": 23945,
|
| 189 |
+
"sha256": "48e914996b67accb09350a6714a5cea4a6191c0a05ac12a8f3045309f961c49c"
|
| 190 |
},
|
| 191 |
+
"components/dnakhla/upstream/terminal_desk/families/mathematics.py": {
|
| 192 |
+
"bytes": 6946,
|
| 193 |
+
"sha256": "552855819cbe4983529b864279c915bc56f8d68d850a3f221d84864066c0e2a5"
|
| 194 |
},
|
| 195 |
+
"components/dnakhla/upstream/terminal_desk/families/mathematics3.py": {
|
| 196 |
+
"bytes": 24030,
|
| 197 |
+
"sha256": "9dc54710cd826aadbe5de55d9093959e38c59dc59ae080e40d379cc4db1987c1"
|
| 198 |
},
|
| 199 |
+
"components/dnakhla/upstream/terminal_desk/families/media.py": {
|
| 200 |
+
"bytes": 7444,
|
| 201 |
+
"sha256": "52523502e6c679e34bd2dbeb46c3f539ba53ae2d4e1033adafca7ce859bc4de8"
|
| 202 |
},
|
| 203 |
+
"components/dnakhla/upstream/terminal_desk/families/media3.py": {
|
| 204 |
+
"bytes": 27612,
|
| 205 |
+
"sha256": "9c91cfbde8ad60da034c15ba3418e21ae5891a12ce3932ecaf8035fcd6eef4bd"
|
| 206 |
},
|
| 207 |
+
"components/dnakhla/upstream/terminal_desk/families/office.py": {
|
| 208 |
+
"bytes": 10356,
|
| 209 |
+
"sha256": "11f76ce7d62e18b535278b487f798703fd6f2bef04dd7ffaefae2c95bcba1102"
|
| 210 |
},
|
| 211 |
+
"components/dnakhla/upstream/terminal_desk/families/office3.py": {
|
| 212 |
+
"bytes": 25496,
|
| 213 |
+
"sha256": "1926c4a6e600cabb4cd35fab9528b4e4d55ef4adc1623b7229ac356ef28c987b"
|
| 214 |
},
|
| 215 |
+
"components/dnakhla/upstream/terminal_desk/families/science.py": {
|
| 216 |
+
"bytes": 10159,
|
| 217 |
+
"sha256": "836ab819a2231700a4bff2929a4579034c45a637992e883ddfbdb0c1f711446a"
|
| 218 |
},
|
| 219 |
+
"components/dnakhla/upstream/terminal_desk/families/science3.py": {
|
| 220 |
+
"bytes": 23969,
|
| 221 |
+
"sha256": "59477a1f9d38dbe5607f6432b4f8538342eec93faeed09bb6c9cb1402980c9a1"
|
| 222 |
},
|
| 223 |
+
"components/dnakhla/upstream/terminal_desk/families/security.py": {
|
| 224 |
+
"bytes": 10341,
|
| 225 |
+
"sha256": "1228db896b6ce796ccf1f133e2f2ba9aaa9d54b745d5ffaf4b584a63a6aab2bd"
|
| 226 |
},
|
| 227 |
+
"components/dnakhla/upstream/terminal_desk/families/security3.py": {
|
| 228 |
+
"bytes": 27080,
|
| 229 |
+
"sha256": "6f5ec9c2dfe9aad81ba382d4f6ffdb7f64493d92cd7fe5d653134ef0dac107af"
|
| 230 |
},
|
| 231 |
+
"components/dnakhla/upstream/terminal_desk/families/software.py": {
|
| 232 |
+
"bytes": 16430,
|
| 233 |
+
"sha256": "4bca03797d701fe33f567729baa9a4fb2cef59cf220d0b79a941cc3817f8ba3a"
|
| 234 |
},
|
| 235 |
+
"components/dnakhla/upstream/terminal_desk/families/software3.py": {
|
| 236 |
+
"bytes": 31784,
|
| 237 |
+
"sha256": "d526ae88ca53ef22dbc1e578055fc27ebb491c184474e662736b8be9523086a7"
|
| 238 |
},
|
| 239 |
+
"components/dnakhla/upstream/terminal_desk/models.py": {
|
| 240 |
+
"bytes": 1750,
|
| 241 |
+
"sha256": "f31264b0909878c6f2d4d18a270c7d92bc895052150c56e5ac3e6b38d4ceebb4"
|
| 242 |
},
|
| 243 |
+
"components/dnakhla/upstream/terminal_desk/oracles/__init__.py": {
|
| 244 |
+
"bytes": 1728,
|
| 245 |
+
"sha256": "04e4b102444b5db19507a46814820d78ad1e9782f963e5764f8f4adfe4d366a3"
|
| 246 |
},
|
| 247 |
+
"components/dnakhla/upstream/terminal_desk/oracles/fin3_invoice_fraud.py": {
|
| 248 |
+
"bytes": 1162,
|
| 249 |
+
"sha256": "975ff8045d42b2f483924e368e304c451bca894ddb4ba593d9dd3aea1c505329"
|
| 250 |
},
|
| 251 |
+
"components/dnakhla/upstream/terminal_desk/oracles/fin3_loan_schedule.py": {
|
| 252 |
+
"bytes": 1752,
|
| 253 |
+
"sha256": "b0a32266ec725f5a4f76d8b40a27fc52759f679d74e4dfe5c7885a1b19a36711"
|
| 254 |
},
|
| 255 |
+
"components/dnakhla/upstream/terminal_desk/oracles/fin3_portfolio_value.py": {
|
| 256 |
+
"bytes": 1729,
|
| 257 |
+
"sha256": "152a3516b9ec6811121747ea875fc1a73cb768ba6a98e05c2bee91325e4f7247"
|
| 258 |
},
|
| 259 |
+
"components/dnakhla/upstream/terminal_desk/oracles/ind3_service_due.py": {
|
| 260 |
+
"bytes": 1819,
|
| 261 |
+
"sha256": "47914a6e1a5bde126ce301bc11d4dc95b11cb0910ac0208a4c78596d7e65e30e"
|
| 262 |
},
|
| 263 |
+
"components/dnakhla/upstream/terminal_desk/oracles/ind3_stl_mass.py": {
|
| 264 |
+
"bytes": 1562,
|
| 265 |
+
"sha256": "53e6adc26768256ce6665bda20c4b04ad87602e24eb31b074c25dc8fbbc00653"
|
| 266 |
},
|
| 267 |
+
"components/dnakhla/upstream/terminal_desk/oracles/ind3_tank_balance.py": {
|
| 268 |
+
"bytes": 1573,
|
| 269 |
+
"sha256": "c1049fdb6b4f11f0b5e0194b41e84b525d5a340213c2c94f5f99ffd6c2b75a42"
|
| 270 |
},
|
| 271 |
+
"components/dnakhla/upstream/terminal_desk/oracles/math3_count_items.py": {
|
| 272 |
+
"bytes": 1005,
|
| 273 |
+
"sha256": "0fd62812cd9ef1d5be6d6ae9fa2fa047eb6bb0a4508ccb5a5369373aefbf8dd3"
|
| 274 |
},
|
| 275 |
+
"components/dnakhla/upstream/terminal_desk/oracles/math3_exam_slots.py": {
|
| 276 |
+
"bytes": 1770,
|
| 277 |
+
"sha256": "03908ec43159f4a66678f37fb0366389608eeeba41361758d966c96eea50dc3f"
|
| 278 |
},
|
| 279 |
+
"components/dnakhla/upstream/terminal_desk/oracles/math3_route_plan.py": {
|
| 280 |
+
"bytes": 1686,
|
| 281 |
+
"sha256": "c2bb32b08a3705a4be56ff8c4e3af94d64441c9a7432f5dcec4dce0b378ee465"
|
| 282 |
},
|
| 283 |
+
"components/dnakhla/upstream/terminal_desk/oracles/med3_silence_report.py": {
|
| 284 |
+
"bytes": 1602,
|
| 285 |
+
"sha256": "554e36455da66fd258e6ad2c39e80acbc3856237fee4608ce57b494f23c3d16d"
|
| 286 |
},
|
| 287 |
+
"components/dnakhla/upstream/terminal_desk/oracles/med3_sprite_count.py": {
|
| 288 |
+
"bytes": 1517,
|
| 289 |
+
"sha256": "8f0a1169d6e5b10c4981b53a22e957c4befad44d95e5d250cf53734105a40256"
|
| 290 |
},
|
| 291 |
+
"components/dnakhla/upstream/terminal_desk/oracles/med3_subtitle_retime.py": {
|
| 292 |
+
"bytes": 1494,
|
| 293 |
+
"sha256": "72f448ba58ac9ee6082692dec88ddb6f279ae69bdb99d39b30d1acce12c19bfe"
|
| 294 |
},
|
| 295 |
+
"components/dnakhla/upstream/terminal_desk/oracles/off3_ar_recon.py": {
|
| 296 |
+
"bytes": 1454,
|
| 297 |
+
"sha256": "b5320a71696443f1b04c0c5e02e35d0baee67a175a912bff86e32df7c2acb357"
|
| 298 |
},
|
| 299 |
+
"components/dnakhla/upstream/terminal_desk/oracles/off3_meeting_slot.py": {
|
| 300 |
+
"bytes": 1711,
|
| 301 |
+
"sha256": "6eef5e15337e5029c8e0b3353adee791ea9ebe73c6d79e47d84d6b7294cb5a38"
|
| 302 |
},
|
| 303 |
+
"components/dnakhla/upstream/terminal_desk/oracles/off3_pdf_xlsx_diff.py": {
|
| 304 |
+
"bytes": 1301,
|
| 305 |
+
"sha256": "82b5c15f02a03615699429a2342dbad4b8985aab76d82fa8a8b96f7fbebc544f"
|
| 306 |
},
|
| 307 |
+
"components/dnakhla/upstream/terminal_desk/oracles/sci3_kinetics_fit.py": {
|
| 308 |
+
"bytes": 1527,
|
| 309 |
+
"sha256": "1ebc19667bf1963c83a47bd4905e99e0c32c3ce249b63ae2d7b39fcffa1b1bb7"
|
| 310 |
},
|
| 311 |
+
"components/dnakhla/upstream/terminal_desk/oracles/sci3_lightcurve_period.py": {
|
| 312 |
+
"bytes": 1540,
|
| 313 |
+
"sha256": "a983fb3c03ba15bc0591ab32ce41ddb99f2f38329e273f3f5da20f775d6bd8ab"
|
| 314 |
},
|
| 315 |
+
"components/dnakhla/upstream/terminal_desk/oracles/sci3_stoich_batch.py": {
|
| 316 |
+
"bytes": 1747,
|
| 317 |
+
"sha256": "56a84763e746f034571dc50a71f3716f340e4f8d9dee823eb3c9b209f471f48a"
|
| 318 |
},
|
| 319 |
+
"components/dnakhla/upstream/terminal_desk/oracles/sec3_auth_triage.py": {
|
| 320 |
+
"bytes": 1443,
|
| 321 |
+
"sha256": "c5fb5f697e8cfdb6008fcd59d6c3095a509d9a488dc28d7b99da4f4fe128b8a6"
|
| 322 |
},
|
| 323 |
+
"components/dnakhla/upstream/terminal_desk/oracles/sec3_exfil_flows.py": {
|
| 324 |
+
"bytes": 1425,
|
| 325 |
+
"sha256": "5a4cc8a38f0554be4b287e2592bd26553db2f3ee6b5c10339d641246a7a6af90"
|
| 326 |
},
|
| 327 |
+
"components/dnakhla/upstream/terminal_desk/oracles/sec3_fw_verdicts.py": {
|
| 328 |
+
"bytes": 1668,
|
| 329 |
+
"sha256": "b91c7389813445d55edbdaadec60aa4c5d0b6c5ead6fdfca5268e425f512820f"
|
| 330 |
},
|
| 331 |
+
"components/dnakhla/upstream/terminal_desk/oracles/sw3_dep_lock.py": {
|
| 332 |
+
"bytes": 1715,
|
| 333 |
+
"sha256": "6b46601bc7e4bdc42c62242344aa431a34e7a6d1a8c7201e77315c66c6a4ae09"
|
| 334 |
},
|
| 335 |
+
"components/dnakhla/upstream/terminal_desk/oracles/sw3_fix_module.py": {
|
| 336 |
+
"bytes": 1831,
|
| 337 |
+
"sha256": "43eee7f24a02ca3f0d3b12db5a44c132a931fc8dba10f9c1d4028d7fa5775bf4"
|
| 338 |
},
|
| 339 |
+
"components/dnakhla/upstream/terminal_desk/oracles/sw3_rate_limit.py": {
|
| 340 |
+
"bytes": 1553,
|
| 341 |
+
"sha256": "4f1f187ae42f47faecc85d84e1f0341c848b03eb2bba1bf538927e2e62758314"
|
| 342 |
},
|
| 343 |
+
"components/dnakhla/upstream/terminal_desk/server/__init__.py": {
|
| 344 |
+
"bytes": 0,
|
| 345 |
+
"sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"
|
| 346 |
},
|
| 347 |
+
"components/dnakhla/upstream/terminal_desk/server/app.py": {
|
| 348 |
+
"bytes": 802,
|
| 349 |
+
"sha256": "6bf7658ec8ad07dda230a01fd893091a9b87df18ebf6af25af6c35965ed01fd8"
|
| 350 |
},
|
| 351 |
+
"components/dnakhla/upstream/terminal_desk/server/environment.py": {
|
| 352 |
+
"bytes": 8350,
|
| 353 |
+
"sha256": "8e92f991e14098a0858490fe5beb43ca9b0ee2cfbddb36e73ecf987ba3922902"
|
| 354 |
},
|
| 355 |
+
"components/loui/.dockerignore": {
|
| 356 |
+
"bytes": 18,
|
| 357 |
+
"sha256": "05cc6ae53cfd6129f1d7010aa874c6cf0a6019b1adfeff3f4fab27f2d04f43ca"
|
| 358 |
},
|
| 359 |
+
"components/loui/Dockerfile": {
|
| 360 |
+
"bytes": 320,
|
| 361 |
+
"sha256": "225304d22825c251c46ab771cabdb176edce0efe249789c528573e8bc42c904d"
|
| 362 |
},
|
| 363 |
+
"components/loui/README.md": {
|
| 364 |
+
"bytes": 486,
|
| 365 |
+
"sha256": "0ab8e0b3aa9790d6aa7d273727bf5ccd2fc0c49d57a4075eeb6022b93c55693f"
|
| 366 |
},
|
| 367 |
+
"components/loui/SOURCE.json": {
|
| 368 |
+
"bytes": 1115,
|
| 369 |
+
"sha256": "4da7db21c634d28a954e5f83145d7f6b2de7a5b1ab62ac193f815e6684ab1406"
|
| 370 |
},
|
| 371 |
+
"components/loui/config.json": {
|
| 372 |
+
"bytes": 1509,
|
| 373 |
+
"sha256": "bfad19ee80d40545950d8e47c7772d548d5b26f3e7873f1ff18d1ceeed04d5ee"
|
| 374 |
},
|
| 375 |
+
"components/loui/runtime/common/__init__.py": {
|
| 376 |
+
"bytes": 1,
|
| 377 |
+
"sha256": "01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b"
|
| 378 |
},
|
| 379 |
+
"components/loui/runtime/common/contracts.py": {
|
| 380 |
+
"bytes": 1015,
|
| 381 |
+
"sha256": "b1e1429208e84aefc2422ee1d2400ad793c43cd5c0e8db213a3b669fe0947ce1"
|
| 382 |
},
|
| 383 |
+
"components/loui/runtime/common/models.py": {
|
| 384 |
+
"bytes": 1941,
|
| 385 |
+
"sha256": "6a1ac8e55af6168d3fdd6b17c700a15cf0546b6154773aa3c59c97d6bffa2ffd"
|
| 386 |
},
|
| 387 |
+
"components/loui/runtime/loui/__init__.py": {
|
| 388 |
+
"bytes": 0,
|
| 389 |
+
"sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"
|
| 390 |
},
|
| 391 |
+
"components/loui/runtime/loui/child.py": {
|
| 392 |
+
"bytes": 3172,
|
| 393 |
+
"sha256": "c4774351bdbd8a044cd20bcd7111ac4db7403feccb9444acf663e71140b27888"
|
| 394 |
},
|
| 395 |
+
"components/loui/runtime/loui/environment.py": {
|
| 396 |
+
"bytes": 7292,
|
| 397 |
+
"sha256": "edd467b474dc0982c9b6c91a9f0150432fa8b9a5c6b62c8187bc9cc9f440a22a"
|
| 398 |
},
|
| 399 |
+
"components/loui/runtime/loui/executor.py": {
|
| 400 |
+
"bytes": 4126,
|
| 401 |
+
"sha256": "eb1bb1ea6b9747c0541e592d6f39b3c543bc8e5f760dbdda4ead54eaea44cd8e"
|
| 402 |
},
|
| 403 |
+
"components/loui/runtime/loui/server.py": {
|
| 404 |
+
"bytes": 411,
|
| 405 |
+
"sha256": "c3ae4e00495724083e73085bd4dccdf3493094ef2e14c0bb017f6502d264244b"
|
| 406 |
},
|
| 407 |
+
"components/loui/tasks/expression-3/instruction.md": {
|
| 408 |
+
"bytes": 955,
|
| 409 |
+
"sha256": "09ef2d8fc856ca3dc5662c279df705e9accc827f4472dc34758ffe769d116128"
|
| 410 |
},
|
| 411 |
+
"components/loui/upstream/LICENSE": {
|
| 412 |
+
"bytes": 1070,
|
| 413 |
+
"sha256": "a5958627f5ebeaf73b280a5b983d86d79c2144c988d761ea7769158788a90de6"
|
| 414 |
},
|
| 415 |
+
"components/loui/upstream/v3/README.md": {
|
| 416 |
+
"bytes": 7857,
|
| 417 |
+
"sha256": "bf5da0c7b871459278ad174cfd3c4ba90de9fbe74d35decce007bed13535d32d"
|
| 418 |
},
|
| 419 |
+
"components/loui/upstream/v3/execution.py": {
|
| 420 |
+
"bytes": 8431,
|
| 421 |
+
"sha256": "578814be5152b9b00c7eeae387544a94db159c9e8e3456e5cb56b31b6a731e9a"
|
| 422 |
},
|
| 423 |
+
"components/loui/upstream/v3/hard_tasks.py": {
|
| 424 |
+
"bytes": 8476,
|
| 425 |
+
"sha256": "f140fcf554e97b67afb14e961affc46c14320cb784fe1f7444585e77ceb89ea0"
|
| 426 |
},
|
| 427 |
+
"components/loui/upstream/v3/server.py": {
|
| 428 |
+
"bytes": 4068,
|
| 429 |
+
"sha256": "67f546daef6e7902c12754cbbd883657e57d2cb21e109275af123c552cc93422"
|
| 430 |
},
|
| 431 |
+
"components/loui/upstream/v3/tasks.jsonl": {
|
| 432 |
+
"bytes": 87084,
|
| 433 |
+
"sha256": "9715cdabe6e67287399a3fe2bad435852510bf854982d2f6695b3d87db395c88"
|
| 434 |
},
|
| 435 |
+
"components/loui/upstream/v3/tasks.py": {
|
| 436 |
+
"bytes": 22139,
|
| 437 |
+
"sha256": "71caf0175532025bf138398229d466f18e5e03365b48853efd92f61f6dae2d66"
|
| 438 |
},
|
| 439 |
+
"components/metaharness/.dockerignore": {
|
| 440 |
+
"bytes": 184,
|
| 441 |
+
"sha256": "54805fba51273053c3dd388970db3b31aae4de8e5998f1c05e735c18e242857f"
|
| 442 |
},
|
| 443 |
+
"components/metaharness/Dockerfile": {
|
| 444 |
+
"bytes": 395,
|
| 445 |
+
"sha256": "1bfc7ebdbe65d93c93fa3122a2efb3e3cf8f6c138113fb6be9d09e5bfe2061ba"
|
| 446 |
},
|
| 447 |
+
"components/metaharness/LICENSE": {
|
| 448 |
+
"bytes": 1080,
|
| 449 |
+
"sha256": "09ed6717912f408da29e15b55170cd56c9658218a540b7c72e70909b9101274c"
|
| 450 |
},
|
| 451 |
+
"components/metaharness/NOTICE": {
|
| 452 |
+
"bytes": 628,
|
| 453 |
+
"sha256": "605977e7d6dcc2b1eda0dfc6501d2b1d5c64c129ff84e793a9a983919530e1ed"
|
| 454 |
},
|
| 455 |
+
"components/metaharness/README.md": {
|
| 456 |
+
"bytes": 666,
|
| 457 |
+
"sha256": "99e6a092e24b941b4ac79a57eeb593beff579f199d3994f73aa7e538f98398d9"
|
| 458 |
},
|
| 459 |
+
"components/metaharness/SOURCE.json": {
|
| 460 |
+
"bytes": 3078,
|
| 461 |
+
"sha256": "6bea52680ab6b140300653d1c98c356dbd0bc9c8da4bab722b21071baa7ec4a9"
|
| 462 |
},
|
| 463 |
+
"components/metaharness/TASKS.json": {
|
| 464 |
+
"bytes": 586,
|
| 465 |
+
"sha256": "3f122a94c8aecb947b4f95bc2a8d67980ec9a9bc2b7adeea3b1c5e08c3504e06"
|
| 466 |
},
|
| 467 |
+
"components/metaharness/runtime/common/__init__.py": {
|
| 468 |
+
"bytes": 1,
|
| 469 |
+
"sha256": "01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b"
|
| 470 |
},
|
| 471 |
+
"components/metaharness/runtime/common/contracts.py": {
|
| 472 |
+
"bytes": 1015,
|
| 473 |
+
"sha256": "b1e1429208e84aefc2422ee1d2400ad793c43cd5c0e8db213a3b669fe0947ce1"
|
| 474 |
},
|
| 475 |
+
"components/metaharness/runtime/common/models.py": {
|
| 476 |
+
"bytes": 1941,
|
| 477 |
+
"sha256": "6a1ac8e55af6168d3fdd6b17c700a15cf0546b6154773aa3c59c97d6bffa2ffd"
|
| 478 |
},
|
| 479 |
+
"components/metaharness/runtime/shared_adapter.py": {
|
| 480 |
+
"bytes": 5550,
|
| 481 |
+
"sha256": "485aa11684c1ca537e3f439ceb3e2bcdfb8848e1012ada02cb5783ae3deeb02d"
|
| 482 |
},
|
| 483 |
+
"components/metaharness/upstream/Dockerfile": {
|
| 484 |
+
"bytes": 797,
|
| 485 |
+
"sha256": "ceddb0dfe82b01ae91859db2215fa697381064801f0eb0a4d96dd6d0473bd25e"
|
| 486 |
},
|
| 487 |
+
"components/metaharness/upstream/README.md": {
|
| 488 |
+
"bytes": 13521,
|
| 489 |
+
"sha256": "8802e5b5d1796dc9d15647705598971ec4be2e7b53e6b30556440a5ebb89d069"
|
| 490 |
},
|
| 491 |
+
"components/metaharness/upstream/arena_env/__init__.py": {
|
| 492 |
+
"bytes": 58,
|
| 493 |
+
"sha256": "d0cca47bd35b44e121fb394856996d9f2271c29528b73d5b6160ab63f47f9a0f"
|
| 494 |
},
|
| 495 |
+
"components/metaharness/upstream/arena_env/app.py": {
|
| 496 |
+
"bytes": 252,
|
| 497 |
+
"sha256": "62815cb244cb4404379dc28e897503994bef49a8e4f4b5721dace574a8865c63"
|
| 498 |
},
|
| 499 |
+
"components/metaharness/upstream/arena_env/environment.py": {
|
| 500 |
+
"bytes": 4280,
|
| 501 |
+
"sha256": "d6882e2c9dabf1ee0fde75df0acdef85670598da633ce523cf54038fd40562a9"
|
| 502 |
},
|
| 503 |
+
"components/metaharness/upstream/arena_env/tasks.py": {
|
| 504 |
+
"bytes": 44343,
|
| 505 |
+
"sha256": "94e29b6d884302f57e9440591cca5c07350cc4eb47d9e4e9f7a27689c519b781"
|
| 506 |
},
|
| 507 |
+
"components/metaharness/upstream/requirements.lock": {
|
| 508 |
+
"bytes": 2008,
|
| 509 |
+
"sha256": "3fbed6fc6af3931cdacd290353a02ba1740222974c91a022145ec4e6a5f3a347"
|
| 510 |
},
|
| 511 |
+
"components/metaharness/upstream/tasks.selected.jsonl": {
|
| 512 |
+
"bytes": 564203,
|
| 513 |
+
"sha256": "bb488a65100922227f9e7e8288beced72577c44cec8c2aa7a54be446d6ce9606"
|
| 514 |
},
|
| 515 |
"schema.json": {
|
| 516 |
+
"bytes": 1911,
|
| 517 |
+
"sha256": "10993deaaa8553929fa0b3b6bf3c1ad100baaaf9ff10ae8ed139a8ec4279a3c4"
|
| 518 |
},
|
| 519 |
"tasks.jsonl": {
|
| 520 |
+
"bytes": 11261,
|
| 521 |
+
"sha256": "8bd6a842e43e36b3200d5b536d66ba3c66635c9ce4fe1ca812b561e25fc84182"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 522 |
},
|
| 523 |
"validate_dataset.py": {
|
| 524 |
+
"bytes": 1260,
|
| 525 |
+
"sha256": "59c642280ff82be024351b29b654a8f7b1eea9e101fc0579c79a3e258e2f2c29"
|
| 526 |
}
|
| 527 |
}
|
| 528 |
}
|
README.md
CHANGED
|
@@ -10,7 +10,6 @@ size_categories:
|
|
| 10 |
- n<1K
|
| 11 |
tags:
|
| 12 |
- openenv
|
| 13 |
-
- harbor
|
| 14 |
- multi-domain
|
| 15 |
configs:
|
| 16 |
- config_name: default
|
|
@@ -19,27 +18,21 @@ configs:
|
|
| 19 |
path: tasks.jsonl
|
| 20 |
---
|
| 21 |
|
| 22 |
-
|
| 23 |
|
| 24 |
-
|
|
| 25 |
|---|---:|---|
|
| 26 |
-
|
|
| 27 |
-
|
|
| 28 |
-
|
|
| 29 |
-
|
|
| 30 |
-
| Video analysis | 1 | TMax |
|
| 31 |
-
| Physical parameter identification | 1 | TMax |
|
| 32 |
-
| Mathematical constraint construction | 1 | MathConstruct |
|
| 33 |
-
| Protein geometry | 1 | PDBThink |
|
| 34 |
|
| 35 |
-
|
| 36 |
|
| 37 |
-
|
| 38 |
|
| 39 |
-
`
|
| 40 |
-
|
| 41 |
-
Validate a downloaded dataset and restore required empty source directories:
|
| 42 |
|
| 43 |
```sh
|
| 44 |
-
python3 -B
|
| 45 |
```
|
|
|
|
| 10 |
- n<1K
|
| 11 |
tags:
|
| 12 |
- openenv
|
|
|
|
| 13 |
- multi-domain
|
| 14 |
configs:
|
| 15 |
- config_name: default
|
|
|
|
| 18 |
path: tasks.jsonl
|
| 19 |
---
|
| 20 |
|
| 21 |
+
Thirteen original tasks for file workflows, structured reasoning, log auditing and expression repair, served by four OpenEnv images.
|
| 22 |
|
| 23 |
+
| Source | Tasks | Content |
|
| 24 |
|---|---:|---|
|
| 25 |
+
| Terminal Desk | 5 | Reconciliation, meeting scheduling, PDF/spreadsheet comparison and kinetics fitting |
|
| 26 |
+
| MetaHarness | 5 | Contact reconciliation, media timelines, security triage, graph routes and calibration |
|
| 27 |
+
| Audit Trail | 2 | Authentication and transaction logs |
|
| 28 |
+
| Python Repair Lab | 1 | Expression parsing and evaluation |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 29 |
|
| 30 |
+
Original generators and graders are retained. Terminal Desk generates a fresh instance at reset. MetaHarness uses an explicit seed when supplied and otherwise generates a random instance. Audit Trail restores its fixed original logs. Python Repair uses the original seed behavior, with default seed 0.
|
| 31 |
|
| 32 |
+
All images expose `schema.json`. Use `op=exec`, `op=call` with a tool listed at reset, or `op=finish`. Each component preserves its original available tools and action limits.
|
| 33 |
|
| 34 |
+
`tasks.jsonl` records the registered tasks and pinned sources. `components/` contains original materials and runtime adapters. `SOURCE_LOCK.json`, `MANIFEST.json` and `SHA256SUMS` record provenance and file hashes. Attribution and licenses are in `LICENSES/README.txt` and the component notices.
|
|
|
|
|
|
|
| 35 |
|
| 36 |
```sh
|
| 37 |
+
python3 -B validate_dataset.py
|
| 38 |
```
|
REGISTRATION.json
DELETED
|
@@ -1,24 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"selected_count": 11,
|
| 3 |
-
"selected_task_ids": [
|
| 4 |
-
"awm-accounting-1-invoice",
|
| 5 |
-
"incident-3",
|
| 6 |
-
"task_008667_2151f271",
|
| 7 |
-
"construct-mc-costas-array-l3-s0",
|
| 8 |
-
"task_000260_7b7cc286",
|
| 9 |
-
"task_000663_dff2c340",
|
| 10 |
-
"pdbthink-s09-7ba4aa076b6bb5633953",
|
| 11 |
-
"expression-3",
|
| 12 |
-
"task_000056_f726766b",
|
| 13 |
-
"task_005684_3c8594a3",
|
| 14 |
-
"task_008998_ae4cbe72"
|
| 15 |
-
],
|
| 16 |
-
"skill_family_count": 8,
|
| 17 |
-
"unregistered_available_tasks": {
|
| 18 |
-
"math": [],
|
| 19 |
-
"tmax": [],
|
| 20 |
-
"awm": [],
|
| 21 |
-
"pdbthink": [],
|
| 22 |
-
"loui": []
|
| 23 |
-
}
|
| 24 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
SHA256SUMS
CHANGED
|
@@ -1,59 +1,105 @@
|
|
| 1 |
-
|
| 2 |
-
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
|
| 19 |
-
|
| 20 |
-
|
| 21 |
-
|
| 22 |
-
|
| 23 |
-
|
| 24 |
-
|
| 25 |
-
|
| 26 |
-
|
| 27 |
-
|
| 28 |
-
|
| 29 |
-
|
| 30 |
-
|
| 31 |
-
|
| 32 |
-
|
| 33 |
-
|
| 34 |
-
|
| 35 |
-
|
| 36 |
-
|
| 37 |
-
|
| 38 |
-
|
| 39 |
-
|
| 40 |
-
|
| 41 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 42 |
05cc6ae53cfd6129f1d7010aa874c6cf0a6019b1adfeff3f4fab27f2d04f43ca components/loui/.dockerignore
|
| 43 |
-
|
| 44 |
-
|
| 45 |
-
|
| 46 |
-
|
| 47 |
01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b components/loui/runtime/common/__init__.py
|
| 48 |
b1e1429208e84aefc2422ee1d2400ad793c43cd5c0e8db213a3b669fe0947ce1 components/loui/runtime/common/contracts.py
|
| 49 |
-
|
| 50 |
e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855 components/loui/runtime/loui/__init__.py
|
| 51 |
c4774351bdbd8a044cd20bcd7111ac4db7403feccb9444acf663e71140b27888 components/loui/runtime/loui/child.py
|
| 52 |
edd467b474dc0982c9b6c91a9f0150432fa8b9a5c6b62c8187bc9cc9f440a22a components/loui/runtime/loui/environment.py
|
| 53 |
-
|
| 54 |
c3ae4e00495724083e73085bd4dccdf3493094ef2e14c0bb017f6502d264244b components/loui/runtime/loui/server.py
|
| 55 |
09ef2d8fc856ca3dc5662c279df705e9accc827f4472dc34758ffe769d116128 components/loui/tasks/expression-3/instruction.md
|
| 56 |
-
682c7db0f0911e85174652574349fbe957c1cc235a68d224c569e405d9674452 components/loui/tasks/incident-3/instruction.md
|
| 57 |
a5958627f5ebeaf73b280a5b983d86d79c2144c988d761ea7769158788a90de6 components/loui/upstream/LICENSE
|
| 58 |
bf5da0c7b871459278ad174cfd3c4ba90de9fbe74d35decce007bed13535d32d components/loui/upstream/v3/README.md
|
| 59 |
578814be5152b9b00c7eeae387544a94db159c9e8e3456e5cb56b31b6a731e9a components/loui/upstream/v3/execution.py
|
|
@@ -61,158 +107,25 @@ f140fcf554e97b67afb14e961affc46c14320cb784fe1f7444585e77ceb89ea0 components/lou
|
|
| 61 |
67f546daef6e7902c12754cbbd883657e57d2cb21e109275af123c552cc93422 components/loui/upstream/v3/server.py
|
| 62 |
9715cdabe6e67287399a3fe2bad435852510bf854982d2f6695b3d87db395c88 components/loui/upstream/v3/tasks.jsonl
|
| 63 |
71caf0175532025bf138398229d466f18e5e03365b48853efd92f61f6dae2d66 components/loui/upstream/v3/tasks.py
|
| 64 |
-
|
| 65 |
-
|
| 66 |
-
|
| 67 |
-
|
| 68 |
-
|
| 69 |
-
|
| 70 |
-
|
| 71 |
-
|
| 72 |
-
|
| 73 |
-
|
| 74 |
-
|
| 75 |
-
|
| 76 |
-
|
| 77 |
-
|
| 78 |
-
|
| 79 |
-
|
| 80 |
-
|
| 81 |
-
|
| 82 |
-
|
| 83 |
-
db4dc3e27abe2dc45cc29b534882975aa9ea8e5b8ebedb67c943fad83810805b components/math/runtime/native_shell/launch_service.py
|
| 84 |
-
1401916b276c6a19805b8bf405d11ffb014794c59a1eda55a91fa2edf06a0e7e components/math/runtime/native_shell/process_scope.py
|
| 85 |
-
c8bb079f359fe4ac6c1764cbf47fdcfaa3f3caee35ff6c41e845bee3e965d454 components/math/runtime/native_shell/server.py
|
| 86 |
-
6934b8fa5117549cb5ba30a1e6ebbd00df2bf4191ba10765473d05a3fd346465 components/math/runtime/native_shell/verifier_launcher.py
|
| 87 |
-
b8b67cfcd0115be0bcd984543e962adebe2528dc2cd18324e032d155563220af components/math/runtime/native_shell/wire_client.py
|
| 88 |
-
56b0b880643a6915bad1e66b9d127578e69853f00a5e198ddfdf3d72a490fa1c components/math/upstream/construct-mc-costas-array-l3-s0/environment/Dockerfile
|
| 89 |
-
15a02495c009c52f7cbc0f2c1daa95e0a4d0981026e123b83aaa892565fd68b5 components/math/upstream/construct-mc-costas-array-l3-s0/environment/instance.json
|
| 90 |
-
88e4a26e71d8483fbc89627210e4ed07f6dfef0fb16ce3e6d31e84a04bd050f9 components/math/upstream/construct-mc-costas-array-l3-s0/instruction.md
|
| 91 |
-
b62ba527da418f1b84d165707ea56ea805953289b0993cc3176e988ef59c3d32 components/math/upstream/construct-mc-costas-array-l3-s0/task.toml
|
| 92 |
-
3c0290e35201f077926099989cd0e82c10bf091cb33c572cacc02bca075debdb components/math/upstream/construct-mc-costas-array-l3-s0/tests/check.py
|
| 93 |
-
15a02495c009c52f7cbc0f2c1daa95e0a4d0981026e123b83aaa892565fd68b5 components/math/upstream/construct-mc-costas-array-l3-s0/tests/instance.json
|
| 94 |
-
d364958443f46cf3ebb71808afc270e23203f62550246eb5008a847a8701bd73 components/math/upstream/construct-mc-costas-array-l3-s0/tests/run.py
|
| 95 |
-
a35b815edf35d07fee8b5b341be2af0539010888f73ce39a0c15f025367eae3e components/math/upstream/construct-mc-costas-array-l3-s0/tests/test.sh
|
| 96 |
-
b0cbd2dbfe130357ab86c48b3f0ee1acca985828022542d97f1f9d77e147f261 components/pdbthink/DEPENDENCIES.json
|
| 97 |
-
a059eac1b72cef773aee8d849c48f0b090e5d87802cfdf8ae3e8456595ba4e87 components/pdbthink/Dockerfile
|
| 98 |
-
6329e8c6c33a5f04e11dbdcba6f43bb7dba10439d969a97b28901d7681ece8b6 components/pdbthink/config.json
|
| 99 |
-
7c98afbca1961f056579b344a5552c574582c6c19926578a748519fdd99496d7 components/pdbthink/licenses/DEPENDENCIES.json
|
| 100 |
-
c71d239df91726fc519c6eb72d318ec65820627232b2f796219e87dcf35d0ab4 components/pdbthink/licenses/LICENSE-PDBTHINK
|
| 101 |
-
b799de2e9e91ea8ee515bca1fee21cef759b73938cf952e629c8fb9543cc6638 components/pdbthink/licenses/SOURCE.json
|
| 102 |
-
7d267c32438351a4d92533f6e9960da36a1e39c768ad56988904029cb90da0c5 components/pdbthink/private/tasks/pdbthink-s09-7ba4aa076b6bb5633953/public_task.json
|
| 103 |
-
8f8067d6fbd793412dd078f35617d367999a644cf040ef4996dfd96c2b2e936f components/pdbthink/private/tasks/pdbthink-s09-7ba4aa076b6bb5633953/tests/coordinate_scoring/__init__.py
|
| 104 |
-
72035a296ec599f0e4743141a76f8dc908be5ac6a7fd500d36fcbb29b8b3687c components/pdbthink/private/tasks/pdbthink-s09-7ba4aa076b6bb5633953/tests/coordinate_scoring/parse.py
|
| 105 |
-
8046af2d8ca0e74d40ca60624ea3c678b81fa3b76b634818fd96757282f12c34 components/pdbthink/private/tasks/pdbthink-s09-7ba4aa076b6bb5633953/tests/coordinate_scoring/scorers.py
|
| 106 |
-
4ed8e4260bc71b5a863888cd3fa2c7bca6210fc5138f96fd2207462c348318b7 components/pdbthink/private/tasks/pdbthink-s09-7ba4aa076b6bb5633953/tests/gold.json
|
| 107 |
-
bf3f533beddf0e9db369e092e297d2905013f2aedad52919cb1db76ed7a566f7 components/pdbthink/private/tasks/pdbthink-s09-7ba4aa076b6bb5633953/tests/test.sh
|
| 108 |
-
628bca2d87aa70d0176cb3a79879c64bbfb07fc53dd094fd3060173b24a76ef4 components/pdbthink/private/tasks/pdbthink-s09-7ba4aa076b6bb5633953/tests/verifier.toml
|
| 109 |
-
91441587561c00649cec98159d22f64d11b01fff459601cce79579737f0fa37c components/pdbthink/private/tasks/pdbthink-s09-7ba4aa076b6bb5633953/tests/verify.py
|
| 110 |
-
0078892ae5870080b3417677926bc64f4f87ba9e8110ff400f18954e361455fc components/pdbthink/requirements.lock
|
| 111 |
-
01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b components/pdbthink/runtime/common/__init__.py
|
| 112 |
-
b1e1429208e84aefc2422ee1d2400ad793c43cd5c0e8db213a3b669fe0947ce1 components/pdbthink/runtime/common/contracts.py
|
| 113 |
-
7263c04e9175faf66501ed9b2ac2f9a637557a8b1966d839fb9944eb01abac0e components/pdbthink/runtime/common/http_routes.py
|
| 114 |
-
26e7a67537ce7ae34909b724243c37242b9c8055cbfe0c717179dac74347786a components/pdbthink/runtime/common/models.py
|
| 115 |
-
9f56e761d79bfdb34304a012586cb04d16b435ef6130091a97702e559260a2f2 components/pdbthink/runtime/pdbthink/__init__.py
|
| 116 |
-
1683d5e2fab016801207ecdde6cbd4d3730ed8c4ca22aafd0f3bf651dce0faf1 components/pdbthink/runtime/pdbthink/adapter.py
|
| 117 |
-
cc89f1e687da1a71af567ac450fd761da0e5d4fe56901695de304aabd81c59bd components/pdbthink/runtime/pdbthink/launch_service.py
|
| 118 |
-
7ab1b3b05068cd5b0f20497062a8da5fd905c45e8eee295cb8f2fc5c7aca6577 components/pdbthink/runtime/pdbthink/openenv_app.py
|
| 119 |
-
76012b37d916b4044c6fe1da4e7accdf9faa2216f50c73d5b87cd12b7f1d70cf components/pdbthink/runtime/pdbthink/server.py
|
| 120 |
-
b1f6f82ff9e113aedd742a8f4b0c18c545020677503765ee913c31e20964b96f components/pdbthink/runtime/pdbthink/transport.py
|
| 121 |
-
b5267c0f1cc015a68154affade8d89f6b6a01e9e4cc47a2dbdb74020e108ab5f components/pdbthink/runtime/pdbthink/wire_client.py
|
| 122 |
-
58d031f7955f7f774733189b8297a1db7f515bb206c26ac50fad68f580848974 components/tmax/DEPENDENCIES.json
|
| 123 |
-
7c4a25fee86ff7295519547dac7f594103c7137ec746423dd452c076a920cbb4 components/tmax/Dockerfile
|
| 124 |
-
9ae187d852f4cd6974fc9c65fba942df4e5586d73ddb3c48916a09376a3d36ac components/tmax/LICENSE_SCOPE.json
|
| 125 |
-
f30eb64313c2645348ca3d965c40c9a466eb3754f3302206e44133d19bc87d6a components/tmax/NOTICE.txt
|
| 126 |
-
e0e598c0fc7ac71b15ee4668ad88f11b9e1084d62610d0535038d5a034d1c946 components/tmax/SOURCE.json
|
| 127 |
-
7b4d7c93c6f7477c2962ee8ae8746bfe941991de3b940400013a15d1bba87536 components/tmax/TASKS.json
|
| 128 |
-
e2aff0a5d12d5f45d675854f26b6b5164bfac7fe1cf4193dab4ce879021bae64 components/tmax/config.json
|
| 129 |
-
11a6d83734845ad09d809667aa219857a5b985b28c258a2eebf5677668a6bd3b components/tmax/licenses/ODC-BY-1.0.txt
|
| 130 |
-
0e66e8816b8f2b4a17d37ec7abc5b8ca5708bae9d71d2c5323d8666d7e7ffa1d components/tmax/licenses/TMAX_DATASET_README.md
|
| 131 |
-
836618cb7e01e236878d367272157e4be6a31d538bf8b9f8cc9ed630aac04482 components/tmax/requirements.lock
|
| 132 |
-
01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b components/tmax/runtime/common/__init__.py
|
| 133 |
-
b1e1429208e84aefc2422ee1d2400ad793c43cd5c0e8db213a3b669fe0947ce1 components/tmax/runtime/common/contracts.py
|
| 134 |
-
7263c04e9175faf66501ed9b2ac2f9a637557a8b1966d839fb9944eb01abac0e components/tmax/runtime/common/http_routes.py
|
| 135 |
-
26e7a67537ce7ae34909b724243c37242b9c8055cbfe0c717179dac74347786a components/tmax/runtime/common/models.py
|
| 136 |
-
01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b components/tmax/runtime/native_shell/__init__.py
|
| 137 |
-
80eb3b90287840668e72040dc55ba115bfc3f4251a25cb2b94af0ed3759dd6b3 components/tmax/runtime/native_shell/actor_launcher.py
|
| 138 |
-
4b71d8cd0f017716e6df6cc64ee268a725be5fb6e363034bae2f9c8b0184b0ba components/tmax/runtime/native_shell/backend.py
|
| 139 |
-
cfe9ed6c11b9da324f5e752ffbf1d8ca5c074120f6067dd01d99590e568adf53 components/tmax/runtime/native_shell/environment.py
|
| 140 |
-
31adf40fa408c39a70fd78882f10b472b8bae1a55efae89192f956001e6a423e components/tmax/runtime/native_shell/guard.py
|
| 141 |
-
db4dc3e27abe2dc45cc29b534882975aa9ea8e5b8ebedb67c943fad83810805b components/tmax/runtime/native_shell/launch_service.py
|
| 142 |
-
1401916b276c6a19805b8bf405d11ffb014794c59a1eda55a91fa2edf06a0e7e components/tmax/runtime/native_shell/process_scope.py
|
| 143 |
-
c8bb079f359fe4ac6c1764cbf47fdcfaa3f3caee35ff6c41e845bee3e965d454 components/tmax/runtime/native_shell/server.py
|
| 144 |
-
6934b8fa5117549cb5ba30a1e6ebbd00df2bf4191ba10765473d05a3fd346465 components/tmax/runtime/native_shell/verifier_launcher.py
|
| 145 |
-
b8b67cfcd0115be0bcd984543e962adebe2528dc2cd18324e032d155563220af components/tmax/runtime/native_shell/wire_client.py
|
| 146 |
-
eab8396a1b533f70468039f8ac1b5fe9927faf4ded578172ec932ef7bf2af22a components/tmax/tasks/task_000056_f726766b/source/external/app/vibration_data.wav
|
| 147 |
-
714f780883970365cfffe408e2c76e75f499005f87551fc84b55d79368e77197 components/tmax/tasks/task_000056_f726766b/source/instruction.md
|
| 148 |
-
e36405ea22dc2679124b64c5e8d7f3c52fb3cfa9f529d4694e26532db5b341d0 components/tmax/tasks/task_000056_f726766b/source/task.toml
|
| 149 |
-
3ae0ce20b61928cc7f524ea6fb43ed55d3df32a9a87834825518d2397e31672e components/tmax/tasks/task_000056_f726766b/source/tests/test.sh
|
| 150 |
-
327c5346a779a44e27ef0cbd9f107e863d599fc6e47f95f248eaec03c15117c4 components/tmax/tasks/task_000056_f726766b/source/tests/test_final_state.py
|
| 151 |
-
a6c4cf2043d8642babb9b546096b3f559a375b59d54a43efebd57e9728466184 components/tmax/tasks/task_000260_7b7cc286/pristine/pipeline/find_threshold.sh
|
| 152 |
-
4631f1f805e6b826a796502ed5d94e676b3061cf448f2f9225116395aa3bb13b components/tmax/tasks/task_000260_7b7cc286/pristine/pipeline/process.sh
|
| 153 |
-
f3ae2df41978712dbffe58665a9582e3d0951f211c5cca5ece9f536225d28ba8 components/tmax/tasks/task_000260_7b7cc286/pristine/pipeline/serialize.sh
|
| 154 |
-
3c04251fe92c30d29ac4d887608f4385176e3bda932594437f82b08a5b348938 components/tmax/tasks/task_000260_7b7cc286/source/external/app/video.mp4
|
| 155 |
-
79c9fd4e4d41524db109d90b0415a4f0a2b9d24bf690fa8d7340ce3cb5ce0975 components/tmax/tasks/task_000260_7b7cc286/source/instruction.md
|
| 156 |
-
d36c49060b4ddbca3b13a5aa98cf5b195c07bff725b91107f58a087ec4325423 components/tmax/tasks/task_000260_7b7cc286/source/task.toml
|
| 157 |
-
3ae0ce20b61928cc7f524ea6fb43ed55d3df32a9a87834825518d2397e31672e components/tmax/tasks/task_000260_7b7cc286/source/tests/test.sh
|
| 158 |
-
aae204101d5c024a0b5cbda42fa686e7d2928fd9be3ad55fd14314b2502182a5 components/tmax/tasks/task_000260_7b7cc286/source/tests/test_final_state.py
|
| 159 |
-
170911a153d00eb0f037ca56a2cbd10d4aa2b7a418e25a0f1df58b1c77589788 components/tmax/tasks/task_000663_dff2c340/pristine/backup_catalog.db
|
| 160 |
-
feae25374139b4b1d8ec9759d553c591841d9330a071217f46a2e464bd32bbd7 components/tmax/tasks/task_000663_dff2c340/source/instruction.md
|
| 161 |
-
85d17b0b5f2f018805d139044cedadeda55cc93406e9d7b548b28fc6aa8ae30a components/tmax/tasks/task_000663_dff2c340/source/task.toml
|
| 162 |
-
3ae0ce20b61928cc7f524ea6fb43ed55d3df32a9a87834825518d2397e31672e components/tmax/tasks/task_000663_dff2c340/source/tests/test.sh
|
| 163 |
-
7a273b9bf8bc61eeec1b8dda674b5f6ba5356abbfd923b413b09d2584c1ef72f components/tmax/tasks/task_000663_dff2c340/source/tests/test_final_state.py
|
| 164 |
-
9fe1c89ee823f133d35dea66840ecb7f87d599487524b7aa1d6371e8f664058e components/tmax/tasks/task_005684_3c8594a3/pristine/compliance_audit.db
|
| 165 |
-
f4eee4e0643fcfb7399df10e1947ec9dbda28c74bacf307167f443506268f583 components/tmax/tasks/task_005684_3c8594a3/source/instruction.md
|
| 166 |
-
5fc0da5f24b16f866fbc354cfc7cb148a17d353dff3b263c1c6caf94bf30b6a2 components/tmax/tasks/task_005684_3c8594a3/source/task.toml
|
| 167 |
-
3ae0ce20b61928cc7f524ea6fb43ed55d3df32a9a87834825518d2397e31672e components/tmax/tasks/task_005684_3c8594a3/source/tests/test.sh
|
| 168 |
-
495630c7ede4e75ef5644c1ee5b69f04969a4059ef094787c19a3014734d3cf2 components/tmax/tasks/task_005684_3c8594a3/source/tests/test_final_state.py
|
| 169 |
-
d6b5039ee32f3a43069245984c8fe5a9689028a9aac06e26a64017c54bd11976 components/tmax/tasks/task_008667_2151f271/pristine/data/financial.db
|
| 170 |
-
629b28471809f802c58831d100315b83012c0066df3b265a2d379a19e61a2262 components/tmax/tasks/task_008667_2151f271/pristine/data/transactions.jsonl
|
| 171 |
-
50d1d10121dfa3b565842fd10f2589ceb91b4459126787af7793cec9cc0d06b1 components/tmax/tasks/task_008667_2151f271/source/instruction.md
|
| 172 |
-
d45954c25df30184144533cbf3ad4160377f627db5b926c3bbc9186327067897 components/tmax/tasks/task_008667_2151f271/source/task.toml
|
| 173 |
-
3ae0ce20b61928cc7f524ea6fb43ed55d3df32a9a87834825518d2397e31672e components/tmax/tasks/task_008667_2151f271/source/tests/test.sh
|
| 174 |
-
cb73fd0ab1765768ebfecc50054ba13c143cc51be201127515eb495904ddf9e6 components/tmax/tasks/task_008667_2151f271/source/tests/test_final_state.py
|
| 175 |
-
909d2e964c0831d8af91b722b4424ed829c261d6b7db1a95180d8a809527ddaf components/tmax/tasks/task_008998_ae4cbe72/pristine/robot_dump.log.gz
|
| 176 |
-
f81f86b07681931baabdba313cc4e988c01bff7a1f1d83349dfa939cdaa20669 components/tmax/tasks/task_008998_ae4cbe72/source/instruction.md
|
| 177 |
-
c8ff58ad07c30c2da028625be23e41319f95e22524944c9d37de2ec255428cd9 components/tmax/tasks/task_008998_ae4cbe72/source/task.toml
|
| 178 |
-
3ae0ce20b61928cc7f524ea6fb43ed55d3df32a9a87834825518d2397e31672e components/tmax/tasks/task_008998_ae4cbe72/source/tests/test.sh
|
| 179 |
-
e03b84ca0519367e5f86b7b3a3231afa5209b1971431497699200099035f5014 components/tmax/tasks/task_008998_ae4cbe72/source/tests/test_final_state.py
|
| 180 |
-
c44d259c4421b16dc5f0bc3912cdd800f6c25746ea31bede5060c9605b225025 components/tmax/upstream/task_000056_f726766b/environment/Dockerfile
|
| 181 |
-
fc9e91cc78e1817d80b4ba8c2dc9a638d0c57959825ee34f5e3d7688ad80dfb9 components/tmax/upstream/task_000056_f726766b/environment/_fixtures/app/fixtures/audio.label.txt
|
| 182 |
-
f55a8eec263c9be975b2adccdda6a07c680109b851a89f55779f14076aaa30d5 components/tmax/upstream/task_000056_f726766b/environment/_fixtures/app/fixtures/audio.wav
|
| 183 |
-
0e71b3e06fcf8cc6f9d95ba2e9664dfbba7786949a0e21b810ada563ae27a637 components/tmax/upstream/task_000056_f726766b/environment/base_install.sh
|
| 184 |
-
70d52288d5c9a7d23bbd63fb086a7f886961a1335632cc6efb892572d197563b components/tmax/upstream/task_000056_f726766b/environment/post_install.sh
|
| 185 |
-
e36405ea22dc2679124b64c5e8d7f3c52fb3cfa9f529d4694e26532db5b341d0 components/tmax/upstream/task_000056_f726766b/task.toml
|
| 186 |
-
98f66d958e8ee701c0579095c2e65254a63194845b894a45db2a6180a46a3193 components/tmax/upstream/task_000260_7b7cc286/environment/Dockerfile
|
| 187 |
-
4a44dc15364204a80fe80e9039455cc1608281820fe2b24f1e5233ade6af1dd5 components/tmax/upstream/task_000260_7b7cc286/environment/_fixtures/app/fixtures/video.label.txt
|
| 188 |
-
bf759113108b136ec3b5fa507d035c1e66ac243b52da09fa07ab58566ee27f58 components/tmax/upstream/task_000260_7b7cc286/environment/_fixtures/app/fixtures/video.mp4
|
| 189 |
-
0e71b3e06fcf8cc6f9d95ba2e9664dfbba7786949a0e21b810ada563ae27a637 components/tmax/upstream/task_000260_7b7cc286/environment/base_install.sh
|
| 190 |
-
ba40e8bc5a20718d686892069c073ee96760685a32fe3291f2f6fbb630a7ae03 components/tmax/upstream/task_000260_7b7cc286/environment/post_install.sh
|
| 191 |
-
483c9171d3e67bec029d9b88cee24d554fa9310a61ec47940312be5f2951bc30 components/tmax/upstream/task_000260_7b7cc286/task.toml
|
| 192 |
-
ac07540077f0810363eb57110b6cefeae93df6271c1cc6121d2d62cdc13a9535 components/tmax/upstream/task_000663_dff2c340/environment/Dockerfile
|
| 193 |
-
a449c18295cee8a3e7ed0c958fe219cbed2d2a8e7fdad924f2679444b3377b94 components/tmax/upstream/task_000663_dff2c340/environment/post_install.sh
|
| 194 |
-
85d17b0b5f2f018805d139044cedadeda55cc93406e9d7b548b28fc6aa8ae30a components/tmax/upstream/task_000663_dff2c340/task.toml
|
| 195 |
-
ac07540077f0810363eb57110b6cefeae93df6271c1cc6121d2d62cdc13a9535 components/tmax/upstream/task_005684_3c8594a3/environment/Dockerfile
|
| 196 |
-
b431517fec535c62b42b517f9212cbb1e9cf80bdf883a55c02bfba08f0d4c404 components/tmax/upstream/task_005684_3c8594a3/environment/post_install.sh
|
| 197 |
-
5fc0da5f24b16f866fbc354cfc7cb148a17d353dff3b263c1c6caf94bf30b6a2 components/tmax/upstream/task_005684_3c8594a3/task.toml
|
| 198 |
-
ac07540077f0810363eb57110b6cefeae93df6271c1cc6121d2d62cdc13a9535 components/tmax/upstream/task_008667_2151f271/environment/Dockerfile
|
| 199 |
-
3a777366c4b998e6368627f4775a73cea29fdbdc9991daedfb13244153c17841 components/tmax/upstream/task_008667_2151f271/environment/post_install.sh
|
| 200 |
-
d45954c25df30184144533cbf3ad4160377f627db5b926c3bbc9186327067897 components/tmax/upstream/task_008667_2151f271/task.toml
|
| 201 |
-
ac07540077f0810363eb57110b6cefeae93df6271c1cc6121d2d62cdc13a9535 components/tmax/upstream/task_008998_ae4cbe72/environment/Dockerfile
|
| 202 |
-
26dfa63d063430c2370144b8e30c1f905dde4e2722403c1e8131a5a84e2d5e69 components/tmax/upstream/task_008998_ae4cbe72/environment/post_install.sh
|
| 203 |
-
c8ff58ad07c30c2da028625be23e41319f95e22524944c9d37de2ec255428cd9 components/tmax/upstream/task_008998_ae4cbe72/task.toml
|
| 204 |
-
abea24b268b08f72897859e527fe90c89c08d2afab7305cf52d4255f2feeb897 prepare_source_tree.py
|
| 205 |
10993deaaa8553929fa0b3b6bf3c1ad100baaaf9ff10ae8ed139a8ec4279a3c4 schema.json
|
| 206 |
-
|
| 207 |
-
|
| 208 |
-
21dc586748f23a8630118831399e1c40d62443444d454bf6f5e7f60ba334b06f upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/instruction.md
|
| 209 |
-
97d07b9814fff65f7cd78bf968d4854aa2aa75e8535ceb574b35a93dbf087db0 upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/prompt.json
|
| 210 |
-
45af241c0dc3ed0b71fff4db4b2f334760bc387aaff0a74a6dc9543cce2effe1 upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/task.toml
|
| 211 |
-
8f8067d6fbd793412dd078f35617d367999a644cf040ef4996dfd96c2b2e936f upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/tests/coordinate_scoring/__init__.py
|
| 212 |
-
72035a296ec599f0e4743141a76f8dc908be5ac6a7fd500d36fcbb29b8b3687c upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/tests/coordinate_scoring/parse.py
|
| 213 |
-
8046af2d8ca0e74d40ca60624ea3c678b81fa3b76b634818fd96757282f12c34 upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/tests/coordinate_scoring/scorers.py
|
| 214 |
-
4ed8e4260bc71b5a863888cd3fa2c7bca6210fc5138f96fd2207462c348318b7 upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/tests/gold.json
|
| 215 |
-
bf3f533beddf0e9db369e092e297d2905013f2aedad52919cb1db76ed7a566f7 upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/tests/test.sh
|
| 216 |
-
628bca2d87aa70d0176cb3a79879c64bbfb07fc53dd094fd3060173b24a76ef4 upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/tests/verifier.toml
|
| 217 |
-
91441587561c00649cec98159d22f64d11b01fff459601cce79579737f0fa37c upstream/pdbthink/pdbthink-s09-7ba4aa076b6bb5633953/tests/verify.py
|
| 218 |
-
0a92b0131b3b069468a5c0e32016a4f76b3f11395531a223b9a131175c2ae274 validate_dataset.py
|
|
|
|
| 1 |
+
e50227e76c5f0c86594f7fd55d13414bc1615800f93e01f4d4a3d3dd869533d5 LICENSES/README.txt
|
| 2 |
+
9b0b7c94692144732a7e73d09b8875feb4734276e42b46656615e07ac99c8142 README.md
|
| 3 |
+
8a55fa76364ae1cd88b1a1da39137400a318c40df4f1ff2941616c51cf5c4f17 SOURCE_LOCK.json
|
| 4 |
+
7c94b391b9d5738860b9270f471e27a99e17255f473b96f7bd1bf46a1d0c82da components/audit/Dockerfile
|
| 5 |
+
5d85c4ca9560bf6be77c0389e21719d726ff9442c7bc73e37a40d79c021eec47 components/audit/NOTICE
|
| 6 |
+
eea2ab8b6a11c6f41afce2488eeaa6d87a6c30f752cb60e76104c83ee02ab074 components/audit/README.md
|
| 7 |
+
0b0eafe25ffa560829dafcdd3ade2625043d5eaa03d725d153f40e6cacc15397 components/audit/SOURCE.json
|
| 8 |
+
6da4b8c7351046b8bfdb7e1ffe47dd6f40401c008497f2e8245673f356ab142d components/audit/config.json
|
| 9 |
+
e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855 components/audit/runtime/audit/__init__.py
|
| 10 |
+
3ff3233f5b306f1ce9f1db748820711148d5e0cbd663e8691f4163d6b9548d03 components/audit/runtime/audit/environment.py
|
| 11 |
+
dc79acae9a5d8abc4c816377745390421d50f317b5b307a76e64634b886ab8b6 components/audit/runtime/audit/server.py
|
| 12 |
+
01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b components/audit/runtime/common/__init__.py
|
| 13 |
+
b1e1429208e84aefc2422ee1d2400ad793c43cd5c0e8db213a3b669fe0947ce1 components/audit/runtime/common/contracts.py
|
| 14 |
+
6a1ac8e55af6168d3fdd6b17c700a15cf0546b6154773aa3c59c97d6bffa2ffd components/audit/runtime/common/models.py
|
| 15 |
+
e58b70774d5f729ae49c59cb82c019972e889b7353dabe1d6b9eefc085993119 components/audit/tasks/auth-05/instruction.md
|
| 16 |
+
141f54a8f1dc40c48f5a691cb2cdc9b15e8f3c029c7c3d500b8f8a054e82152b components/audit/tasks/ledger-01/instruction.md
|
| 17 |
+
cfc7749b96f63bd31c3c42b5c471bf756814053e847c10f3eb003417bc523d30 components/audit/upstream/LICENSE
|
| 18 |
+
638536fc5897e3dd2aea2ce4671bf321e45d6de0ece20bc857ea38126f058dc8 components/audit/upstream/audit_trail/__init__.py
|
| 19 |
+
5156b42a8bebe5bf119a654f8e081eea0c7614f32933b2fd262c078b66e54276 components/audit/upstream/audit_trail/models.py
|
| 20 |
+
c27b096b1833ae60a6dff6108164d107cd5ecd50524a38ba22dd695733011aeb components/audit/upstream/audit_trail/server/__init__.py
|
| 21 |
+
5428cf74f5d6a6ea75e67ad2eb061d96ed391bff146c01ece422b984273d1125 components/audit/upstream/audit_trail/server/audit_trail_environment.py
|
| 22 |
+
c2f1193259d9c0dfecc2645bcc7ba36b01d336cad2aa5cc3c7ed358f9aa27b2a components/audit/upstream/audit_trail/tasks.py
|
| 23 |
+
d70f12d0207ac89da7804330af5a207e1784e6603b565b73e40d786de75364b0 components/audit/upstream/dataset/README.md
|
| 24 |
+
dcb67aca547276783eb5f0da148ebcbd55d69d13cbb6dd437e0108ae971be1e8 components/audit/upstream/dataset/tasks.jsonl
|
| 25 |
+
c04a2771c0665225047882b2da49d452e20d7cc9bc0ea024a48f1cd31411c504 components/dnakhla/.dockerignore
|
| 26 |
+
a2464ca6190e49c967ccb0b521c8190dba35d94b9b2208e31562161f20f535b8 components/dnakhla/Dockerfile
|
| 27 |
+
cfc7749b96f63bd31c3c42b5c471bf756814053e847c10f3eb003417bc523d30 components/dnakhla/LICENSE
|
| 28 |
+
c306489df6e0c1049ff449d672d81e2aa5a78c66665c97b1b4448584be62f8f3 components/dnakhla/NOTICE
|
| 29 |
+
f06b54055f7f780cd3bdf94dc3a5fb7d5e8e48f083a29727261fcf51e8f5d209 components/dnakhla/README.md
|
| 30 |
+
6c0c97d7de7fa1381099f380cd5554d584ed7581e50b0dc2d43d15cd6ae5c1de components/dnakhla/SOURCE_MANIFEST.json
|
| 31 |
+
01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b components/dnakhla/runtime/common/__init__.py
|
| 32 |
+
b1e1429208e84aefc2422ee1d2400ad793c43cd5c0e8db213a3b669fe0947ce1 components/dnakhla/runtime/common/contracts.py
|
| 33 |
+
6a1ac8e55af6168d3fdd6b17c700a15cf0546b6154773aa3c59c97d6bffa2ffd components/dnakhla/runtime/common/models.py
|
| 34 |
+
adb5e5e6b8d1c5f4d2ff5bbfd4b66038c3d52e4ae50b0d3430c56a196d5ae5c3 components/dnakhla/runtime/dnakhla_compat/__init__.py
|
| 35 |
+
eaa4d0c0f293f3d53630eda1ad71921a8c1308b1ae375be3041bd3d0afc41369 components/dnakhla/runtime/dnakhla_compat/environment.py
|
| 36 |
+
d64b7539b8cc9f5dcc170dcd0c4c48e6673da923ce0f22b754c7859770032bd8 components/dnakhla/runtime/dnakhla_compat/server.py
|
| 37 |
+
8c68fdfde651ec70155ec1a8d4b15f5c14cdd1f9d98197fc5037b49d6dc74524 components/dnakhla/upstream/openenv.yaml
|
| 38 |
+
e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855 components/dnakhla/upstream/terminal_desk/__init__.py
|
| 39 |
+
e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855 components/dnakhla/upstream/terminal_desk/core/__init__.py
|
| 40 |
+
8606129c5aa3f99cc540a7c8269b65e9bb6c42e81bca36085c16963a0cccd2bd components/dnakhla/upstream/terminal_desk/core/grading.py
|
| 41 |
+
59b4b07b0d59e01792c8dbbf7877555e2da2346ddf5d2c17df3bbd4e17cb847f components/dnakhla/upstream/terminal_desk/core/shell.py
|
| 42 |
+
2ca3d4eda1fb04a84a236fbb43b71d13d46ea68109f545e036842211be3e3958 components/dnakhla/upstream/terminal_desk/families/__init__.py
|
| 43 |
+
d76cab459096d3748d2c4198753853d85418de61f64436cf4772b89345fdcf17 components/dnakhla/upstream/terminal_desk/families/base.py
|
| 44 |
+
312a26e2d48ac10a07716384d3059a697f75f16e5b37fcabb8c07fcac3397f6f components/dnakhla/upstream/terminal_desk/families/finance.py
|
| 45 |
+
a4839540c7a54198ea8e480248428e9ca65bdaf45adea5ae9f81cad71cbb1311 components/dnakhla/upstream/terminal_desk/families/finance3.py
|
| 46 |
+
9140985ca44b1bcfc78b853f44496b7a9b77288284675f3656898de5be70d6aa components/dnakhla/upstream/terminal_desk/families/industrial.py
|
| 47 |
+
48e914996b67accb09350a6714a5cea4a6191c0a05ac12a8f3045309f961c49c components/dnakhla/upstream/terminal_desk/families/industrial3.py
|
| 48 |
+
552855819cbe4983529b864279c915bc56f8d68d850a3f221d84864066c0e2a5 components/dnakhla/upstream/terminal_desk/families/mathematics.py
|
| 49 |
+
9dc54710cd826aadbe5de55d9093959e38c59dc59ae080e40d379cc4db1987c1 components/dnakhla/upstream/terminal_desk/families/mathematics3.py
|
| 50 |
+
52523502e6c679e34bd2dbeb46c3f539ba53ae2d4e1033adafca7ce859bc4de8 components/dnakhla/upstream/terminal_desk/families/media.py
|
| 51 |
+
9c91cfbde8ad60da034c15ba3418e21ae5891a12ce3932ecaf8035fcd6eef4bd components/dnakhla/upstream/terminal_desk/families/media3.py
|
| 52 |
+
11f76ce7d62e18b535278b487f798703fd6f2bef04dd7ffaefae2c95bcba1102 components/dnakhla/upstream/terminal_desk/families/office.py
|
| 53 |
+
1926c4a6e600cabb4cd35fab9528b4e4d55ef4adc1623b7229ac356ef28c987b components/dnakhla/upstream/terminal_desk/families/office3.py
|
| 54 |
+
836ab819a2231700a4bff2929a4579034c45a637992e883ddfbdb0c1f711446a components/dnakhla/upstream/terminal_desk/families/science.py
|
| 55 |
+
59477a1f9d38dbe5607f6432b4f8538342eec93faeed09bb6c9cb1402980c9a1 components/dnakhla/upstream/terminal_desk/families/science3.py
|
| 56 |
+
1228db896b6ce796ccf1f133e2f2ba9aaa9d54b745d5ffaf4b584a63a6aab2bd components/dnakhla/upstream/terminal_desk/families/security.py
|
| 57 |
+
6f5ec9c2dfe9aad81ba382d4f6ffdb7f64493d92cd7fe5d653134ef0dac107af components/dnakhla/upstream/terminal_desk/families/security3.py
|
| 58 |
+
4bca03797d701fe33f567729baa9a4fb2cef59cf220d0b79a941cc3817f8ba3a components/dnakhla/upstream/terminal_desk/families/software.py
|
| 59 |
+
d526ae88ca53ef22dbc1e578055fc27ebb491c184474e662736b8be9523086a7 components/dnakhla/upstream/terminal_desk/families/software3.py
|
| 60 |
+
f31264b0909878c6f2d4d18a270c7d92bc895052150c56e5ac3e6b38d4ceebb4 components/dnakhla/upstream/terminal_desk/models.py
|
| 61 |
+
04e4b102444b5db19507a46814820d78ad1e9782f963e5764f8f4adfe4d366a3 components/dnakhla/upstream/terminal_desk/oracles/__init__.py
|
| 62 |
+
975ff8045d42b2f483924e368e304c451bca894ddb4ba593d9dd3aea1c505329 components/dnakhla/upstream/terminal_desk/oracles/fin3_invoice_fraud.py
|
| 63 |
+
b0a32266ec725f5a4f76d8b40a27fc52759f679d74e4dfe5c7885a1b19a36711 components/dnakhla/upstream/terminal_desk/oracles/fin3_loan_schedule.py
|
| 64 |
+
152a3516b9ec6811121747ea875fc1a73cb768ba6a98e05c2bee91325e4f7247 components/dnakhla/upstream/terminal_desk/oracles/fin3_portfolio_value.py
|
| 65 |
+
47914a6e1a5bde126ce301bc11d4dc95b11cb0910ac0208a4c78596d7e65e30e components/dnakhla/upstream/terminal_desk/oracles/ind3_service_due.py
|
| 66 |
+
53e6adc26768256ce6665bda20c4b04ad87602e24eb31b074c25dc8fbbc00653 components/dnakhla/upstream/terminal_desk/oracles/ind3_stl_mass.py
|
| 67 |
+
c1049fdb6b4f11f0b5e0194b41e84b525d5a340213c2c94f5f99ffd6c2b75a42 components/dnakhla/upstream/terminal_desk/oracles/ind3_tank_balance.py
|
| 68 |
+
0fd62812cd9ef1d5be6d6ae9fa2fa047eb6bb0a4508ccb5a5369373aefbf8dd3 components/dnakhla/upstream/terminal_desk/oracles/math3_count_items.py
|
| 69 |
+
03908ec43159f4a66678f37fb0366389608eeeba41361758d966c96eea50dc3f components/dnakhla/upstream/terminal_desk/oracles/math3_exam_slots.py
|
| 70 |
+
c2bb32b08a3705a4be56ff8c4e3af94d64441c9a7432f5dcec4dce0b378ee465 components/dnakhla/upstream/terminal_desk/oracles/math3_route_plan.py
|
| 71 |
+
554e36455da66fd258e6ad2c39e80acbc3856237fee4608ce57b494f23c3d16d components/dnakhla/upstream/terminal_desk/oracles/med3_silence_report.py
|
| 72 |
+
8f0a1169d6e5b10c4981b53a22e957c4befad44d95e5d250cf53734105a40256 components/dnakhla/upstream/terminal_desk/oracles/med3_sprite_count.py
|
| 73 |
+
72f448ba58ac9ee6082692dec88ddb6f279ae69bdb99d39b30d1acce12c19bfe components/dnakhla/upstream/terminal_desk/oracles/med3_subtitle_retime.py
|
| 74 |
+
b5320a71696443f1b04c0c5e02e35d0baee67a175a912bff86e32df7c2acb357 components/dnakhla/upstream/terminal_desk/oracles/off3_ar_recon.py
|
| 75 |
+
6eef5e15337e5029c8e0b3353adee791ea9ebe73c6d79e47d84d6b7294cb5a38 components/dnakhla/upstream/terminal_desk/oracles/off3_meeting_slot.py
|
| 76 |
+
82b5c15f02a03615699429a2342dbad4b8985aab76d82fa8a8b96f7fbebc544f components/dnakhla/upstream/terminal_desk/oracles/off3_pdf_xlsx_diff.py
|
| 77 |
+
1ebc19667bf1963c83a47bd4905e99e0c32c3ce249b63ae2d7b39fcffa1b1bb7 components/dnakhla/upstream/terminal_desk/oracles/sci3_kinetics_fit.py
|
| 78 |
+
a983fb3c03ba15bc0591ab32ce41ddb99f2f38329e273f3f5da20f775d6bd8ab components/dnakhla/upstream/terminal_desk/oracles/sci3_lightcurve_period.py
|
| 79 |
+
56a84763e746f034571dc50a71f3716f340e4f8d9dee823eb3c9b209f471f48a components/dnakhla/upstream/terminal_desk/oracles/sci3_stoich_batch.py
|
| 80 |
+
c5fb5f697e8cfdb6008fcd59d6c3095a509d9a488dc28d7b99da4f4fe128b8a6 components/dnakhla/upstream/terminal_desk/oracles/sec3_auth_triage.py
|
| 81 |
+
5a4cc8a38f0554be4b287e2592bd26553db2f3ee6b5c10339d641246a7a6af90 components/dnakhla/upstream/terminal_desk/oracles/sec3_exfil_flows.py
|
| 82 |
+
b91c7389813445d55edbdaadec60aa4c5d0b6c5ead6fdfca5268e425f512820f components/dnakhla/upstream/terminal_desk/oracles/sec3_fw_verdicts.py
|
| 83 |
+
6b46601bc7e4bdc42c62242344aa431a34e7a6d1a8c7201e77315c66c6a4ae09 components/dnakhla/upstream/terminal_desk/oracles/sw3_dep_lock.py
|
| 84 |
+
43eee7f24a02ca3f0d3b12db5a44c132a931fc8dba10f9c1d4028d7fa5775bf4 components/dnakhla/upstream/terminal_desk/oracles/sw3_fix_module.py
|
| 85 |
+
4f1f187ae42f47faecc85d84e1f0341c848b03eb2bba1bf538927e2e62758314 components/dnakhla/upstream/terminal_desk/oracles/sw3_rate_limit.py
|
| 86 |
+
e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855 components/dnakhla/upstream/terminal_desk/server/__init__.py
|
| 87 |
+
6bf7658ec8ad07dda230a01fd893091a9b87df18ebf6af25af6c35965ed01fd8 components/dnakhla/upstream/terminal_desk/server/app.py
|
| 88 |
+
8e92f991e14098a0858490fe5beb43ca9b0ee2cfbddb36e73ecf987ba3922902 components/dnakhla/upstream/terminal_desk/server/environment.py
|
| 89 |
05cc6ae53cfd6129f1d7010aa874c6cf0a6019b1adfeff3f4fab27f2d04f43ca components/loui/.dockerignore
|
| 90 |
+
225304d22825c251c46ab771cabdb176edce0efe249789c528573e8bc42c904d components/loui/Dockerfile
|
| 91 |
+
0ab8e0b3aa9790d6aa7d273727bf5ccd2fc0c49d57a4075eeb6022b93c55693f components/loui/README.md
|
| 92 |
+
4da7db21c634d28a954e5f83145d7f6b2de7a5b1ab62ac193f815e6684ab1406 components/loui/SOURCE.json
|
| 93 |
+
bfad19ee80d40545950d8e47c7772d548d5b26f3e7873f1ff18d1ceeed04d5ee components/loui/config.json
|
| 94 |
01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b components/loui/runtime/common/__init__.py
|
| 95 |
b1e1429208e84aefc2422ee1d2400ad793c43cd5c0e8db213a3b669fe0947ce1 components/loui/runtime/common/contracts.py
|
| 96 |
+
6a1ac8e55af6168d3fdd6b17c700a15cf0546b6154773aa3c59c97d6bffa2ffd components/loui/runtime/common/models.py
|
| 97 |
e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855 components/loui/runtime/loui/__init__.py
|
| 98 |
c4774351bdbd8a044cd20bcd7111ac4db7403feccb9444acf663e71140b27888 components/loui/runtime/loui/child.py
|
| 99 |
edd467b474dc0982c9b6c91a9f0150432fa8b9a5c6b62c8187bc9cc9f440a22a components/loui/runtime/loui/environment.py
|
| 100 |
+
eb1bb1ea6b9747c0541e592d6f39b3c543bc8e5f760dbdda4ead54eaea44cd8e components/loui/runtime/loui/executor.py
|
| 101 |
c3ae4e00495724083e73085bd4dccdf3493094ef2e14c0bb017f6502d264244b components/loui/runtime/loui/server.py
|
| 102 |
09ef2d8fc856ca3dc5662c279df705e9accc827f4472dc34758ffe769d116128 components/loui/tasks/expression-3/instruction.md
|
|
|
|
| 103 |
a5958627f5ebeaf73b280a5b983d86d79c2144c988d761ea7769158788a90de6 components/loui/upstream/LICENSE
|
| 104 |
bf5da0c7b871459278ad174cfd3c4ba90de9fbe74d35decce007bed13535d32d components/loui/upstream/v3/README.md
|
| 105 |
578814be5152b9b00c7eeae387544a94db159c9e8e3456e5cb56b31b6a731e9a components/loui/upstream/v3/execution.py
|
|
|
|
| 107 |
67f546daef6e7902c12754cbbd883657e57d2cb21e109275af123c552cc93422 components/loui/upstream/v3/server.py
|
| 108 |
9715cdabe6e67287399a3fe2bad435852510bf854982d2f6695b3d87db395c88 components/loui/upstream/v3/tasks.jsonl
|
| 109 |
71caf0175532025bf138398229d466f18e5e03365b48853efd92f61f6dae2d66 components/loui/upstream/v3/tasks.py
|
| 110 |
+
54805fba51273053c3dd388970db3b31aae4de8e5998f1c05e735c18e242857f components/metaharness/.dockerignore
|
| 111 |
+
1bfc7ebdbe65d93c93fa3122a2efb3e3cf8f6c138113fb6be9d09e5bfe2061ba components/metaharness/Dockerfile
|
| 112 |
+
09ed6717912f408da29e15b55170cd56c9658218a540b7c72e70909b9101274c components/metaharness/LICENSE
|
| 113 |
+
605977e7d6dcc2b1eda0dfc6501d2b1d5c64c129ff84e793a9a983919530e1ed components/metaharness/NOTICE
|
| 114 |
+
99e6a092e24b941b4ac79a57eeb593beff579f199d3994f73aa7e538f98398d9 components/metaharness/README.md
|
| 115 |
+
6bea52680ab6b140300653d1c98c356dbd0bc9c8da4bab722b21071baa7ec4a9 components/metaharness/SOURCE.json
|
| 116 |
+
3f122a94c8aecb947b4f95bc2a8d67980ec9a9bc2b7adeea3b1c5e08c3504e06 components/metaharness/TASKS.json
|
| 117 |
+
01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b components/metaharness/runtime/common/__init__.py
|
| 118 |
+
b1e1429208e84aefc2422ee1d2400ad793c43cd5c0e8db213a3b669fe0947ce1 components/metaharness/runtime/common/contracts.py
|
| 119 |
+
6a1ac8e55af6168d3fdd6b17c700a15cf0546b6154773aa3c59c97d6bffa2ffd components/metaharness/runtime/common/models.py
|
| 120 |
+
485aa11684c1ca537e3f439ceb3e2bcdfb8848e1012ada02cb5783ae3deeb02d components/metaharness/runtime/shared_adapter.py
|
| 121 |
+
ceddb0dfe82b01ae91859db2215fa697381064801f0eb0a4d96dd6d0473bd25e components/metaharness/upstream/Dockerfile
|
| 122 |
+
8802e5b5d1796dc9d15647705598971ec4be2e7b53e6b30556440a5ebb89d069 components/metaharness/upstream/README.md
|
| 123 |
+
d0cca47bd35b44e121fb394856996d9f2271c29528b73d5b6160ab63f47f9a0f components/metaharness/upstream/arena_env/__init__.py
|
| 124 |
+
62815cb244cb4404379dc28e897503994bef49a8e4f4b5721dace574a8865c63 components/metaharness/upstream/arena_env/app.py
|
| 125 |
+
d6882e2c9dabf1ee0fde75df0acdef85670598da633ce523cf54038fd40562a9 components/metaharness/upstream/arena_env/environment.py
|
| 126 |
+
94e29b6d884302f57e9440591cca5c07350cc4eb47d9e4e9f7a27689c519b781 components/metaharness/upstream/arena_env/tasks.py
|
| 127 |
+
3fbed6fc6af3931cdacd290353a02ba1740222974c91a022145ec4e6a5f3a347 components/metaharness/upstream/requirements.lock
|
| 128 |
+
bb488a65100922227f9e7e8288beced72577c44cec8c2aa7a54be446d6ce9606 components/metaharness/upstream/tasks.selected.jsonl
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 129 |
10993deaaa8553929fa0b3b6bf3c1ad100baaaf9ff10ae8ed139a8ec4279a3c4 schema.json
|
| 130 |
+
8bd6a842e43e36b3200d5b536d66ba3c66635c9ce4fe1ca812b561e25fc84182 tasks.jsonl
|
| 131 |
+
59c642280ff82be024351b29b654a8f7b1eea9e101fc0579c79a3e258e2f2c29 validate_dataset.py
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
SOURCE_LOCK.json
CHANGED
|
The diff for this file is too large to render.
See raw diff
|
|
|
components/audit/Dockerfile
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
FROM ghcr.io/bochencs/openenv-pdbthink@sha256:cf4c1c22bc9656adb95815c560e8261c83c7658b036edde59b20eace0af3248a
|
| 2 |
+
USER root
|
| 3 |
+
COPY runtime /opt/audit/runtime
|
| 4 |
+
COPY upstream /opt/audit/upstream
|
| 5 |
+
COPY tasks /opt/audit/tasks
|
| 6 |
+
COPY SOURCE.json config.json NOTICE /opt/audit/
|
| 7 |
+
RUN chmod -R go-rwx /opt/audit
|
| 8 |
+
ENV PYTHONPATH=/opt/audit/runtime:/opt/audit/upstream PYTHONDONTWRITEBYTECODE=1 PYTHONUNBUFFERED=1 ENABLE_WEB_INTERFACE=false OPENENV_MODE=simulation GRADIO_ANALYTICS_ENABLED=false HF_HUB_OFFLINE=1
|
| 9 |
+
WORKDIR /opt/audit
|
| 10 |
+
EXPOSE 8000
|
| 11 |
+
HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["python", "-c", "import urllib.request; urllib.request.urlopen('http://127.0.0.1:8000/health', timeout=3).read()"]
|
| 12 |
+
CMD ["python", "-m", "audit.server"]
|
components/audit/NOTICE
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
Audit Trail by Noe Flandre, Apache-2.0.
|
| 2 |
+
Source: https://github.com/NoeFlandre/openenv-arena/tree/e6b007ff234bd48449fa5ea045c083f30550389d
|
| 3 |
+
Adaptations: shared OpenEnv schema, per-session module isolation and task registration.
|
components/audit/README.md
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
Two original Audit Trail tasks: auth-05 and ledger-01. The original fixed logs, ten-action limit and exact-answer grader are preserved. Shared actions map grep and answer to the original tools.
|
components/audit/SOURCE.json
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"source_dataset": "NoeFlandre/audit-trail",
|
| 3 |
+
"source_revision": "f821596324c2d3f29130ebc7054a22c6bd5559d4",
|
| 4 |
+
"source_url": "https://huggingface.co/datasets/NoeFlandre/audit-trail/tree/f821596324c2d3f29130ebc7054a22c6bd5559d4",
|
| 5 |
+
"source_github_revision": "e6b007ff234bd48449fa5ea045c083f30550389d",
|
| 6 |
+
"source_github_url": "https://github.com/NoeFlandre/openenv-arena/tree/e6b007ff234bd48449fa5ea045c083f30550389d",
|
| 7 |
+
"license": "Apache-2.0",
|
| 8 |
+
"registered_tasks": [
|
| 9 |
+
"auth-05",
|
| 10 |
+
"ledger-01"
|
| 11 |
+
],
|
| 12 |
+
"files": {
|
| 13 |
+
"upstream/LICENSE": "cfc7749b96f63bd31c3c42b5c471bf756814053e847c10f3eb003417bc523d30",
|
| 14 |
+
"upstream/audit_trail/__init__.py": "638536fc5897e3dd2aea2ce4671bf321e45d6de0ece20bc857ea38126f058dc8",
|
| 15 |
+
"upstream/audit_trail/models.py": "5156b42a8bebe5bf119a654f8e081eea0c7614f32933b2fd262c078b66e54276",
|
| 16 |
+
"upstream/audit_trail/tasks.py": "c2f1193259d9c0dfecc2645bcc7ba36b01d336cad2aa5cc3c7ed358f9aa27b2a",
|
| 17 |
+
"upstream/audit_trail/server/__init__.py": "c27b096b1833ae60a6dff6108164d107cd5ecd50524a38ba22dd695733011aeb",
|
| 18 |
+
"upstream/audit_trail/server/audit_trail_environment.py": "5428cf74f5d6a6ea75e67ad2eb061d96ed391bff146c01ece422b984273d1125",
|
| 19 |
+
"upstream/dataset/README.md": "d70f12d0207ac89da7804330af5a207e1784e6603b565b73e40d786de75364b0",
|
| 20 |
+
"upstream/dataset/tasks.jsonl": "dcb67aca547276783eb5f0da148ebcbd55d69d13cbb6dd437e0108ae971be1e8"
|
| 21 |
+
}
|
| 22 |
+
}
|
components/audit/config.json
ADDED
|
@@ -0,0 +1,44 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"tasks": [
|
| 3 |
+
{
|
| 4 |
+
"task_id": "auth-05",
|
| 5 |
+
"split": "train",
|
| 6 |
+
"seed": 2005,
|
| 7 |
+
"accepted_seed": 2005,
|
| 8 |
+
"family": "auth",
|
| 9 |
+
"level": 5,
|
| 10 |
+
"source_dataset": "NoeFlandre/audit-trail",
|
| 11 |
+
"source_revision": "f821596324c2d3f29130ebc7054a22c6bd5559d4",
|
| 12 |
+
"source_url": "https://huggingface.co/datasets/NoeFlandre/audit-trail/tree/f821596324c2d3f29130ebc7054a22c6bd5559d4",
|
| 13 |
+
"source_github_revision": "e6b007ff234bd48449fa5ea045c083f30550389d",
|
| 14 |
+
"license": "Apache-2.0",
|
| 15 |
+
"original_instruction": "tasks/auth-05/instruction.md",
|
| 16 |
+
"instruction_sha256": "e58b70774d5f729ae49c59cb82c019972e889b7353dabe1d6b9eefc085993119",
|
| 17 |
+
"question_sha256": "c53c4bfeb41ddba2094a9d513304f1f20f200d8235843f75484ddb960f58abd5",
|
| 18 |
+
"log_sha256": "d2c23a77aea2e5049297bb14ed21fb7bc6a18712d1cf100836cca5e0b776d587",
|
| 19 |
+
"grading": "Original exact answer, case-insensitive; correct 1, otherwise 0",
|
| 20 |
+
"rendered_question_sha256": "260bc6fa5e59ccc1c5a1f590775ebe1e246b9da8e63662c637d25ebe643634b2",
|
| 21 |
+
"rendered_protocol": "Original PROTOCOL suffix replaced with shared call/finish schema; preceding question is unchanged"
|
| 22 |
+
},
|
| 23 |
+
{
|
| 24 |
+
"task_id": "ledger-01",
|
| 25 |
+
"split": "train",
|
| 26 |
+
"seed": 2011,
|
| 27 |
+
"accepted_seed": 2011,
|
| 28 |
+
"family": "ledger",
|
| 29 |
+
"level": 1,
|
| 30 |
+
"source_dataset": "NoeFlandre/audit-trail",
|
| 31 |
+
"source_revision": "f821596324c2d3f29130ebc7054a22c6bd5559d4",
|
| 32 |
+
"source_url": "https://huggingface.co/datasets/NoeFlandre/audit-trail/tree/f821596324c2d3f29130ebc7054a22c6bd5559d4",
|
| 33 |
+
"source_github_revision": "e6b007ff234bd48449fa5ea045c083f30550389d",
|
| 34 |
+
"license": "Apache-2.0",
|
| 35 |
+
"original_instruction": "tasks/ledger-01/instruction.md",
|
| 36 |
+
"instruction_sha256": "141f54a8f1dc40c48f5a691cb2cdc9b15e8f3c029c7c3d500b8f8a054e82152b",
|
| 37 |
+
"question_sha256": "c131345800dedf98dd94e8deafa961a802a37a8d5226ae0820c75c1c5388a74e",
|
| 38 |
+
"log_sha256": "1560ae70923c515859a8eebb7daf21487e643c0771d93d708eeb86d402819f89",
|
| 39 |
+
"grading": "Original exact answer, case-insensitive; correct 1, otherwise 0",
|
| 40 |
+
"rendered_question_sha256": "afcc6d9e5baca3e5756678d0f5603761515e64c3c54876608d810ab08e0507b1",
|
| 41 |
+
"rendered_protocol": "Original PROTOCOL suffix replaced with shared call/finish schema; preceding question is unchanged"
|
| 42 |
+
}
|
| 43 |
+
]
|
| 44 |
+
}
|
components/audit/runtime/audit/__init__.py
ADDED
|
File without changes
|
components/audit/runtime/audit/environment.py
ADDED
|
@@ -0,0 +1,128 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import hashlib
|
| 2 |
+
import importlib.util
|
| 3 |
+
import json
|
| 4 |
+
import sys
|
| 5 |
+
from pathlib import Path
|
| 6 |
+
from threading import RLock
|
| 7 |
+
from uuid import uuid4
|
| 8 |
+
|
| 9 |
+
from openenv.core.env_server.interfaces import Environment
|
| 10 |
+
from openenv.core.env_server.types import EnvironmentMetadata, State
|
| 11 |
+
from common.models import ArenaAction, ArenaObservation
|
| 12 |
+
|
| 13 |
+
ROOT = Path('/opt/audit')
|
| 14 |
+
SOURCE = json.loads((ROOT / 'SOURCE.json').read_text())
|
| 15 |
+
for relative, digest in SOURCE['files'].items():
|
| 16 |
+
if hashlib.sha256((ROOT / relative).read_bytes()).hexdigest() != digest:
|
| 17 |
+
raise RuntimeError('Original source hash mismatch')
|
| 18 |
+
from audit_trail.models import AuditTrailAction
|
| 19 |
+
from audit_trail.tasks import PROTOCOL
|
| 20 |
+
|
| 21 |
+
TASK_IDS = tuple(SOURCE['registered_tasks'])
|
| 22 |
+
ACTION_MAPPING = ('Use {"op":"call","tool":"grep","arguments":{"text":"<text>"}} to search the log, '
|
| 23 |
+
'or {"op":"call","tool":"answer","arguments":{"value":"<value>"}} to answer. '
|
| 24 |
+
'The requested answer-only value belongs in arguments.value. Return the complete action JSON. '
|
| 25 |
+
'Use {"op":"finish"} to end without an answer. There are 10 actions including the answer.')
|
| 26 |
+
|
| 27 |
+
|
| 28 |
+
def render_question(question):
|
| 29 |
+
if not question.endswith(PROTOCOL) or question.count(PROTOCOL) != 1:
|
| 30 |
+
raise RuntimeError('Original protocol suffix changed')
|
| 31 |
+
return question[:-len(PROTOCOL)] + ACTION_MAPPING
|
| 32 |
+
|
| 33 |
+
|
| 34 |
+
class AuditEnvironment(Environment):
|
| 35 |
+
SUPPORTS_CONCURRENT_SESSIONS = True
|
| 36 |
+
|
| 37 |
+
def __init__(self):
|
| 38 |
+
self.lock = RLock()
|
| 39 |
+
self.module_name = 'audit_trail.server._session_' + uuid4().hex
|
| 40 |
+
path = ROOT / 'upstream/audit_trail/server/audit_trail_environment.py'
|
| 41 |
+
spec = importlib.util.spec_from_file_location(self.module_name, path)
|
| 42 |
+
self.original = importlib.util.module_from_spec(spec)
|
| 43 |
+
sys.modules[self.module_name] = self.original
|
| 44 |
+
try:
|
| 45 |
+
spec.loader.exec_module(self.original)
|
| 46 |
+
self.env = self.original.AuditTrailEnvironment()
|
| 47 |
+
except BaseException:
|
| 48 |
+
sys.modules.pop(self.module_name, None)
|
| 49 |
+
raise
|
| 50 |
+
self.task_id = None
|
| 51 |
+
self.terminal = None
|
| 52 |
+
|
| 53 |
+
def _translate(self, observation):
|
| 54 |
+
message = render_question(observation.question) if observation.question else observation.output
|
| 55 |
+
if message == 'send exactly one of grep or answer':
|
| 56 |
+
message = 'Use call with tool grep and arguments.text, or tool answer and arguments.value.'
|
| 57 |
+
result = ArenaObservation(task_id=observation.task_id, message=message,
|
| 58 |
+
data={'steps_left': observation.steps_left}, reward=observation.reward, done=observation.done)
|
| 59 |
+
if observation.done:
|
| 60 |
+
self.terminal = result
|
| 61 |
+
return result
|
| 62 |
+
|
| 63 |
+
def reset(self, *, task_id=None, seed=None, index=None, split='train', episode_id=None, **kwargs):
|
| 64 |
+
with self.lock:
|
| 65 |
+
if split != 'train':
|
| 66 |
+
raise ValueError('Unknown split')
|
| 67 |
+
if index is not None:
|
| 68 |
+
if type(index) is not int or not 0 <= index < len(TASK_IDS):
|
| 69 |
+
raise ValueError('Invalid task index')
|
| 70 |
+
if task_id is not None and task_id != TASK_IDS[index]:
|
| 71 |
+
raise ValueError('Task selection mismatch')
|
| 72 |
+
task_id = TASK_IDS[index]
|
| 73 |
+
task_id = task_id or TASK_IDS[0]
|
| 74 |
+
if task_id not in TASK_IDS or (seed is not None and type(seed) is not int):
|
| 75 |
+
raise ValueError('Invalid task or seed')
|
| 76 |
+
self.task_id = task_id
|
| 77 |
+
self.terminal = None
|
| 78 |
+
return self._translate(self.env.reset(task_id=task_id, seed=seed, episode_id=episode_id))
|
| 79 |
+
|
| 80 |
+
def step(self, action, timeout_s=None, **kwargs):
|
| 81 |
+
with self.lock:
|
| 82 |
+
if self.task_id is None:
|
| 83 |
+
raise ValueError('Reset before stepping')
|
| 84 |
+
if self.terminal is not None:
|
| 85 |
+
return self.terminal
|
| 86 |
+
value = action.action_payload() if isinstance(action, ArenaAction) else ArenaAction.model_validate(action).action_payload()
|
| 87 |
+
mapped = {}
|
| 88 |
+
if value['op'] == 'finish':
|
| 89 |
+
mapped = {'answer': ''}
|
| 90 |
+
elif value['op'] == 'call':
|
| 91 |
+
tool, args = value['tool'], value['arguments']
|
| 92 |
+
if tool == 'grep' and set(args) == {'text'} and isinstance(args['text'], str) and len(args['text']) <= 200:
|
| 93 |
+
mapped = {'grep': args['text']}
|
| 94 |
+
elif tool == 'answer' and set(args) == {'value'} and isinstance(args['value'], str) and len(args['value']) <= 64:
|
| 95 |
+
mapped = {'answer': args['value']}
|
| 96 |
+
return self._translate(self.env.step(AuditTrailAction(**mapped), timeout_s=timeout_s))
|
| 97 |
+
|
| 98 |
+
@property
|
| 99 |
+
def state(self):
|
| 100 |
+
with self.lock:
|
| 101 |
+
return self.env.state
|
| 102 |
+
|
| 103 |
+
def close(self):
|
| 104 |
+
with self.lock:
|
| 105 |
+
self.original._episode = None
|
| 106 |
+
self.task_id = None
|
| 107 |
+
self.terminal = None
|
| 108 |
+
sys.modules.pop(self.module_name, None)
|
| 109 |
+
|
| 110 |
+
def get_metadata(self):
|
| 111 |
+
return EnvironmentMetadata(name='audit_trail', version='1.0.0', description='Original fixed-seed log audit tasks.')
|
| 112 |
+
|
| 113 |
+
def list_splits(self):
|
| 114 |
+
return ['train']
|
| 115 |
+
|
| 116 |
+
def list_tasks(self, split):
|
| 117 |
+
if split != 'train':
|
| 118 |
+
raise ValueError('Unknown split')
|
| 119 |
+
return [{'id': name, 'index': i} for i, name in enumerate(TASK_IDS)]
|
| 120 |
+
|
| 121 |
+
def num_tasks(self, split):
|
| 122 |
+
return len(self.list_tasks(split))
|
| 123 |
+
|
| 124 |
+
def get_task(self, split, index):
|
| 125 |
+
return self.list_tasks(split)[index]
|
| 126 |
+
|
| 127 |
+
def get_task_range(self, split, start=None, stop=None):
|
| 128 |
+
return self.list_tasks(split)[start:stop]
|
components/{math/runtime/native_shell → audit/runtime/audit}/server.py
RENAMED
|
@@ -1,14 +1,14 @@
|
|
| 1 |
-
|
| 2 |
from openenv.core.env_server.http_server import create_app
|
| 3 |
from common.models import ArenaAction, ArenaObservation
|
| 4 |
-
from .environment import
|
| 5 |
|
| 6 |
-
app=create_app(
|
| 7 |
|
| 8 |
|
| 9 |
def main():
|
| 10 |
import uvicorn
|
| 11 |
-
uvicorn.run(app,host='0.0.0.0',port=8000,log_level='warning')
|
| 12 |
|
| 13 |
|
| 14 |
-
if __name__=='__main__':
|
|
|
|
|
|
|
|
|
| 1 |
from openenv.core.env_server.http_server import create_app
|
| 2 |
from common.models import ArenaAction, ArenaObservation
|
| 3 |
+
from .environment import AuditEnvironment
|
| 4 |
|
| 5 |
+
app = create_app(AuditEnvironment, ArenaAction, ArenaObservation, env_name='audit_trail', max_concurrent_envs=5)
|
| 6 |
|
| 7 |
|
| 8 |
def main():
|
| 9 |
import uvicorn
|
| 10 |
+
uvicorn.run(app, host='0.0.0.0', port=8000, log_level='warning')
|
| 11 |
|
| 12 |
|
| 13 |
+
if __name__ == '__main__':
|
| 14 |
+
main()
|
components/{awm/runtime/awm → audit/runtime/common}/__init__.py
RENAMED
|
File without changes
|
components/{awm → audit}/runtime/common/contracts.py
RENAMED
|
File without changes
|
components/{pdbthink → audit}/runtime/common/models.py
RENAMED
|
@@ -5,6 +5,7 @@ from typing import Any, Literal
|
|
| 5 |
import jsonschema
|
| 6 |
from openenv.core.env_server.types import Action, Observation
|
| 7 |
from pydantic import ConfigDict, Field, model_serializer, model_validator
|
|
|
|
| 8 |
from .contracts import ACTION_SCHEMA
|
| 9 |
|
| 10 |
|
|
@@ -22,7 +23,7 @@ class ArenaAction(Action):
|
|
| 22 |
return value
|
| 23 |
def finite(item):
|
| 24 |
if isinstance(item,float) and not math.isfinite(item):
|
| 25 |
-
raise
|
| 26 |
if isinstance(item,dict):
|
| 27 |
for part in item.values():finite(part)
|
| 28 |
elif isinstance(item,list):
|
|
@@ -31,7 +32,7 @@ class ArenaAction(Action):
|
|
| 31 |
try:
|
| 32 |
jsonschema.Draft202012Validator(ACTION_SCHEMA).validate(value)
|
| 33 |
except jsonschema.ValidationError as exc:
|
| 34 |
-
raise
|
| 35 |
return value
|
| 36 |
|
| 37 |
@classmethod
|
|
|
|
| 5 |
import jsonschema
|
| 6 |
from openenv.core.env_server.types import Action, Observation
|
| 7 |
from pydantic import ConfigDict, Field, model_serializer, model_validator
|
| 8 |
+
from pydantic_core import PydanticCustomError
|
| 9 |
from .contracts import ACTION_SCHEMA
|
| 10 |
|
| 11 |
|
|
|
|
| 23 |
return value
|
| 24 |
def finite(item):
|
| 25 |
if isinstance(item,float) and not math.isfinite(item):
|
| 26 |
+
raise PydanticCustomError('finite_number', 'Non-finite JSON number')
|
| 27 |
if isinstance(item,dict):
|
| 28 |
for part in item.values():finite(part)
|
| 29 |
elif isinstance(item,list):
|
|
|
|
| 32 |
try:
|
| 33 |
jsonschema.Draft202012Validator(ACTION_SCHEMA).validate(value)
|
| 34 |
except jsonschema.ValidationError as exc:
|
| 35 |
+
raise PydanticCustomError('action_contract', '{message}', {'message': exc.message}) from exc
|
| 36 |
return value
|
| 37 |
|
| 38 |
@classmethod
|
components/audit/tasks/auth-05/instruction.md
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
Some source IPs tried to log in between 12:00 and 13:00. Consider only successful logins (result=ok) that came after at least 6 failed logins (result=fail) from the same source IP. Which user name is on the earliest such successful login? Answer with the user name only. Reply {"grep": "<text>"} to search the log (up to 10 matching lines), or {"answer": "<value>"} to finish.
|
components/audit/tasks/ledger-01/instruction.md
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
A duplicate charge is a debit that has an earlier debit with the same acct and the same amount, from 1 to 90 seconds before it, where that earlier debit has no reversal line anywhere in the log whose ref is its txn id. Which txn id is the earliest duplicate charge? Answer with the txn id only. Reply {"grep": "<text>"} to search the log (up to 10 matching lines), or {"answer": "<value>"} to finish.
|
LICENSES/Apache-2.0-PDBThink.txt → components/audit/upstream/LICENSE
RENAMED
|
@@ -1,3 +1,4 @@
|
|
|
|
|
| 1 |
Apache License
|
| 2 |
Version 2.0, January 2004
|
| 3 |
http://www.apache.org/licenses/
|
|
|
|
| 1 |
+
|
| 2 |
Apache License
|
| 3 |
Version 2.0, January 2004
|
| 4 |
http://www.apache.org/licenses/
|
components/audit/upstream/audit_trail/__init__.py
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# SPDX-License-Identifier: Apache-2.0
|
| 2 |
+
|
| 3 |
+
"""Audit Trail Environment."""
|
| 4 |
+
|
| 5 |
+
from .models import AuditTrailAction, AuditTrailObservation
|
| 6 |
+
|
| 7 |
+
__all__ = [
|
| 8 |
+
"AuditTrailAction",
|
| 9 |
+
"AuditTrailObservation",
|
| 10 |
+
]
|
components/audit/upstream/audit_trail/models.py
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# SPDX-License-Identifier: Apache-2.0
|
| 2 |
+
|
| 3 |
+
"""
|
| 4 |
+
Actions and observations for the Audit Trail environment.
|
| 5 |
+
"""
|
| 6 |
+
|
| 7 |
+
from openenv.core.env_server.types import Action, Observation
|
| 8 |
+
from pydantic import Field
|
| 9 |
+
|
| 10 |
+
|
| 11 |
+
class AuditTrailAction(Action):
|
| 12 |
+
"""Search the log or answer. Send exactly one of the two fields."""
|
| 13 |
+
|
| 14 |
+
grep: str | None = Field(
|
| 15 |
+
default=None,
|
| 16 |
+
max_length=200,
|
| 17 |
+
description="Return up to 10 log lines containing this text (case-insensitive). "
|
| 18 |
+
"An empty string returns the first 10 lines.",
|
| 19 |
+
)
|
| 20 |
+
answer: str | None = Field(
|
| 21 |
+
default=None,
|
| 22 |
+
max_length=64,
|
| 23 |
+
description="The value the question asks for. Ends the episode.",
|
| 24 |
+
)
|
| 25 |
+
|
| 26 |
+
|
| 27 |
+
class AuditTrailObservation(Observation):
|
| 28 |
+
"""What the agent sees after each action."""
|
| 29 |
+
|
| 30 |
+
task_id: str = Field(default="", description="Task being played")
|
| 31 |
+
question: str = Field(default="", description="The question. Sent once, at reset.")
|
| 32 |
+
output: str = Field(default="", description="Result of the last action")
|
| 33 |
+
steps_left: int = Field(default=0, description="Actions left before the episode ends")
|
components/audit/upstream/audit_trail/server/__init__.py
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# SPDX-License-Identifier: Apache-2.0
|
| 2 |
+
|
| 3 |
+
"""Audit Trail environment server components."""
|
| 4 |
+
|
| 5 |
+
from .audit_trail_environment import AuditTrailEnvironment
|
| 6 |
+
|
| 7 |
+
__all__ = ["AuditTrailEnvironment"]
|
components/audit/upstream/audit_trail/server/audit_trail_environment.py
ADDED
|
@@ -0,0 +1,111 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# SPDX-License-Identifier: Apache-2.0
|
| 2 |
+
|
| 3 |
+
"""
|
| 4 |
+
Audit Trail environment.
|
| 5 |
+
|
| 6 |
+
Each task is one log from a fixed seed, in one of three families: auth logs
|
| 7 |
+
(cybersecurity), ledger (finance) and sensor readings (natural science). The
|
| 8 |
+
question states a rule. The agent searches the log with ``grep`` and ends the
|
| 9 |
+
episode with ``answer``. Reward is 1.0 for the right value and 0.0 otherwise.
|
| 10 |
+
"""
|
| 11 |
+
|
| 12 |
+
from uuid import uuid4
|
| 13 |
+
|
| 14 |
+
from openenv.core.env_server.interfaces import Environment
|
| 15 |
+
from openenv.core.env_server.types import State
|
| 16 |
+
|
| 17 |
+
from ..models import AuditTrailAction, AuditTrailObservation
|
| 18 |
+
from ..tasks import TASKS, build
|
| 19 |
+
|
| 20 |
+
MAX_STEPS = 10
|
| 21 |
+
MAX_MATCHES = 10
|
| 22 |
+
|
| 23 |
+
# Shared by all instances. The HTTP server builds a new instance per request,
|
| 24 |
+
# so the episode must live outside the instance. The arena runs one episode
|
| 25 |
+
# per sandbox at a time.
|
| 26 |
+
_episode: dict | None = None
|
| 27 |
+
|
| 28 |
+
|
| 29 |
+
class AuditTrailEnvironment(Environment):
|
| 30 |
+
"""Answer a question about one log by searching it with grep."""
|
| 31 |
+
|
| 32 |
+
SUPPORTS_CONCURRENT_SESSIONS: bool = False
|
| 33 |
+
|
| 34 |
+
def reset(
|
| 35 |
+
self,
|
| 36 |
+
seed: int | None = None,
|
| 37 |
+
episode_id: str | None = None,
|
| 38 |
+
task_id: str | None = None,
|
| 39 |
+
**kwargs,
|
| 40 |
+
) -> AuditTrailObservation:
|
| 41 |
+
global _episode
|
| 42 |
+
task_id = task_id or next(iter(TASKS))
|
| 43 |
+
if task_id not in TASKS:
|
| 44 |
+
raise ValueError(f"unknown task_id {task_id!r}")
|
| 45 |
+
|
| 46 |
+
built = build(task_id)
|
| 47 |
+
_episode = {
|
| 48 |
+
"episode_id": episode_id or str(uuid4()),
|
| 49 |
+
"task_id": task_id,
|
| 50 |
+
"lines": built.lines,
|
| 51 |
+
"question": built.question,
|
| 52 |
+
"answer": built.answer,
|
| 53 |
+
"steps": 0,
|
| 54 |
+
"done": False,
|
| 55 |
+
"reward": 0.0,
|
| 56 |
+
}
|
| 57 |
+
return self._observation(output="", done=False, reward=0.0)
|
| 58 |
+
|
| 59 |
+
def step(
|
| 60 |
+
self,
|
| 61 |
+
action: AuditTrailAction,
|
| 62 |
+
timeout_s: float | None = None,
|
| 63 |
+
**kwargs,
|
| 64 |
+
) -> AuditTrailObservation: # type: ignore[override]
|
| 65 |
+
ep = self._require_episode()
|
| 66 |
+
if ep["done"]:
|
| 67 |
+
return self._observation(output="the episode is over", done=True, reward=ep["reward"])
|
| 68 |
+
|
| 69 |
+
ep["steps"] += 1
|
| 70 |
+
if action.answer is not None and action.grep is None:
|
| 71 |
+
correct = action.answer.strip().lower() == ep["answer"]
|
| 72 |
+
return self._finish(1.0 if correct else 0.0, "correct" if correct else "wrong")
|
| 73 |
+
if action.grep is not None and action.answer is None:
|
| 74 |
+
needle = action.grep.lower()
|
| 75 |
+
matches = [line for line in ep["lines"] if needle in line.lower()]
|
| 76 |
+
output = "\n".join(matches[:MAX_MATCHES]) or "no matching lines"
|
| 77 |
+
if len(matches) > MAX_MATCHES:
|
| 78 |
+
output += f"\n({len(matches)} matches, first {MAX_MATCHES} shown)"
|
| 79 |
+
else:
|
| 80 |
+
output = "send exactly one of grep or answer"
|
| 81 |
+
|
| 82 |
+
if ep["steps"] >= MAX_STEPS:
|
| 83 |
+
return self._finish(0.0, output + "\nno steps left")
|
| 84 |
+
return self._observation(output=output, done=False, reward=0.0)
|
| 85 |
+
|
| 86 |
+
@property
|
| 87 |
+
def state(self) -> State:
|
| 88 |
+
ep = _episode or {}
|
| 89 |
+
return State(episode_id=ep.get("episode_id"), step_count=ep.get("steps", 0))
|
| 90 |
+
|
| 91 |
+
def _require_episode(self) -> dict:
|
| 92 |
+
if _episode is None:
|
| 93 |
+
raise RuntimeError("call reset() before step()")
|
| 94 |
+
return _episode
|
| 95 |
+
|
| 96 |
+
def _finish(self, reward: float, output: str) -> AuditTrailObservation:
|
| 97 |
+
ep = self._require_episode()
|
| 98 |
+
ep["done"] = True
|
| 99 |
+
ep["reward"] = reward
|
| 100 |
+
return self._observation(output=output, done=True, reward=reward)
|
| 101 |
+
|
| 102 |
+
def _observation(self, output: str, done: bool, reward: float) -> AuditTrailObservation:
|
| 103 |
+
ep = self._require_episode()
|
| 104 |
+
return AuditTrailObservation(
|
| 105 |
+
task_id=ep["task_id"],
|
| 106 |
+
question=ep["question"] if ep["steps"] == 0 else "",
|
| 107 |
+
output=output,
|
| 108 |
+
steps_left=max(0, MAX_STEPS - ep["steps"]),
|
| 109 |
+
done=done,
|
| 110 |
+
reward=reward,
|
| 111 |
+
)
|
components/audit/upstream/audit_trail/tasks.py
ADDED
|
@@ -0,0 +1,381 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# SPDX-License-Identifier: Apache-2.0
|
| 2 |
+
|
| 3 |
+
"""
|
| 4 |
+
Tasks for the Audit Trail environment.
|
| 5 |
+
|
| 6 |
+
Three families of logs: authentication (cybersecurity), ledger (finance) and
|
| 7 |
+
sensor readings (natural science). Each task builds one log from its seed. The
|
| 8 |
+
question states a rule, and the answer follows from that rule. The answer is
|
| 9 |
+
computed from the log when the task is built. No answer is stored.
|
| 10 |
+
|
| 11 |
+
Levels 0-2 are easy, 3-5 medium and 6-7 hard. Harder levels have longer logs,
|
| 12 |
+
more decoys and a larger threshold, so one grep shows less of the answer.
|
| 13 |
+
"""
|
| 14 |
+
|
| 15 |
+
import random
|
| 16 |
+
from collections.abc import Callable
|
| 17 |
+
from dataclasses import dataclass
|
| 18 |
+
|
| 19 |
+
FAMILIES = ("auth", "ledger", "sensor")
|
| 20 |
+
TASKS_PER_FAMILY = 8
|
| 21 |
+
|
| 22 |
+
# A generator rejects a seed when its log does not meet the family's checks. It then tries
|
| 23 |
+
# seed + ATTEMPT_STEP, and so on up to MAX_ATTEMPTS. The accepted seed is recorded in the task.
|
| 24 |
+
MAX_ATTEMPTS = 50
|
| 25 |
+
ATTEMPT_STEP = 100
|
| 26 |
+
|
| 27 |
+
PROTOCOL = (
|
| 28 |
+
'Reply {"grep": "<text>"} to search the log (up to 10 matching lines), '
|
| 29 |
+
'or {"answer": "<value>"} to finish.'
|
| 30 |
+
)
|
| 31 |
+
|
| 32 |
+
|
| 33 |
+
@dataclass(frozen=True)
|
| 34 |
+
class Task:
|
| 35 |
+
task_id: str
|
| 36 |
+
family: str
|
| 37 |
+
level: int
|
| 38 |
+
seed: int
|
| 39 |
+
|
| 40 |
+
|
| 41 |
+
@dataclass(frozen=True)
|
| 42 |
+
class Built:
|
| 43 |
+
lines: list[str]
|
| 44 |
+
answer: str
|
| 45 |
+
question: str
|
| 46 |
+
seed: int
|
| 47 |
+
|
| 48 |
+
|
| 49 |
+
def _task_table() -> dict[str, Task]:
|
| 50 |
+
table: dict[str, Task] = {}
|
| 51 |
+
for family_index, family in enumerate(FAMILIES):
|
| 52 |
+
for level in range(TASKS_PER_FAMILY):
|
| 53 |
+
task_id = f"{family}-{level:02d}"
|
| 54 |
+
table[task_id] = Task(task_id, family, level, 2000 + 10 * family_index + level)
|
| 55 |
+
return table
|
| 56 |
+
|
| 57 |
+
|
| 58 |
+
TASKS = _task_table()
|
| 59 |
+
|
| 60 |
+
|
| 61 |
+
def _tier(level: int) -> int:
|
| 62 |
+
return 0 if level < 3 else 1 if level < 6 else 2
|
| 63 |
+
|
| 64 |
+
|
| 65 |
+
def _clock(seconds: int) -> str:
|
| 66 |
+
hours, rest = divmod(seconds, 3600)
|
| 67 |
+
minutes, secs = divmod(rest, 60)
|
| 68 |
+
return f"{hours:02d}:{minutes:02d}:{secs:02d}"
|
| 69 |
+
|
| 70 |
+
|
| 71 |
+
def _claim(used: set[int], second: int) -> int:
|
| 72 |
+
"""Return the first second at or after ``second`` that no other line uses."""
|
| 73 |
+
while second in used:
|
| 74 |
+
second += 1
|
| 75 |
+
used.add(second)
|
| 76 |
+
return second
|
| 77 |
+
|
| 78 |
+
|
| 79 |
+
def _ask(body: str, reply: str) -> str:
|
| 80 |
+
return f"{body} Answer with {reply} only. {PROTOCOL}"
|
| 81 |
+
|
| 82 |
+
|
| 83 |
+
# ---------------------------------------------------------------- auth
|
| 84 |
+
|
| 85 |
+
|
| 86 |
+
AUTH_USERS = ["alice", "bob", "carol", "dave", "erin", "frank", "grace", "heidi", "ivan", "judy"]
|
| 87 |
+
AUTH_START = 12 * 3600
|
| 88 |
+
AUTH_END = 13 * 3600 - 1
|
| 89 |
+
AUTH_LINES = (42, 52, 62)
|
| 90 |
+
AUTH_NEAR_MISSES = (1, 2, 3)
|
| 91 |
+
AUTH_FAIL_ONLY = (1, 1, 2)
|
| 92 |
+
AUTH_LEGIT_SOURCES = 4
|
| 93 |
+
|
| 94 |
+
|
| 95 |
+
def _make_auth(level: int, rng: random.Random) -> Built | None:
|
| 96 |
+
"""One source has k failures and then a success. Near misses have k-1 failures, fail-only
|
| 97 |
+
sources have no success, and legitimate sources have fewer than k failures in total."""
|
| 98 |
+
tier = _tier(level)
|
| 99 |
+
k = 5 + level // 3
|
| 100 |
+
near, fail_only = AUTH_NEAR_MISSES[tier], AUTH_FAIL_ONLY[tier]
|
| 101 |
+
used: set[int] = set()
|
| 102 |
+
octets = rng.sample(range(1, 200), 1 + near + fail_only + AUTH_LEGIT_SOURCES)
|
| 103 |
+
ips = [f"10.0.{octet}.{rng.randint(100, 199)}" for octet in octets]
|
| 104 |
+
target, near_ips = ips[0], ips[1 : 1 + near]
|
| 105 |
+
fail_ips = ips[1 + near : 1 + near + fail_only]
|
| 106 |
+
legit_ips = ips[1 + near + fail_only :]
|
| 107 |
+
|
| 108 |
+
events: list[tuple[int, str, str, str]] = []
|
| 109 |
+
answer_user = rng.choice(AUTH_USERS)
|
| 110 |
+
|
| 111 |
+
def when(low: int, high: int) -> int:
|
| 112 |
+
return _claim(used, rng.randrange(low, high))
|
| 113 |
+
|
| 114 |
+
def run_of_fails(source: str, count: int) -> list[int]:
|
| 115 |
+
times = sorted(when(AUTH_START, AUTH_END - 900) for _ in range(count))
|
| 116 |
+
events.extend((t, rng.choice(AUTH_USERS), source, "fail") for t in times)
|
| 117 |
+
return times
|
| 118 |
+
|
| 119 |
+
fails = run_of_fails(target, k)
|
| 120 |
+
events.append((_claim(used, fails[-1] + rng.randint(30, 300)), answer_user, target, "ok"))
|
| 121 |
+
|
| 122 |
+
for source in near_ips:
|
| 123 |
+
fails = run_of_fails(source, k - 1)
|
| 124 |
+
events.append(
|
| 125 |
+
(_claim(used, fails[-1] + rng.randint(30, 300)), rng.choice(AUTH_USERS), source, "ok")
|
| 126 |
+
)
|
| 127 |
+
|
| 128 |
+
for source in fail_ips:
|
| 129 |
+
run_of_fails(source, k + 3)
|
| 130 |
+
|
| 131 |
+
for source in legit_ips:
|
| 132 |
+
run_of_fails(source, rng.randint(0, min(k - 1, 2)))
|
| 133 |
+
|
| 134 |
+
target_lines = AUTH_LINES[tier] + rng.randint(0, 4)
|
| 135 |
+
while len(events) < target_lines:
|
| 136 |
+
source = rng.choice(legit_ips)
|
| 137 |
+
events.append((when(AUTH_START, AUTH_END), rng.choice(AUTH_USERS), source, "ok"))
|
| 138 |
+
|
| 139 |
+
# The rule: an ok line counts when its source has at least k fail lines before it.
|
| 140 |
+
qualifying: dict[str, list[tuple[int, str]]] = {}
|
| 141 |
+
seen_fails: dict[str, int] = {}
|
| 142 |
+
for second, name, source, result in sorted(events):
|
| 143 |
+
if result == "fail":
|
| 144 |
+
seen_fails[source] = seen_fails.get(source, 0) + 1
|
| 145 |
+
elif seen_fails.get(source, 0) >= k:
|
| 146 |
+
qualifying.setdefault(source, []).append((second, name))
|
| 147 |
+
if set(qualifying) != {target}:
|
| 148 |
+
return None
|
| 149 |
+
answer = min(qualifying[target])[1]
|
| 150 |
+
|
| 151 |
+
lines = [
|
| 152 |
+
f"{_clock(second)} auth user={name} src={source} result={result}"
|
| 153 |
+
for second, name, source, result in sorted(events)
|
| 154 |
+
]
|
| 155 |
+
question = _ask(
|
| 156 |
+
"Some source IPs tried to log in between 12:00 and 13:00. Consider only successful logins "
|
| 157 |
+
f"(result=ok) that came after at least {k} failed logins (result=fail) from the same "
|
| 158 |
+
"source IP. Which user name is on the earliest such successful login?",
|
| 159 |
+
"the user name",
|
| 160 |
+
)
|
| 161 |
+
return Built(lines, answer, question, 0)
|
| 162 |
+
|
| 163 |
+
|
| 164 |
+
# ---------------------------------------------------------------- ledger
|
| 165 |
+
|
| 166 |
+
|
| 167 |
+
LEDGER_START = 10 * 3600
|
| 168 |
+
LEDGER_END = 11 * 3600 - 1
|
| 169 |
+
LEDGER_WINDOW = 90
|
| 170 |
+
LEDGER_LINES = (38, 48, 58)
|
| 171 |
+
LEDGER_DUPLICATES = (1, 2, 2)
|
| 172 |
+
|
| 173 |
+
|
| 174 |
+
@dataclass(frozen=True)
|
| 175 |
+
class Txn:
|
| 176 |
+
second: int
|
| 177 |
+
txn: str
|
| 178 |
+
acct: str
|
| 179 |
+
kind: str
|
| 180 |
+
amount: str
|
| 181 |
+
ref: str
|
| 182 |
+
|
| 183 |
+
|
| 184 |
+
def _ledger_duplicates(txns: list[Txn]) -> list[Txn]:
|
| 185 |
+
"""Each debit that has an earlier debit with the same account and amount, 1 to 90 s before,
|
| 186 |
+
where that earlier debit has no reversal line whose ref is its txn id."""
|
| 187 |
+
reversed_refs = {t.ref for t in txns if t.kind == "reversal"}
|
| 188 |
+
debits = [t for t in txns if t.kind == "debit"]
|
| 189 |
+
duplicates = []
|
| 190 |
+
for later in debits:
|
| 191 |
+
for earlier in debits:
|
| 192 |
+
gap = later.second - earlier.second
|
| 193 |
+
if (
|
| 194 |
+
earlier.acct == later.acct
|
| 195 |
+
and earlier.amount == later.amount
|
| 196 |
+
and 1 <= gap <= LEDGER_WINDOW
|
| 197 |
+
and earlier.txn not in reversed_refs
|
| 198 |
+
):
|
| 199 |
+
duplicates.append(later)
|
| 200 |
+
break
|
| 201 |
+
return duplicates
|
| 202 |
+
|
| 203 |
+
|
| 204 |
+
def _make_ledger(level: int, rng: random.Random) -> Built | None:
|
| 205 |
+
tier = _tier(level)
|
| 206 |
+
used: set[int] = set()
|
| 207 |
+
ids = iter(rng.sample(range(1000, 10000), 200))
|
| 208 |
+
accts = [f"A-{n}" for n in rng.sample(range(10, 100), 60)]
|
| 209 |
+
cents = iter(rng.sample(range(1000, 50000), 200))
|
| 210 |
+
|
| 211 |
+
def amount() -> str:
|
| 212 |
+
value = next(cents)
|
| 213 |
+
return f"{value // 100}.{value % 100:02d}"
|
| 214 |
+
|
| 215 |
+
def txn_id() -> str:
|
| 216 |
+
return f"T{next(ids)}"
|
| 217 |
+
|
| 218 |
+
def at(low: int, high: int) -> int:
|
| 219 |
+
return _claim(used, rng.randrange(low, high))
|
| 220 |
+
|
| 221 |
+
txns: list[Txn] = []
|
| 222 |
+
|
| 223 |
+
# True duplicates: a debit repeated within the window, never reversed.
|
| 224 |
+
for index in range(LEDGER_DUPLICATES[tier]):
|
| 225 |
+
account, value = accts[index], amount()
|
| 226 |
+
first = at(LEDGER_START, LEDGER_END - 900)
|
| 227 |
+
txns.append(Txn(first, txn_id(), account, "debit", value, "-"))
|
| 228 |
+
dup = _claim(used, first + rng.randint(1, LEDGER_WINDOW))
|
| 229 |
+
txns.append(Txn(dup, txn_id(), account, "debit", value, "-"))
|
| 230 |
+
|
| 231 |
+
decoy_base = 3 + LEDGER_DUPLICATES[tier]
|
| 232 |
+
for index in range(1 + tier):
|
| 233 |
+
other, third, fourth = (
|
| 234 |
+
accts[decoy_base + 3 * index],
|
| 235 |
+
accts[decoy_base + 1 + 3 * index],
|
| 236 |
+
accts[decoy_base + 2 + 3 * index],
|
| 237 |
+
)
|
| 238 |
+
|
| 239 |
+
# Same amount on another account, within the window: not a duplicate.
|
| 240 |
+
same_amount = amount()
|
| 241 |
+
t1 = at(LEDGER_START, LEDGER_END - 900)
|
| 242 |
+
txns.append(Txn(t1, txn_id(), other, "debit", same_amount, "-"))
|
| 243 |
+
t2 = _claim(used, t1 + rng.randint(1, LEDGER_WINDOW))
|
| 244 |
+
txns.append(Txn(t2, txn_id(), third, "debit", same_amount, "-"))
|
| 245 |
+
|
| 246 |
+
# Same account and amount, but more than the window apart: not a duplicate.
|
| 247 |
+
far_amount = amount()
|
| 248 |
+
t3 = at(LEDGER_START, LEDGER_END - 1800)
|
| 249 |
+
txns.append(Txn(t3, txn_id(), other, "debit", far_amount, "-"))
|
| 250 |
+
t4 = _claim(used, t3 + rng.randint(120, 900))
|
| 251 |
+
txns.append(Txn(t4, txn_id(), other, "debit", far_amount, "-"))
|
| 252 |
+
|
| 253 |
+
# Same account and amount within the window, but the earlier debit was reversed.
|
| 254 |
+
reversed_amount = amount()
|
| 255 |
+
t5 = at(LEDGER_START, LEDGER_END - 1800)
|
| 256 |
+
reversed_id = txn_id()
|
| 257 |
+
txns.append(Txn(t5, reversed_id, third, "debit", reversed_amount, "-"))
|
| 258 |
+
t6 = _claim(used, t5 + rng.randint(1, LEDGER_WINDOW))
|
| 259 |
+
txns.append(Txn(t6, txn_id(), third, "debit", reversed_amount, "-"))
|
| 260 |
+
t7 = _claim(used, t6 + rng.randint(1, 300))
|
| 261 |
+
txns.append(Txn(t7, txn_id(), third, "reversal", reversed_amount, reversed_id))
|
| 262 |
+
|
| 263 |
+
# A credit with the same amount as an earlier debit, within the window: not a duplicate.
|
| 264 |
+
credit_amount = amount()
|
| 265 |
+
t8 = at(LEDGER_START, LEDGER_END - 900)
|
| 266 |
+
txns.append(Txn(t8, txn_id(), fourth, "debit", credit_amount, "-"))
|
| 267 |
+
t9 = _claim(used, t8 + rng.randint(1, LEDGER_WINDOW))
|
| 268 |
+
txns.append(Txn(t9, txn_id(), fourth, "credit", credit_amount, "-"))
|
| 269 |
+
|
| 270 |
+
while len(txns) < LEDGER_LINES[tier] + rng.randint(0, 4):
|
| 271 |
+
kind = rng.choice(["debit", "debit", "credit"])
|
| 272 |
+
txns.append(
|
| 273 |
+
Txn(at(LEDGER_START, LEDGER_END), txn_id(), rng.choice(accts[40:]), kind, amount(), "-")
|
| 274 |
+
)
|
| 275 |
+
|
| 276 |
+
duplicates = _ledger_duplicates(txns)
|
| 277 |
+
if len(duplicates) != LEDGER_DUPLICATES[tier]:
|
| 278 |
+
return None
|
| 279 |
+
earliest = min(duplicates, key=lambda t: t.second)
|
| 280 |
+
txns.sort(key=lambda t: t.second)
|
| 281 |
+
lines = [
|
| 282 |
+
f"{_clock(t.second)} txn={t.txn} acct={t.acct} type={t.kind} amount={t.amount} ref={t.ref}"
|
| 283 |
+
for t in txns
|
| 284 |
+
]
|
| 285 |
+
question = _ask(
|
| 286 |
+
"A duplicate charge is a debit that has an earlier debit with the same acct and the same "
|
| 287 |
+
f"amount, from 1 to {LEDGER_WINDOW} seconds before it, where that earlier debit has no "
|
| 288 |
+
"reversal line anywhere in the log whose ref is its txn id. Which txn id is the earliest "
|
| 289 |
+
"duplicate charge?",
|
| 290 |
+
"the txn id",
|
| 291 |
+
)
|
| 292 |
+
return Built(lines, earliest.txn.lower(), question, 0)
|
| 293 |
+
|
| 294 |
+
|
| 295 |
+
# ---------------------------------------------------------------- sensor
|
| 296 |
+
|
| 297 |
+
|
| 298 |
+
STATIONS = ["delta", "harbor", "lake", "mesa", "pine", "quarry", "ridge", "summit"]
|
| 299 |
+
SENSOR_STATIONS = (3, 5, 6)
|
| 300 |
+
SENSOR_READINGS = (15, 11, 9)
|
| 301 |
+
SENSOR_LAST_MINUTE = 6 * 60 + 50 # each station ends near 06:50, after the alert
|
| 302 |
+
HEAT_START = 6 * 3600
|
| 303 |
+
THRESHOLD = 300 # tenths of a degree C, so 30.0 C is exact
|
| 304 |
+
|
| 305 |
+
|
| 306 |
+
def _make_sensor(level: int, rng: random.Random) -> Built | None:
|
| 307 |
+
"""Stations report every 10 minutes at their own offset, so no two readings share a minute.
|
| 308 |
+
The answer is the station with the earliest onset (first reading from 06:00 at 30.0 C or more)
|
| 309 |
+
whose next reading is also 30.0 C or more. Seeds are rejected unless the answer is hidden
|
| 310 |
+
from a plain grep for hot readings."""
|
| 311 |
+
tier = _tier(level)
|
| 312 |
+
names = rng.sample(STATIONS, SENSOR_STATIONS[tier])
|
| 313 |
+
offsets = rng.sample(range(10), len(names))
|
| 314 |
+
count = SENSOR_READINGS[tier]
|
| 315 |
+
first_minute = SENSOR_LAST_MINUTE - 10 * (count - 1)
|
| 316 |
+
readings: list[tuple[int, str, int]] = []
|
| 317 |
+
for name, offset in zip(names, offsets, strict=True):
|
| 318 |
+
temp = rng.randint(270, 300)
|
| 319 |
+
for index in range(count):
|
| 320 |
+
temp = min(max(temp + rng.randint(-25, 25), 240), 340)
|
| 321 |
+
minute = first_minute + 10 * index + offset
|
| 322 |
+
readings.append((minute * 60, name, temp))
|
| 323 |
+
readings.sort()
|
| 324 |
+
|
| 325 |
+
hot = [r for r in readings if r[2] >= THRESHOLD]
|
| 326 |
+
if len(hot) < 12 or sum(1 for r in hot if r[0] < HEAT_START) < 5:
|
| 327 |
+
return None
|
| 328 |
+
|
| 329 |
+
best: tuple[int, str] | None = None
|
| 330 |
+
for name in names:
|
| 331 |
+
series = [(second, temp) for second, station, temp in readings if station == name]
|
| 332 |
+
onset = next(
|
| 333 |
+
(
|
| 334 |
+
i
|
| 335 |
+
for i, (second, temp) in enumerate(series)
|
| 336 |
+
if second >= HEAT_START and temp >= THRESHOLD
|
| 337 |
+
),
|
| 338 |
+
None,
|
| 339 |
+
)
|
| 340 |
+
if onset is None or onset + 1 >= len(series) or series[onset + 1][1] < THRESHOLD:
|
| 341 |
+
continue
|
| 342 |
+
if best is None or series[onset][0] < best[0]:
|
| 343 |
+
best = (series[onset][0], name)
|
| 344 |
+
if best is None:
|
| 345 |
+
return None
|
| 346 |
+
# Six hot readings come before the answer, so it is not among the first hot readings in the log.
|
| 347 |
+
if sum(1 for r in hot if r[0] < best[0]) < 6:
|
| 348 |
+
return None
|
| 349 |
+
|
| 350 |
+
lines = [
|
| 351 |
+
f"{_clock(second)[:5]} station={station} temp_c={temp // 10}.{temp % 10}"
|
| 352 |
+
for second, station, temp in readings
|
| 353 |
+
]
|
| 354 |
+
question = _ask(
|
| 355 |
+
"A heat alert started at 06:00. For each station, take its first reading at or after "
|
| 356 |
+
"06:00 that is 30.0 C or more. Keep the stations whose next reading after that reading "
|
| 357 |
+
"is also 30.0 C or more. Which kept station has the earliest such reading?",
|
| 358 |
+
"the station name",
|
| 359 |
+
)
|
| 360 |
+
return Built(lines, best[1], question, 0)
|
| 361 |
+
|
| 362 |
+
|
| 363 |
+
# ---------------------------------------------------------------- public
|
| 364 |
+
|
| 365 |
+
|
| 366 |
+
_MAKERS: dict[str, Callable[[int, random.Random], Built | None]] = {
|
| 367 |
+
"auth": _make_auth,
|
| 368 |
+
"ledger": _make_ledger,
|
| 369 |
+
"sensor": _make_sensor,
|
| 370 |
+
}
|
| 371 |
+
|
| 372 |
+
|
| 373 |
+
def build(task_id: str) -> Built:
|
| 374 |
+
"""Build the log, the answer, the question and the accepted seed for one task."""
|
| 375 |
+
task = TASKS[task_id]
|
| 376 |
+
for attempt in range(MAX_ATTEMPTS):
|
| 377 |
+
seed = task.seed + ATTEMPT_STEP * attempt
|
| 378 |
+
built = _MAKERS[task.family](task.level, random.Random(seed))
|
| 379 |
+
if built is not None:
|
| 380 |
+
return Built(built.lines, built.answer, built.question, seed)
|
| 381 |
+
raise ValueError(f"no accepted log for {task_id} within {MAX_ATTEMPTS} seeds")
|
components/audit/upstream/dataset/README.md
ADDED
|
@@ -0,0 +1,57 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: apache-2.0
|
| 3 |
+
language:
|
| 4 |
+
- en
|
| 5 |
+
pretty_name: Audit Trail tasks
|
| 6 |
+
tags:
|
| 7 |
+
- openenv
|
| 8 |
+
- log-analysis
|
| 9 |
+
- cybersecurity
|
| 10 |
+
- finance
|
| 11 |
+
- reinforcement-learning
|
| 12 |
+
size_categories:
|
| 13 |
+
- n<1K
|
| 14 |
+
---
|
| 15 |
+
|
| 16 |
+
# Audit Trail tasks
|
| 17 |
+
|
| 18 |
+
This dataset lists the tasks of the Audit Trail OpenEnv environment. The environment code is in the [GitHub repository](https://github.com/NoeFlandre/openenv-arena).
|
| 19 |
+
|
| 20 |
+
## What the environment teaches
|
| 21 |
+
|
| 22 |
+
The agent gets one log and a question. The question states a rule. The agent searches the log with `grep` and gives one answer. The rule has two steps: find the right lines, then compare them. The logs come from three families:
|
| 23 |
+
|
| 24 |
+
| Family | Domain | Rule |
|
| 25 |
+
| --- | --- | --- |
|
| 26 |
+
| `auth` | Cybersecurity | The earliest successful login from a source IP that had at least K failed logins before it. Answer: the user name. |
|
| 27 |
+
| `ledger` | Finance | The earliest debit that repeats an earlier debit with the same account and amount, 1 to 90 seconds before it, where the earlier debit was never reversed. Answer: the txn id. |
|
| 28 |
+
| `sensor` | Natural science | Among stations whose first reading at or after 06:00 of 30.0 C or more is followed by another reading of 30.0 C or more, the station with the earliest such reading. Answer: the station name. |
|
| 29 |
+
|
| 30 |
+
Each task has a level from 0 to 7. Levels 0 to 2 are easy, 3 to 5 medium and 6 to 7 hard. Harder levels have longer logs, more decoys and a higher K.
|
| 31 |
+
|
| 32 |
+
## Files
|
| 33 |
+
|
| 34 |
+
| File | Contents |
|
| 35 |
+
| --- | --- |
|
| 36 |
+
| `tasks.jsonl` | One task for each line: `task_id`, `split`, `family`, `level` and the accepted `seed`. |
|
| 37 |
+
|
| 38 |
+
The dataset does not contain the logs. The server builds each log from its seed, so the same seed always gives the same log and answer. If a seed does not give a log that passes the checks, the server tries the seed plus 100, then plus 200, and so on. The accepted seed is in `tasks.jsonl`.
|
| 39 |
+
|
| 40 |
+
## Reward
|
| 41 |
+
|
| 42 |
+
- `1.0`: the answer is correct. Case does not matter.
|
| 43 |
+
- `0.0`: the answer is wrong, or the agent uses all 10 steps.
|
| 44 |
+
|
| 45 |
+
## Splits
|
| 46 |
+
|
| 47 |
+
All 24 tasks are in the `train` split.
|
| 48 |
+
|
| 49 |
+
## Limits
|
| 50 |
+
|
| 51 |
+
- The logs are synthetic. They do not come from a real system.
|
| 52 |
+
- A grep returns at most 10 matching lines.
|
| 53 |
+
- Each episode has 10 steps.
|
| 54 |
+
|
| 55 |
+
## License
|
| 56 |
+
|
| 57 |
+
Apache License 2.0.
|
components/audit/upstream/dataset/tasks.jsonl
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{"task_id": "auth-00", "split": "train", "family": "auth", "level": 0, "seed": 2000}
|
| 2 |
+
{"task_id": "auth-01", "split": "train", "family": "auth", "level": 1, "seed": 2001}
|
| 3 |
+
{"task_id": "auth-02", "split": "train", "family": "auth", "level": 2, "seed": 2002}
|
| 4 |
+
{"task_id": "auth-03", "split": "train", "family": "auth", "level": 3, "seed": 2003}
|
| 5 |
+
{"task_id": "auth-04", "split": "train", "family": "auth", "level": 4, "seed": 2004}
|
| 6 |
+
{"task_id": "auth-05", "split": "train", "family": "auth", "level": 5, "seed": 2005}
|
| 7 |
+
{"task_id": "auth-06", "split": "train", "family": "auth", "level": 6, "seed": 2006}
|
| 8 |
+
{"task_id": "auth-07", "split": "train", "family": "auth", "level": 7, "seed": 2007}
|
| 9 |
+
{"task_id": "ledger-00", "split": "train", "family": "ledger", "level": 0, "seed": 2010}
|
| 10 |
+
{"task_id": "ledger-01", "split": "train", "family": "ledger", "level": 1, "seed": 2011}
|
| 11 |
+
{"task_id": "ledger-02", "split": "train", "family": "ledger", "level": 2, "seed": 2012}
|
| 12 |
+
{"task_id": "ledger-03", "split": "train", "family": "ledger", "level": 3, "seed": 2013}
|
| 13 |
+
{"task_id": "ledger-04", "split": "train", "family": "ledger", "level": 4, "seed": 2014}
|
| 14 |
+
{"task_id": "ledger-05", "split": "train", "family": "ledger", "level": 5, "seed": 2015}
|
| 15 |
+
{"task_id": "ledger-06", "split": "train", "family": "ledger", "level": 6, "seed": 2016}
|
| 16 |
+
{"task_id": "ledger-07", "split": "train", "family": "ledger", "level": 7, "seed": 2017}
|
| 17 |
+
{"task_id": "sensor-00", "split": "train", "family": "sensor", "level": 0, "seed": 2320}
|
| 18 |
+
{"task_id": "sensor-01", "split": "train", "family": "sensor", "level": 1, "seed": 2021}
|
| 19 |
+
{"task_id": "sensor-02", "split": "train", "family": "sensor", "level": 2, "seed": 2022}
|
| 20 |
+
{"task_id": "sensor-03", "split": "train", "family": "sensor", "level": 3, "seed": 2023}
|
| 21 |
+
{"task_id": "sensor-04", "split": "train", "family": "sensor", "level": 4, "seed": 2024}
|
| 22 |
+
{"task_id": "sensor-05", "split": "train", "family": "sensor", "level": 5, "seed": 2125}
|
| 23 |
+
{"task_id": "sensor-06", "split": "train", "family": "sensor", "level": 6, "seed": 2126}
|
| 24 |
+
{"task_id": "sensor-07", "split": "train", "family": "sensor", "level": 7, "seed": 2027}
|
components/awm/ADAPTATIONS.txt
DELETED
|
@@ -1,4 +0,0 @@
|
|
| 1 |
-
Interface: call and finish using the original FastApiMCP business tools.
|
| 2 |
-
Reset copies the original seed database; finish runs the original state checker.
|
| 3 |
-
The accounting adapter retains committed SQLAlchemy attributes for response serialization after session closure.
|
| 4 |
-
Each episode has a 600-second limit. FastApiMCP 0.4.0 and the OpenEnv SDK use separate Python environments. Dependency versions are recorded in the two requirements.lock files.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
components/awm/Dockerfile
DELETED
|
@@ -1,5 +0,0 @@
|
|
| 1 |
-
FROM ghcr.io/bochencs/openenv-awm@sha256:ca13dd484ed50f5f72e1de652ab55ac25dd7550ee1558f553a3d6eae5a07cb95
|
| 2 |
-
USER root
|
| 3 |
-
COPY config.json /opt/awm/config.json
|
| 4 |
-
COPY runtime/awm/adapter.py runtime/awm/worker.py /opt/awm/runtime/awm/
|
| 5 |
-
RUN rm -rf /opt/awm/private/tasks/awm-manufacturing-1-schedule && chmod 600 /opt/awm/config.json
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
components/awm/LICENSE_SCOPE.json
DELETED
|
@@ -1,22 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"component": "awm",
|
| 3 |
-
"upstream": {
|
| 4 |
-
"scope": "Original AWM request text, generated API source, schema/sample rows and pure-code verifiers",
|
| 5 |
-
"license": "CC-BY-4.0",
|
| 6 |
-
"notice": "NOTICE",
|
| 7 |
-
"source_credit": "SOURCE_CREDITS.json",
|
| 8 |
-
"materialized_seed": "Frozen database generated from the original schema/sample SQL; not an upstream binary file."
|
| 9 |
-
},
|
| 10 |
-
"adapter": {
|
| 11 |
-
"scope": "Local transport/packaging adaptations in awm/runtime and configuration metadata",
|
| 12 |
-
"note": "Local adaptation; not attributed as upstream AWM source."
|
| 13 |
-
},
|
| 14 |
-
"dependencies": {
|
| 15 |
-
"scope": "Installed third-party libraries and official OpenEnv SDK",
|
| 16 |
-
"note": "Keep respective installed package licenses; these are not relicensed under dataset licenses. Dependency names, versions and wheel hashes are in lock files.",
|
| 17 |
-
"lock_files": [
|
| 18 |
-
"requirements.lock",
|
| 19 |
-
"awm-requirements.lock"
|
| 20 |
-
]
|
| 21 |
-
}
|
| 22 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
components/awm/NOTICE
DELETED
|
@@ -1,6 +0,0 @@
|
|
| 1 |
-
This image adapts one unchanged original train task from AgentWorldModel-1K.
|
| 2 |
-
Authors: Zhaoyang Wang, Canwen Xu, Boyi Liu, Yite Wang, Siwei Han, Zhewei Yao, Huaxiu Yao, Yuxiong He.
|
| 3 |
-
Dataset: https://huggingface.co/datasets/Snowflake/AgentWorldModel-1K/tree/dde80a0283fe781bdc51656bce57063dc5650213
|
| 4 |
-
License: Creative Commons Attribution 4.0 International (CC BY 4.0).
|
| 5 |
-
License terms: https://creativecommons.org/licenses/by/4.0/
|
| 6 |
-
Changes: shared OpenEnv transport, fixed task selection, isolated per-episode database, original FastApiMCP 0.4.0 worker environment. Original task requests, API source, seed data and pure-code graders are unchanged.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
components/awm/SOURCE_CREDITS.json
DELETED
|
@@ -1,9 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"repo": "Snowflake/AgentWorldModel-1K",
|
| 3 |
-
"revision": "dde80a0283fe781bdc51656bce57063dc5650213",
|
| 4 |
-
"url": "https://huggingface.co/datasets/Snowflake/AgentWorldModel-1K/tree/dde80a0283fe781bdc51656bce57063dc5650213",
|
| 5 |
-
"license": "CC-BY-4.0",
|
| 6 |
-
"authors": "Zhaoyang Wang, Canwen Xu, Boyi Liu, Yite Wang, Siwei Han, Zhewei Yao, Huaxiu Yao, Yuxiong He",
|
| 7 |
-
"paper": "https://arxiv.org/abs/2602.10090",
|
| 8 |
-
"code": "https://github.com/Snowflake-Labs/agent-world-model"
|
| 9 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
components/awm/TASKS.json
DELETED
|
@@ -1,36 +0,0 @@
|
|
| 1 |
-
[
|
| 2 |
-
{
|
| 3 |
-
"task_id": "awm-accounting-1-invoice",
|
| 4 |
-
"source_repo": "Snowflake/AgentWorldModel-1K",
|
| 5 |
-
"source_revision": "dde80a0283fe781bdc51656bce57063dc5650213",
|
| 6 |
-
"source_record": "gen_tasks.jsonl#scenario=accounting_1;tasks[1]",
|
| 7 |
-
"source_instruction_sha256": "a08b48d978d8a70cfea5c6e871d079622fc99ac8438fb38d6d6816bdfa399c99",
|
| 8 |
-
"original_limits": null,
|
| 9 |
-
"adapter_limits": {
|
| 10 |
-
"episode_seconds": 600,
|
| 11 |
-
"cpus": 1,
|
| 12 |
-
"memory_mb": 2048,
|
| 13 |
-
"max_context_length": 32768,
|
| 14 |
-
"max_completion_tokens": 32768
|
| 15 |
-
},
|
| 16 |
-
"interface": {
|
| 17 |
-
"schema_sha256": "10993deaaa8553929fa0b3b6bf3c1ad100baaaf9ff10ae8ed139a8ec4279a3c4",
|
| 18 |
-
"ops": [
|
| 19 |
-
"call",
|
| 20 |
-
"finish"
|
| 21 |
-
],
|
| 22 |
-
"business_tools": "Unchanged original FastApiMCP 0.4.0 operation names and argument schemas",
|
| 23 |
-
"shell": false,
|
| 24 |
-
"reset": "Fixed task_id, fresh original seed copy, no random task substitution",
|
| 25 |
-
"reward": "0 or 1 from original pure-code state verifier at finish; terminal immutable"
|
| 26 |
-
},
|
| 27 |
-
"tool_count": 27,
|
| 28 |
-
"original_files_sha256": {
|
| 29 |
-
"original_api.py": "57362b907a2d454bbd29b95dfebb7d84207ce9d7e22533eaf54853ee4fb84990",
|
| 30 |
-
"original_verifier.py": "3cd0d63022caa900e32bda0b0d3ae5c9948ce3c195b77ba1906c7ddebea9c58b",
|
| 31 |
-
"initial.db": "8ad2959536e44caba47bcbeca9018e47e7157783194d19b429aa8f22a60f4771",
|
| 32 |
-
"SOURCE.json": "3a1cc59eece46232d3ebb39df3cbfedd0625ab85bcf5e1d6cb090ea6ecec0e58"
|
| 33 |
-
},
|
| 34 |
-
"license": "CC-BY-4.0"
|
| 35 |
-
}
|
| 36 |
-
]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
components/awm/awm-requirements.lock
DELETED
|
@@ -1,44 +0,0 @@
|
|
| 1 |
-
annotated-doc==0.0.5 --hash=sha256:117bac03a25ede5df5440e855b32d556049ca169ead221505badf432fed4b101
|
| 2 |
-
annotated-types==0.8.0 --hash=sha256:f072f4d804ea359e4eaf198b1af7a8b0943881a87f31bb764f8bf219bb9419e0
|
| 3 |
-
anyio==4.15.1 --hash=sha256:6152fdbbf9a77fdec97731721bebf7c4c44f7c29b424b0065826173efc7ed101
|
| 4 |
-
attrs==26.1.0 --hash=sha256:c647aa4a12dfbad9333ca4e71fe62ddc36f4e63b2d260a37a8b83d2f043ac309
|
| 5 |
-
certifi==2026.7.22 --hash=sha256:62f22742b58a1a33014a2b6b706588a8d7e2a88ae7bd1a6ebe8c992928483775
|
| 6 |
-
cffi==2.1.1 --hash=sha256:c1453022f490d2459a11819d83ad1d586e9ff65a12ac3e705ffebd46d3685dcf
|
| 7 |
-
charset-normalizer==3.5.2 --hash=sha256:3d31298449090ab8d47b7b1b2a555ff73cac7ed438a08b7ac160980c7ebed649
|
| 8 |
-
click==8.5.0 --hash=sha256:255bc9599cf7748b4b1a446ccc735421bd08a2ae529a8b88597d3de5664ee360
|
| 9 |
-
cryptography==50.0.2 --hash=sha256:630ebfea3bf689d075f82316324ff7433dc447fe6bc1bfc76524b74b4a9567d2
|
| 10 |
-
fastapi==0.115.12 --hash=sha256:e94613d6c05e27be7ffebdd6ea5f388112e5e430c8f7d6494a9d1d88d43e814d
|
| 11 |
-
fastapi-mcp==0.4.0 --hash=sha256:d4a3fe7966af24d44e4b412720561c95eb12bed999a4443a88221834b3b15aec
|
| 12 |
-
greenlet==3.2.5 --hash=sha256:45fcea7b697b91290b36eafc12fff479aca6ba6500d98ef6f34d5634c7119cbe
|
| 13 |
-
h11==0.16.0 --hash=sha256:63cf8bbe7522de3bf65932fda1d9c2772064ffb3dae62d55932da54b31cb6c86
|
| 14 |
-
httpcore==1.0.9 --hash=sha256:2d400746a40668fc9dec9810239072b40b4484b640a8c38fd654a024c7a1bf55
|
| 15 |
-
httpx==0.28.1 --hash=sha256:d909fcccc110f8c7faf814ca82a9a4d816bc5a6dbfea25d6591d6985b8ba59ad
|
| 16 |
-
httpx-sse==0.4.3 --hash=sha256:0ac1c9fe3c0afad2e0ebb25a934a59f4c7823b60792691f779fad2c5568830fc
|
| 17 |
-
idna==3.20 --hash=sha256:ab7ae7122974553370f0bdb919e1a960b2cd1bc1ef0276416d896db81c14582c
|
| 18 |
-
jsonschema==4.26.0 --hash=sha256:d489f15263b8d200f8387e64b4c3a75f06629559fb73deb8fdfb525f2dab50ce
|
| 19 |
-
jsonschema-specifications==2025.9.1 --hash=sha256:98802fee3a11ee76ecaca44429fda8a41bff98b00a0f2838151b113f210cc6fe
|
| 20 |
-
markdown-it-py==4.2.0 --hash=sha256:9f7ebbcd14fe59494226453aed97c1070d83f8d24b6fc3a3bcf9a38092641c4a
|
| 21 |
-
mcp==1.26.0 --hash=sha256:904a21c33c25aa98ddbeb47273033c435e595bbacfdb177f4bd87f6dceebe1ca
|
| 22 |
-
mdurl==0.1.2 --hash=sha256:84008a41e51615a49fc9966191ff91509e3c40b939176e643fd50a5c2196b8f8
|
| 23 |
-
pycparser==3.11 --hash=sha256:51d5a8ba2be0bbe440b99d2112604c95bbbc3c2748a64260186c541e1729cd80
|
| 24 |
-
pydantic==2.12.5 --hash=sha256:e561593fccf61e8a20fc46dfc2dfe075b8be7d0188df33f221ad1f0139180f9d
|
| 25 |
-
pydantic_core==2.41.5 --hash=sha256:eceb81a8d74f9267ef4081e246ffd6d129da5d87e37a77c9bde550cb04870c1c
|
| 26 |
-
pydantic-settings==2.15.0 --hash=sha256:0ba092c291c94baceb5eff768aa0d56400a457585bc0175925a5a5510303da42
|
| 27 |
-
Pygments==2.21.0 --hash=sha256:2363c69b61c4a97c838da3b130dcd6468f4848992b21a82f2a63ec34377137d9
|
| 28 |
-
PyJWT==2.15.1 --hash=sha256:42d59d631f7768a1028a64c7ff581a9bf7519804daf91fc5b6c56e30eec5e193
|
| 29 |
-
python-dotenv==1.2.4 --hash=sha256:42269a8a5b3fd54ffa6f3d84b18abed50064717576b4ecf03dc4a55d8aa04fdc
|
| 30 |
-
python-multipart==0.0.32 --hash=sha256:ff6d3f776f16878c894e52e107296ffc890e913c611b1a4ec6c44e2821fe2e23
|
| 31 |
-
referencing==0.37.0 --hash=sha256:381329a9f99628c9069361716891d34ad94af76e461dcb0335825aecc7692231
|
| 32 |
-
requests==2.34.2 --hash=sha256:2a0d60c172f83ac6ab31e4554906c0f3b3588d37b5cb939b1c061f4907e278e0
|
| 33 |
-
rich==15.0.0 --hash=sha256:33bd4ef74232fb73fe9279a257718407f169c09b78a87ad3d296f548e27de0bb
|
| 34 |
-
rpds-py==2026.9.1 --hash=sha256:addeda51556dac7c1a2f14cda62db8b621cd12afba3091d03a96c72932387eab
|
| 35 |
-
shellingham==1.5.4 --hash=sha256:7ecfff8f2fd72616f7481040475a65b2bf8af90a56c89140852d1120324e8686
|
| 36 |
-
SQLAlchemy==2.0.41 --hash=sha256:6145afea51ff0af7f2564a05fa95eb46f542919e6523729663a5d285ecb3cf5e
|
| 37 |
-
sse-starlette==3.0.3 --hash=sha256:af5bf5a6f3933df1d9c7f8539633dc8444ca6a97ab2e2a7cd3b6e431ac03a431
|
| 38 |
-
starlette==0.46.2 --hash=sha256:595633ce89f8ffa71a015caed34a5b2dc1c0cdb3f0f1fbd1e69339cf2abeec35
|
| 39 |
-
tomli==2.5.0 --hash=sha256:6cf74416bdc94ae458b14e37286c1073081850ac8459a00d0c5efef5d44294c6
|
| 40 |
-
typer==0.27.3 --hash=sha256:e50022f28b82a86313e54501317a1db64bf8f8d036ff8cfe5ca7e47675454aff
|
| 41 |
-
typing_extensions==4.16.0 --hash=sha256:481caa481374e813c1b176ada14e97f1f67a4539ce9cfeb3f350d78d6370c2e8
|
| 42 |
-
typing-inspection==0.4.4 --hash=sha256:65b8397ba37ccbce054456aaccddfc91e6e3083c92824df348d96ca832f3f147
|
| 43 |
-
urllib3==2.8.0 --hash=sha256:0cf3cae568d36aa9576b28dfb35f11328f1cb974ca7647d9475ebb86c75ac6e3
|
| 44 |
-
uvicorn==0.54.0 --hash=sha256:505bdb0f318731d45f1f712071fc781a8981f6847a31c902c9f5e652d4f67faf
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
components/awm/config.json
DELETED
|
@@ -1,15 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"tasks": [
|
| 3 |
-
{
|
| 4 |
-
"task_id": "awm-accounting-1-invoice",
|
| 5 |
-
"split": "train",
|
| 6 |
-
"original_sha256": {
|
| 7 |
-
"original_api.py": "57362b907a2d454bbd29b95dfebb7d84207ce9d7e22533eaf54853ee4fb84990",
|
| 8 |
-
"original_verifier.py": "3cd0d63022caa900e32bda0b0d3ae5c9948ce3c195b77ba1906c7ddebea9c58b",
|
| 9 |
-
"initial.db": "8ad2959536e44caba47bcbeca9018e47e7157783194d19b429aa8f22a60f4771",
|
| 10 |
-
"SOURCE.json": "3a1cc59eece46232d3ebb39df3cbfedd0625ab85bcf5e1d6cb090ea6ecec0e58"
|
| 11 |
-
},
|
| 12 |
-
"timeout_seconds": 600
|
| 13 |
-
}
|
| 14 |
-
]
|
| 15 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
components/awm/private/tasks/awm-accounting-1-invoice/SOURCE.json
DELETED
|
@@ -1,11 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"repo": "Snowflake/AgentWorldModel-1K",
|
| 3 |
-
"revision": "dde80a0283fe781bdc51656bce57063dc5650213",
|
| 4 |
-
"scenario": "accounting_1",
|
| 5 |
-
"task_idx": 1,
|
| 6 |
-
"task": "Create an invoice for customer 'Acme Design Studio' dated 2025-01-05 with due_date 2025-02-04 containing two line_items ('Logo redesign' quantity 1 unit_price 1200 with no discount and 'Brand guideline document' quantity 1 unit_price 800 with a 10% discount), assign it to department 'Design', and mark its tax_category as 'Standard Sales Tax 8.5%'.",
|
| 7 |
-
"task_id": "awm-accounting-1-invoice",
|
| 8 |
-
"license": "CC-BY-4.0",
|
| 9 |
-
"split": "train",
|
| 10 |
-
"original_format": "FastAPI through FastApiMCP 0.4.0"
|
| 11 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
components/awm/private/tasks/awm-accounting-1-invoice/initial.db
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:8ad2959536e44caba47bcbeca9018e47e7157783194d19b429aa8f22a60f4771
|
| 3 |
-
size 331776
|
|
|
|
|
|
|
|
|
|
|
|
components/awm/private/tasks/awm-accounting-1-invoice/original_api.py
DELETED
|
@@ -1,1767 +0,0 @@
|
|
| 1 |
-
from fastapi import FastAPI, Query, Path, Body
|
| 2 |
-
from pydantic import BaseModel, Field, ConfigDict
|
| 3 |
-
from typing import Optional, List, Dict
|
| 4 |
-
from datetime import datetime, date
|
| 5 |
-
import os
|
| 6 |
-
from sqlalchemy import (
|
| 7 |
-
create_engine,
|
| 8 |
-
Column,
|
| 9 |
-
Integer,
|
| 10 |
-
String,
|
| 11 |
-
DateTime,
|
| 12 |
-
Date,
|
| 13 |
-
Float,
|
| 14 |
-
Text,
|
| 15 |
-
ForeignKey,
|
| 16 |
-
CheckConstraint,
|
| 17 |
-
Index,
|
| 18 |
-
)
|
| 19 |
-
from sqlalchemy.orm import declarative_base, relationship, sessionmaker
|
| 20 |
-
|
| 21 |
-
database_url = os.getenv("DATABASE_PATH", "sqlite:///outputs/databases/zenledger_small_business_accounting_suite.db")
|
| 22 |
-
engine = create_engine(database_url, future=True)
|
| 23 |
-
SessionLocal = sessionmaker(bind=engine, autoflush=False, autocommit=False, future=True)
|
| 24 |
-
Base = declarative_base()
|
| 25 |
-
|
| 26 |
-
class User(Base):
|
| 27 |
-
__tablename__ = "users"
|
| 28 |
-
id = Column(Integer, primary_key=True)
|
| 29 |
-
username = Column(Text, unique=True, nullable=False)
|
| 30 |
-
email = Column(Text, unique=True, nullable=False)
|
| 31 |
-
full_name = Column(Text)
|
| 32 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 33 |
-
updated_at = Column(DateTime)
|
| 34 |
-
|
| 35 |
-
class Department(Base):
|
| 36 |
-
__tablename__ = "departments"
|
| 37 |
-
id = Column(Integer, primary_key=True)
|
| 38 |
-
name = Column(Text, unique=True, nullable=False)
|
| 39 |
-
description = Column(Text)
|
| 40 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 41 |
-
updated_at = Column(DateTime)
|
| 42 |
-
|
| 43 |
-
class TaxCategory(Base):
|
| 44 |
-
__tablename__ = "tax_categories"
|
| 45 |
-
id = Column(Integer, primary_key=True)
|
| 46 |
-
name = Column(Text, unique=True, nullable=False)
|
| 47 |
-
description = Column(Text)
|
| 48 |
-
rate = Column(Float, nullable=False)
|
| 49 |
-
is_compound = Column(Integer, nullable=False, default=0)
|
| 50 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 51 |
-
updated_at = Column(DateTime)
|
| 52 |
-
|
| 53 |
-
class PaymentTerm(Base):
|
| 54 |
-
__tablename__ = "payment_terms"
|
| 55 |
-
id = Column(Integer, primary_key=True)
|
| 56 |
-
name = Column(Text, unique=True, nullable=False)
|
| 57 |
-
days = Column(Integer, nullable=False)
|
| 58 |
-
description = Column(Text)
|
| 59 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 60 |
-
updated_at = Column(DateTime)
|
| 61 |
-
|
| 62 |
-
class Customer(Base):
|
| 63 |
-
__tablename__ = "customers"
|
| 64 |
-
id = Column(Integer, primary_key=True)
|
| 65 |
-
name = Column(Text, unique=True, nullable=False)
|
| 66 |
-
billing_email = Column(Text)
|
| 67 |
-
payment_terms_id = Column(Integer, ForeignKey("payment_terms.id"))
|
| 68 |
-
default_tax_category_id = Column(Integer, ForeignKey("tax_categories.id"))
|
| 69 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 70 |
-
updated_at = Column(DateTime)
|
| 71 |
-
|
| 72 |
-
class Account(Base):
|
| 73 |
-
__tablename__ = "accounts"
|
| 74 |
-
id = Column(Integer, primary_key=True)
|
| 75 |
-
name = Column(Text, unique=True, nullable=False)
|
| 76 |
-
code = Column(Text)
|
| 77 |
-
type = Column(Text, nullable=False)
|
| 78 |
-
sub_type = Column(Text)
|
| 79 |
-
is_active = Column(Integer, nullable=False, default=1)
|
| 80 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 81 |
-
updated_at = Column(DateTime)
|
| 82 |
-
|
| 83 |
-
class Vendor(Base):
|
| 84 |
-
__tablename__ = "vendors"
|
| 85 |
-
id = Column(Integer, primary_key=True)
|
| 86 |
-
name = Column(Text, unique=True, nullable=False)
|
| 87 |
-
contact_email = Column(Text)
|
| 88 |
-
payment_terms_id = Column(Integer, ForeignKey("payment_terms.id"))
|
| 89 |
-
default_expense_category_id = Column(Integer, ForeignKey("accounts.id"))
|
| 90 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 91 |
-
updated_at = Column(DateTime)
|
| 92 |
-
|
| 93 |
-
class BankAccount(Base):
|
| 94 |
-
__tablename__ = "bank_accounts"
|
| 95 |
-
id = Column(Integer, primary_key=True)
|
| 96 |
-
name = Column(Text, unique=True, nullable=False)
|
| 97 |
-
institution_name = Column(Text)
|
| 98 |
-
account_number_masked = Column(Text)
|
| 99 |
-
account_id = Column(Integer, ForeignKey("accounts.id"), nullable=False)
|
| 100 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 101 |
-
updated_at = Column(DateTime)
|
| 102 |
-
|
| 103 |
-
class Invoice(Base):
|
| 104 |
-
__tablename__ = "invoices"
|
| 105 |
-
id = Column(Integer, primary_key=True)
|
| 106 |
-
invoice_number = Column(Text, unique=True, nullable=False)
|
| 107 |
-
customer_id = Column(Integer, ForeignKey("customers.id"), nullable=False)
|
| 108 |
-
department_id = Column(Integer, ForeignKey("departments.id"))
|
| 109 |
-
tax_category_id = Column(Integer, ForeignKey("tax_categories.id"))
|
| 110 |
-
invoice_date = Column(Date, nullable=False)
|
| 111 |
-
due_date = Column(Date, nullable=False)
|
| 112 |
-
currency = Column(Text, nullable=False, default="USD")
|
| 113 |
-
status = Column(Text, nullable=False)
|
| 114 |
-
subtotal = Column(Float, nullable=False, default=0.0)
|
| 115 |
-
tax_amount = Column(Float, nullable=False, default=0.0)
|
| 116 |
-
total = Column(Float, nullable=False, default=0.0)
|
| 117 |
-
balance_due = Column(Float, nullable=False, default=0.0)
|
| 118 |
-
payment_terms_id = Column(Integer, ForeignKey("payment_terms.id"))
|
| 119 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 120 |
-
updated_at = Column(DateTime)
|
| 121 |
-
|
| 122 |
-
class InvoiceLineItem(Base):
|
| 123 |
-
__tablename__ = "invoice_line_items"
|
| 124 |
-
id = Column(Integer, primary_key=True)
|
| 125 |
-
invoice_id = Column(Integer, ForeignKey("invoices.id", ondelete="CASCADE"), nullable=False)
|
| 126 |
-
description = Column(Text, nullable=False)
|
| 127 |
-
quantity = Column(Float, nullable=False)
|
| 128 |
-
unit_price = Column(Float, nullable=False)
|
| 129 |
-
discount_percent = Column(Float, nullable=False, default=0.0)
|
| 130 |
-
line_subtotal = Column(Float, nullable=False, default=0.0)
|
| 131 |
-
tax_amount = Column(Float, nullable=False, default=0.0)
|
| 132 |
-
total = Column(Float, nullable=False, default=0.0)
|
| 133 |
-
revenue_account_id = Column(Integer, ForeignKey("accounts.id"))
|
| 134 |
-
department_id = Column(Integer, ForeignKey("departments.id"))
|
| 135 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 136 |
-
updated_at = Column(DateTime)
|
| 137 |
-
|
| 138 |
-
class Payment(Base):
|
| 139 |
-
__tablename__ = "payments"
|
| 140 |
-
id = Column(Integer, primary_key=True)
|
| 141 |
-
customer_id = Column(Integer, ForeignKey("customers.id"), nullable=False)
|
| 142 |
-
payment_date = Column(Date, nullable=False)
|
| 143 |
-
settlement_date = Column(Date)
|
| 144 |
-
amount = Column(Float, nullable=False)
|
| 145 |
-
currency = Column(Text, nullable=False, default="USD")
|
| 146 |
-
method = Column(Text, nullable=False)
|
| 147 |
-
reference = Column(Text)
|
| 148 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 149 |
-
updated_at = Column(DateTime)
|
| 150 |
-
|
| 151 |
-
class PaymentApplication(Base):
|
| 152 |
-
__tablename__ = "payment_applications"
|
| 153 |
-
id = Column(Integer, primary_key=True)
|
| 154 |
-
payment_id = Column(Integer, ForeignKey("payments.id", ondelete="CASCADE"), nullable=False)
|
| 155 |
-
invoice_id = Column(Integer, ForeignKey("invoices.id", ondelete="CASCADE"), nullable=False)
|
| 156 |
-
amount = Column(Float, nullable=False)
|
| 157 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 158 |
-
updated_at = Column(DateTime)
|
| 159 |
-
|
| 160 |
-
class Bill(Base):
|
| 161 |
-
__tablename__ = "bills"
|
| 162 |
-
id = Column(Integer, primary_key=True)
|
| 163 |
-
bill_number = Column(Text)
|
| 164 |
-
vendor_id = Column(Integer, ForeignKey("vendors.id"), nullable=False)
|
| 165 |
-
bill_date = Column(Date, nullable=False)
|
| 166 |
-
due_date = Column(Date)
|
| 167 |
-
currency = Column(Text, nullable=False, default="USD")
|
| 168 |
-
amount = Column(Float, nullable=False)
|
| 169 |
-
description = Column(Text)
|
| 170 |
-
department_id = Column(Integer, ForeignKey("departments.id"))
|
| 171 |
-
reimbursement_status = Column(Text, nullable=False)
|
| 172 |
-
payment_terms_id = Column(Integer, ForeignKey("payment_terms.id"))
|
| 173 |
-
status = Column(Text, nullable=False, default="open")
|
| 174 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 175 |
-
updated_at = Column(DateTime)
|
| 176 |
-
|
| 177 |
-
class RecurringExpense(Base):
|
| 178 |
-
__tablename__ = "recurring_expenses"
|
| 179 |
-
id = Column(Integer, primary_key=True)
|
| 180 |
-
name = Column(Text, nullable=False)
|
| 181 |
-
vendor_id = Column(Integer, ForeignKey("vendors.id"))
|
| 182 |
-
amount = Column(Float, nullable=False)
|
| 183 |
-
expense_account_id = Column(Integer, ForeignKey("accounts.id"), nullable=False)
|
| 184 |
-
department_id = Column(Integer, ForeignKey("departments.id"))
|
| 185 |
-
frequency = Column(Text, nullable=False)
|
| 186 |
-
next_run_date = Column(Date, nullable=False)
|
| 187 |
-
end_date = Column(Date)
|
| 188 |
-
is_active = Column(Integer, nullable=False, default=1)
|
| 189 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 190 |
-
updated_at = Column(DateTime)
|
| 191 |
-
|
| 192 |
-
class BankTransaction(Base):
|
| 193 |
-
__tablename__ = "bank_transactions"
|
| 194 |
-
id = Column(Integer, primary_key=True)
|
| 195 |
-
bank_account_id = Column(Integer, ForeignKey("bank_accounts.id"), nullable=False)
|
| 196 |
-
transaction_date = Column(Date, nullable=False)
|
| 197 |
-
posted_date = Column(Date)
|
| 198 |
-
description = Column(Text, nullable=False)
|
| 199 |
-
amount = Column(Float, nullable=False)
|
| 200 |
-
external_id = Column(Text)
|
| 201 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 202 |
-
updated_at = Column(DateTime)
|
| 203 |
-
|
| 204 |
-
class JournalEntry(Base):
|
| 205 |
-
__tablename__ = "journal_entries"
|
| 206 |
-
id = Column(Integer, primary_key=True)
|
| 207 |
-
entry_date = Column(Date, nullable=False)
|
| 208 |
-
description = Column(Text)
|
| 209 |
-
department_id = Column(Integer, ForeignKey("departments.id"))
|
| 210 |
-
source = Column(Text)
|
| 211 |
-
source_id = Column(Integer)
|
| 212 |
-
created_by_user_id = Column(Integer, ForeignKey("users.id"))
|
| 213 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 214 |
-
updated_at = Column(DateTime)
|
| 215 |
-
|
| 216 |
-
class JournalEntryLine(Base):
|
| 217 |
-
__tablename__ = "journal_entry_lines"
|
| 218 |
-
id = Column(Integer, primary_key=True)
|
| 219 |
-
journal_entry_id = Column(Integer, ForeignKey("journal_entries.id", ondelete="CASCADE"), nullable=False)
|
| 220 |
-
account_id = Column(Integer, ForeignKey("accounts.id"), nullable=False)
|
| 221 |
-
department_id = Column(Integer, ForeignKey("departments.id"))
|
| 222 |
-
description = Column(Text)
|
| 223 |
-
debit = Column(Float, nullable=False, default=0.0)
|
| 224 |
-
credit = Column(Float, nullable=False, default=0.0)
|
| 225 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 226 |
-
updated_at = Column(DateTime)
|
| 227 |
-
|
| 228 |
-
class BankTransactionJournalLink(Base):
|
| 229 |
-
__tablename__ = "bank_transaction_journal_links"
|
| 230 |
-
id = Column(Integer, primary_key=True)
|
| 231 |
-
bank_transaction_id = Column(Integer, ForeignKey("bank_transactions.id", ondelete="CASCADE"), nullable=False)
|
| 232 |
-
journal_entry_id = Column(Integer, ForeignKey("journal_entries.id", ondelete="CASCADE"), nullable=False)
|
| 233 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 234 |
-
|
| 235 |
-
class RecurringInvoice(Base):
|
| 236 |
-
__tablename__ = "recurring_invoices"
|
| 237 |
-
id = Column(Integer, primary_key=True)
|
| 238 |
-
customer_id = Column(Integer, ForeignKey("customers.id"), nullable=False)
|
| 239 |
-
name = Column(Text, nullable=False)
|
| 240 |
-
description = Column(Text)
|
| 241 |
-
quantity = Column(Float, nullable=False)
|
| 242 |
-
unit_price = Column(Float, nullable=False)
|
| 243 |
-
discount_percent = Column(Float, nullable=False, default=0.0)
|
| 244 |
-
frequency = Column(Text, nullable=False)
|
| 245 |
-
next_run_date = Column(Date, nullable=False)
|
| 246 |
-
end_date = Column(Date)
|
| 247 |
-
payment_terms_id = Column(Integer, ForeignKey("payment_terms.id"))
|
| 248 |
-
tax_category_id = Column(Integer, ForeignKey("tax_categories.id"))
|
| 249 |
-
department_id = Column(Integer, ForeignKey("departments.id"))
|
| 250 |
-
currency = Column(Text, nullable=False, default="USD")
|
| 251 |
-
is_active = Column(Integer, nullable=False, default=1)
|
| 252 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 253 |
-
updated_at = Column(DateTime)
|
| 254 |
-
|
| 255 |
-
class AccountingPeriod(Base):
|
| 256 |
-
__tablename__ = "accounting_periods"
|
| 257 |
-
id = Column(Integer, primary_key=True)
|
| 258 |
-
start_date = Column(Date, nullable=False)
|
| 259 |
-
end_date = Column(Date, nullable=False)
|
| 260 |
-
close_date = Column(Date)
|
| 261 |
-
is_locked = Column(Integer, nullable=False, default=0)
|
| 262 |
-
created_at = Column(DateTime, default=datetime.utcnow)
|
| 263 |
-
updated_at = Column(DateTime)
|
| 264 |
-
|
| 265 |
-
Index("idx_users_email", User.email)
|
| 266 |
-
Index("idx_departments_name", Department.name, unique=True)
|
| 267 |
-
Index("idx_tax_categories_name", TaxCategory.name, unique=True)
|
| 268 |
-
Index("idx_payment_terms_name", PaymentTerm.name, unique=True)
|
| 269 |
-
Index("idx_customers_name", Customer.name, unique=True)
|
| 270 |
-
Index("idx_customers_payment_terms_id", Customer.payment_terms_id)
|
| 271 |
-
Index("idx_customers_tax_category_id", Customer.default_tax_category_id)
|
| 272 |
-
Index("idx_vendors_name", Vendor.name, unique=True)
|
| 273 |
-
Index("idx_vendors_payment_terms_id", Vendor.payment_terms_id)
|
| 274 |
-
Index("idx_vendors_expense_category_id", Vendor.default_expense_category_id)
|
| 275 |
-
Index("idx_accounts_name", Account.name, unique=True)
|
| 276 |
-
Index("idx_accounts_type", Account.type)
|
| 277 |
-
Index("idx_bank_accounts_name", BankAccount.name, unique=True)
|
| 278 |
-
Index("idx_bank_accounts_account_id", BankAccount.account_id)
|
| 279 |
-
Index("idx_invoices_invoice_number", Invoice.invoice_number, unique=True)
|
| 280 |
-
Index("idx_invoices_customer_id", Invoice.customer_id)
|
| 281 |
-
Index("idx_invoices_department_id", Invoice.department_id)
|
| 282 |
-
Index("idx_invoices_tax_category_id", Invoice.tax_category_id)
|
| 283 |
-
Index("idx_invoices_invoice_date", Invoice.invoice_date)
|
| 284 |
-
Index("idx_invoice_line_items_invoice_id", InvoiceLineItem.invoice_id)
|
| 285 |
-
Index("idx_invoice_line_items_department_id", InvoiceLineItem.department_id)
|
| 286 |
-
Index("idx_payments_customer_id", Payment.customer_id)
|
| 287 |
-
Index("idx_payments_payment_date", Payment.payment_date)
|
| 288 |
-
Index("idx_payment_applications_payment_id", PaymentApplication.payment_id)
|
| 289 |
-
Index("idx_payment_applications_invoice_id", PaymentApplication.invoice_id)
|
| 290 |
-
Index("idx_bills_vendor_id", Bill.vendor_id)
|
| 291 |
-
Index("idx_bills_department_id", Bill.department_id)
|
| 292 |
-
Index("idx_bills_bill_date", Bill.bill_date)
|
| 293 |
-
Index("idx_recurring_expenses_vendor_id", RecurringExpense.vendor_id)
|
| 294 |
-
Index("idx_recurring_expenses_next_run_date", RecurringExpense.next_run_date)
|
| 295 |
-
Index("idx_recurring_expenses_department_id", RecurringExpense.department_id)
|
| 296 |
-
Index("idx_bank_transactions_account_id", BankTransaction.bank_account_id)
|
| 297 |
-
Index("idx_bank_transactions_date", BankTransaction.transaction_date)
|
| 298 |
-
Index("idx_journal_entries_entry_date", JournalEntry.entry_date)
|
| 299 |
-
Index("idx_journal_entries_department_id", JournalEntry.department_id)
|
| 300 |
-
Index("idx_journal_entry_lines_entry_id", JournalEntryLine.journal_entry_id)
|
| 301 |
-
Index("idx_journal_entry_lines_account_id", JournalEntryLine.account_id)
|
| 302 |
-
Index("idx_journal_entry_lines_department_id", JournalEntryLine.department_id)
|
| 303 |
-
Index("idx_bt_journal_links_bt_id", BankTransactionJournalLink.bank_transaction_id)
|
| 304 |
-
Index("idx_bt_journal_links_je_id", BankTransactionJournalLink.journal_entry_id)
|
| 305 |
-
Index("idx_recurring_invoices_customer_id", RecurringInvoice.customer_id)
|
| 306 |
-
Index("idx_recurring_invoices_next_run_date", RecurringInvoice.next_run_date)
|
| 307 |
-
Index("idx_recurring_invoices_department_id", RecurringInvoice.department_id)
|
| 308 |
-
Index("idx_accounting_periods_start_end", AccountingPeriod.start_date, AccountingPeriod.end_date)
|
| 309 |
-
Index("idx_accounting_periods_is_locked", AccountingPeriod.is_locked)
|
| 310 |
-
|
| 311 |
-
Base.metadata.create_all(engine)
|
| 312 |
-
|
| 313 |
-
app = FastAPI(title="ZenLedger Small Business Accounting Suite API", version="1.0.0")
|
| 314 |
-
|
| 315 |
-
class CustomerCreateRequest(BaseModel):
|
| 316 |
-
name: str = Field(..., description="Customer legal or display name (must be unique)", example="Acme Design Studio")
|
| 317 |
-
billing_email: Optional[str] = Field(None, description="Primary billing email address for invoices", example="billing@acmedesign.com")
|
| 318 |
-
payment_terms_id: Optional[int] = Field(None, description="ID of payment_terms row to use as default terms", example=2)
|
| 319 |
-
default_tax_category_id: Optional[int] = Field(None, description="ID of tax_categories row used as default customer tax", example=1)
|
| 320 |
-
|
| 321 |
-
class CustomerResponse(BaseModel):
|
| 322 |
-
model_config = ConfigDict(from_attributes=True)
|
| 323 |
-
id: int = Field(..., description="Unique customer identifier", example=10)
|
| 324 |
-
name: str = Field(..., description="Customer name", example="Acme Design Studio")
|
| 325 |
-
billing_email: Optional[str] = Field(None, description="Customer billing email", example="billing@acmedesign.com")
|
| 326 |
-
payment_terms_id: Optional[int] = Field(None, description="Linked payment_terms.id or null", example=3)
|
| 327 |
-
default_tax_category_id: Optional[int] = Field(None, description="Linked tax_categories.id or null", example=1)
|
| 328 |
-
created_at: Optional[datetime] = Field(None, description="Timestamp when customer was created (ISO 8601)", example="2025-01-04T10:15:23Z")
|
| 329 |
-
updated_at: Optional[datetime] = Field(None, description="Timestamp for last update or null", example=None)
|
| 330 |
-
|
| 331 |
-
class CustomersListResponse(BaseModel):
|
| 332 |
-
customers: List[CustomerResponse] = Field(..., description="List of customers", example=[])
|
| 333 |
-
|
| 334 |
-
class PaymentTermResponse(BaseModel):
|
| 335 |
-
model_config = ConfigDict(from_attributes=True)
|
| 336 |
-
id: int = Field(..., description="Payment terms ID", example=3)
|
| 337 |
-
name: str = Field(..., description="Name of payment terms", example="Net 30")
|
| 338 |
-
days: int = Field(..., description="Number of days from invoice date to due date", example=30)
|
| 339 |
-
description: Optional[str] = Field(None, description="Optional description", example="Payment due 30 days from invoice date")
|
| 340 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2024-01-01T00:00:00Z")
|
| 341 |
-
updated_at: Optional[datetime] = Field(None, description="Last update timestamp", example=None)
|
| 342 |
-
|
| 343 |
-
class PaymentTermsListResponse(BaseModel):
|
| 344 |
-
payment_terms: List[PaymentTermResponse] = Field(..., description="List of payment terms", example=[])
|
| 345 |
-
|
| 346 |
-
class TaxCategoryResponse(BaseModel):
|
| 347 |
-
model_config = ConfigDict(from_attributes=True)
|
| 348 |
-
id: int = Field(..., description="Tax category ID", example=1)
|
| 349 |
-
name: str = Field(..., description="Tax category name", example="Standard Sales Tax 8.5%")
|
| 350 |
-
description: Optional[str] = Field(None, description="Optional description of when this tax applies", example="Standard local sales tax")
|
| 351 |
-
rate: float = Field(..., description="Tax rate as decimal (e.g., 0.085 for 8.5%)", example=0.085)
|
| 352 |
-
is_compound: bool = Field(..., description="True if tax is compounded with other taxes", example=False)
|
| 353 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2024-01-01T00:00:00Z")
|
| 354 |
-
updated_at: Optional[datetime] = Field(None, description="Last update timestamp", example=None)
|
| 355 |
-
|
| 356 |
-
class TaxCategoriesListResponse(BaseModel):
|
| 357 |
-
tax_categories: List[TaxCategoryResponse] = Field(..., description="List of tax categories", example=[])
|
| 358 |
-
|
| 359 |
-
class DepartmentResponse(BaseModel):
|
| 360 |
-
model_config = ConfigDict(from_attributes=True)
|
| 361 |
-
id: int = Field(..., description="Department ID", example=2)
|
| 362 |
-
name: str = Field(..., description="Department name", example="Design")
|
| 363 |
-
description: Optional[str] = Field(None, description="Optional department description", example="Design and creative services")
|
| 364 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2024-01-01T00:00:00Z")
|
| 365 |
-
updated_at: Optional[datetime] = Field(None, description="Last update timestamp", example=None)
|
| 366 |
-
|
| 367 |
-
class DepartmentsListResponse(BaseModel):
|
| 368 |
-
departments: List[DepartmentResponse] = Field(..., description="List of departments", example=[])
|
| 369 |
-
|
| 370 |
-
class AccountResponse(BaseModel):
|
| 371 |
-
model_config = ConfigDict(from_attributes=True)
|
| 372 |
-
id: int = Field(..., description="Account ID", example=50)
|
| 373 |
-
name: str = Field(..., description="Account name", example="Software Subscriptions")
|
| 374 |
-
code: Optional[str] = Field(None, description="Optional account code", example="6100")
|
| 375 |
-
type: str = Field(..., description="High-level account type", example="expense")
|
| 376 |
-
sub_type: Optional[str] = Field(None, description="Optional subtype classification", example="Operating Expense")
|
| 377 |
-
is_active: bool = Field(..., description="Whether account can be posted to", example=True)
|
| 378 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2024-01-01T00:00:00Z")
|
| 379 |
-
updated_at: Optional[datetime] = Field(None, description="Last update timestamp", example=None)
|
| 380 |
-
|
| 381 |
-
class AccountsListResponse(BaseModel):
|
| 382 |
-
accounts: List[AccountResponse] = Field(..., description="List of accounts", example=[])
|
| 383 |
-
|
| 384 |
-
class BankAccountResponse(BaseModel):
|
| 385 |
-
model_config = ConfigDict(from_attributes=True)
|
| 386 |
-
id: int = Field(..., description="Bank account ID", example=1)
|
| 387 |
-
name: str = Field(..., description="Display name for the bank account", example="Chase Business Checking ****1023")
|
| 388 |
-
institution_name: Optional[str] = Field(None, description="Financial institution name", example="Chase")
|
| 389 |
-
account_number_masked: Optional[str] = Field(None, description="Masked bank account number", example="****1023")
|
| 390 |
-
account_id: int = Field(..., description="Linked GL account ID", example=101)
|
| 391 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2024-01-01T00:00:00Z")
|
| 392 |
-
updated_at: Optional[datetime] = Field(None, description="Last update timestamp", example=None)
|
| 393 |
-
|
| 394 |
-
class BankAccountsListResponse(BaseModel):
|
| 395 |
-
bank_accounts: List[BankAccountResponse] = Field(..., description="List of bank accounts", example=[])
|
| 396 |
-
|
| 397 |
-
class InvoiceCreateRequest(BaseModel):
|
| 398 |
-
invoice_number: str = Field(..., description="Unique invoice number", example="INV-2025-001")
|
| 399 |
-
customer_id: int = Field(..., description="Customer ID that this invoice belongs to", example=10)
|
| 400 |
-
invoice_date: str = Field(..., description="Invoice date in ISO format YYYY-MM-DD", example="2025-01-05")
|
| 401 |
-
due_date: str = Field(..., description="Due date in ISO format YYYY-MM-DD", example="2025-02-04")
|
| 402 |
-
department_id: Optional[int] = Field(None, description="Department responsible for this invoice", example=2)
|
| 403 |
-
tax_category_id: Optional[int] = Field(None, description="Tax category applied at invoice level", example=1)
|
| 404 |
-
payment_terms_id: Optional[int] = Field(None, description="Payment terms to apply; defaults to customer terms if omitted", example=3)
|
| 405 |
-
currency: Optional[str] = Field("USD", description="Currency code, defaults to USD", example="USD")
|
| 406 |
-
status: Optional[str] = Field("draft", description="Initial status (draft or open)", example="open")
|
| 407 |
-
|
| 408 |
-
class InvoiceResponse(BaseModel):
|
| 409 |
-
model_config = ConfigDict(from_attributes=True)
|
| 410 |
-
id: int = Field(..., description="Invoice ID", example=1001)
|
| 411 |
-
invoice_number: str = Field(..., description="Unique invoice number", example="INV-2025-001")
|
| 412 |
-
customer_id: int = Field(..., description="Linked customer ID", example=10)
|
| 413 |
-
department_id: Optional[int] = Field(None, description="Linked department ID", example=2)
|
| 414 |
-
tax_category_id: Optional[int] = Field(None, description="Linked tax category ID", example=1)
|
| 415 |
-
invoice_date: date = Field(..., description="Invoice date", example="2025-01-05")
|
| 416 |
-
due_date: date = Field(..., description="Due date", example="2025-02-04")
|
| 417 |
-
currency: str = Field(..., description="Currency code", example="USD")
|
| 418 |
-
status: str = Field(..., description="Invoice status", example="open")
|
| 419 |
-
subtotal: float = Field(..., description="Sum of line_subtotals before tax", example=2000.0)
|
| 420 |
-
tax_amount: float = Field(..., description="Total tax applied to invoice", example=170.0)
|
| 421 |
-
total: float = Field(..., description="Invoice total including tax", example=2170.0)
|
| 422 |
-
balance_due: float = Field(..., description="Remaining balance due on invoice", example=2170.0)
|
| 423 |
-
payment_terms_id: Optional[int] = Field(None, description="Linked payment_terms ID", example=3)
|
| 424 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2025-01-05T09:00:00Z")
|
| 425 |
-
updated_at: Optional[datetime] = Field(None, description="Update timestamp", example=None)
|
| 426 |
-
|
| 427 |
-
class InvoiceLineItemCreateRequest(BaseModel):
|
| 428 |
-
invoice_id: int = Field(..., description="ID of the invoice this line belongs to", example=1001)
|
| 429 |
-
description: str = Field(..., description="Description of the product or service", example="Logo redesign")
|
| 430 |
-
quantity: float = Field(..., description="Quantity of units sold", example=1.0)
|
| 431 |
-
unit_price: float = Field(..., description="Price per unit", example=1200.0)
|
| 432 |
-
discount_percent: Optional[float] = Field(0.0, description="Discount percentage applied to this line", example=10.0)
|
| 433 |
-
revenue_account_id: Optional[int] = Field(None, description="Revenue account to credit for this line", example=400)
|
| 434 |
-
department_id: Optional[int] = Field(None, description="Department for this line; overrides invoice department", example=2)
|
| 435 |
-
|
| 436 |
-
class InvoiceLineItemResponse(BaseModel):
|
| 437 |
-
model_config = ConfigDict(from_attributes=True)
|
| 438 |
-
id: int = Field(..., description="Invoice line item ID", example=5001)
|
| 439 |
-
invoice_id: int = Field(..., description="Parent invoice ID", example=1001)
|
| 440 |
-
description: str = Field(..., description="Line item description", example="Logo redesign")
|
| 441 |
-
quantity: float = Field(..., description="Quantity", example=1.0)
|
| 442 |
-
unit_price: float = Field(..., description="Unit price", example=1200.0)
|
| 443 |
-
discount_percent: float = Field(..., description="Discount percent", example=0.0)
|
| 444 |
-
line_subtotal: float = Field(..., description="Subtotal before tax for this line", example=1200.0)
|
| 445 |
-
tax_amount: float = Field(..., description="Tax for this line", example=102.0)
|
| 446 |
-
total: float = Field(..., description="Total including tax for this line", example=1302.0)
|
| 447 |
-
revenue_account_id: Optional[int] = Field(None, description="Linked revenue account ID", example=400)
|
| 448 |
-
department_id: Optional[int] = Field(None, description="Linked department ID", example=2)
|
| 449 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2025-01-05T09:10:00Z")
|
| 450 |
-
updated_at: Optional[datetime] = Field(None, description="Update timestamp", example=None)
|
| 451 |
-
|
| 452 |
-
class InvoiceRecalculateTotalsResponse(BaseModel):
|
| 453 |
-
invoice_id: int = Field(..., description="Invoice ID", example=1001)
|
| 454 |
-
subtotal: float = Field(..., description="Updated subtotal", example=2000.0)
|
| 455 |
-
tax_amount: float = Field(..., description="Updated tax amount", example=170.0)
|
| 456 |
-
total: float = Field(..., description="Updated total", example=2170.0)
|
| 457 |
-
balance_due: float = Field(..., description="Updated balance due after payments", example=1270.0)
|
| 458 |
-
|
| 459 |
-
class InvoicesListItemResponse(BaseModel):
|
| 460 |
-
model_config = ConfigDict(from_attributes=True)
|
| 461 |
-
id: int = Field(..., description="Invoice ID", example=1001)
|
| 462 |
-
invoice_number: str = Field(..., description="Invoice number", example="INV-2025-001")
|
| 463 |
-
customer_id: int = Field(..., description="Customer ID", example=10)
|
| 464 |
-
invoice_date: date = Field(..., description="Invoice date", example="2025-01-05")
|
| 465 |
-
due_date: date = Field(..., description="Due date", example="2025-02-04")
|
| 466 |
-
status: str = Field(..., description="Invoice status", example="open")
|
| 467 |
-
subtotal: float = Field(..., description="Subtotal amount", example=2000.0)
|
| 468 |
-
tax_amount: float = Field(..., description="Tax amount", example=170.0)
|
| 469 |
-
total: float = Field(..., description="Total invoice amount", example=2170.0)
|
| 470 |
-
balance_due: float = Field(..., description="Outstanding balance", example=1270.0)
|
| 471 |
-
department_id: Optional[int] = Field(None, description="Linked department ID", example=2)
|
| 472 |
-
tax_category_id: Optional[int] = Field(None, description="Linked tax category ID", example=1)
|
| 473 |
-
payment_terms_id: Optional[int] = Field(None, description="Linked payment terms ID", example=3)
|
| 474 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2025-01-05T09:00:00Z")
|
| 475 |
-
updated_at: Optional[datetime] = Field(None, description="Last update timestamp", example="2025-01-10T10:00:00Z")
|
| 476 |
-
|
| 477 |
-
class InvoicesListResponse(BaseModel):
|
| 478 |
-
invoices: List[InvoicesListItemResponse] = Field(..., description="List of invoices", example=[])
|
| 479 |
-
|
| 480 |
-
class PaymentCreateRequest(BaseModel):
|
| 481 |
-
customer_id: int = Field(..., description="Customer who made the payment", example=10)
|
| 482 |
-
payment_date: str = Field(..., description="Date payment was received (YYYY-MM-DD)", example="2025-01-10")
|
| 483 |
-
settlement_date: Optional[str] = Field(None, description="Date payment settled in bank (YYYY-MM-DD)", example="2025-01-10")
|
| 484 |
-
amount: float = Field(..., description="Gross payment amount", example=900.0)
|
| 485 |
-
currency: Optional[str] = Field("USD", description="Currency code (defaults to USD)", example="USD")
|
| 486 |
-
method: str = Field(..., description="Payment method description", example="Credit Card")
|
| 487 |
-
reference: Optional[str] = Field(None, description="External reference or transaction ID", example="STRIPE-12345")
|
| 488 |
-
|
| 489 |
-
class PaymentResponse(BaseModel):
|
| 490 |
-
model_config = ConfigDict(from_attributes=True)
|
| 491 |
-
id: int = Field(..., description="Payment ID", example=2001)
|
| 492 |
-
customer_id: int = Field(..., description="Customer ID", example=10)
|
| 493 |
-
payment_date: date = Field(..., description="Payment date", example="2025-01-10")
|
| 494 |
-
settlement_date: Optional[date] = Field(None, description="Settlement date", example="2025-01-10")
|
| 495 |
-
amount: float = Field(..., description="Payment amount", example=900.0)
|
| 496 |
-
currency: str = Field(..., description="Payment currency", example="USD")
|
| 497 |
-
method: str = Field(..., description="Payment method", example="Credit Card")
|
| 498 |
-
reference: Optional[str] = Field(None, description="External reference ID", example="STRIPE-12345")
|
| 499 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2025-01-10T12:00:00Z")
|
| 500 |
-
updated_at: Optional[datetime] = Field(None, description="Update timestamp", example=None)
|
| 501 |
-
|
| 502 |
-
class PaymentApplicationCreateRequest(BaseModel):
|
| 503 |
-
payment_id: int = Field(..., description="Payment to allocate", example=2001)
|
| 504 |
-
invoice_id: int = Field(..., description="Invoice receiving this payment portion", example=1001)
|
| 505 |
-
amount: float = Field(..., description="Amount applied from payment to invoice", example=900.0)
|
| 506 |
-
|
| 507 |
-
class PaymentApplicationResponse(BaseModel):
|
| 508 |
-
model_config = ConfigDict(from_attributes=True)
|
| 509 |
-
id: int = Field(..., description="Payment application ID", example=3001)
|
| 510 |
-
payment_id: int = Field(..., description="Linked payment ID", example=2001)
|
| 511 |
-
invoice_id: int = Field(..., description="Linked invoice ID", example=1001)
|
| 512 |
-
amount: float = Field(..., description="Amount applied", example=900.0)
|
| 513 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2025-01-10T12:05:00Z")
|
| 514 |
-
updated_at: Optional[datetime] = Field(None, description="Update timestamp", example=None)
|
| 515 |
-
|
| 516 |
-
class VendorCreateRequest(BaseModel):
|
| 517 |
-
name: str = Field(..., description="Vendor legal or display name", example="PixelPrint Supplies")
|
| 518 |
-
contact_email: Optional[str] = Field(None, description="Vendor accounts payable contact email", example="accounts@pixelprint.com")
|
| 519 |
-
payment_terms_id: Optional[int] = Field(None, description="Default payment terms for this vendor", example=2)
|
| 520 |
-
default_expense_category_id: Optional[int] = Field(None, description="Default expense account for purchases from this vendor", example=60)
|
| 521 |
-
|
| 522 |
-
class VendorResponse(BaseModel):
|
| 523 |
-
model_config = ConfigDict(from_attributes=True)
|
| 524 |
-
id: int = Field(..., description="Vendor ID", example=20)
|
| 525 |
-
name: str = Field(..., description="Vendor name", example="PixelPrint Supplies")
|
| 526 |
-
contact_email: Optional[str] = Field(None, description="Vendor email", example="accounts@pixelprint.com")
|
| 527 |
-
payment_terms_id: Optional[int] = Field(None, description="Linked payment_terms ID", example=2)
|
| 528 |
-
default_expense_category_id: Optional[int] = Field(None, description="Linked default expense account ID", example=60)
|
| 529 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2025-01-03T08:00:00Z")
|
| 530 |
-
updated_at: Optional[datetime] = Field(None, description="Update timestamp", example=None)
|
| 531 |
-
|
| 532 |
-
class VendorsListResponse(BaseModel):
|
| 533 |
-
vendors: List[VendorResponse] = Field(..., description="List of vendors", example=[])
|
| 534 |
-
|
| 535 |
-
class BillCreateRequest(BaseModel):
|
| 536 |
-
bill_number: Optional[str] = Field(None, description="Vendor-provided bill or invoice number", example="BILL-2025-001")
|
| 537 |
-
vendor_id: int = Field(..., description="Vendor this bill is from", example=20)
|
| 538 |
-
bill_date: str = Field(..., description="Date on the vendor bill (YYYY-MM-DD)", example="2025-01-03")
|
| 539 |
-
due_date: Optional[str] = Field(None, description="Due date if known (YYYY-MM-DD)", example="2025-01-18")
|
| 540 |
-
currency: Optional[str] = Field("USD", description="Bill currency code", example="USD")
|
| 541 |
-
amount: float = Field(..., description="Total bill amount", example=325.5)
|
| 542 |
-
description: Optional[str] = Field(None, description="Description of the bill or purpose", example="Printer ink and paper")
|
| 543 |
-
department_id: Optional[int] = Field(None, description="Department to expense this bill to", example=3)
|
| 544 |
-
reimbursement_status: str = Field(..., description="Reimbursement status (Not Reimbursable, Reimbursable, Reimbursed)", example="Not Reimbursable")
|
| 545 |
-
payment_terms_id: Optional[int] = Field(None, description="Payment terms used for due_date calculation", example=1)
|
| 546 |
-
status: Optional[str] = Field("open", description="Bill status (open, paid, void)", example="open")
|
| 547 |
-
|
| 548 |
-
class BillResponse(BaseModel):
|
| 549 |
-
model_config = ConfigDict(from_attributes=True)
|
| 550 |
-
id: int = Field(..., description="Bill ID", example=7001)
|
| 551 |
-
bill_number: Optional[str] = Field(None, description="Vendor bill number", example="BILL-2025-001")
|
| 552 |
-
vendor_id: int = Field(..., description="Vendor ID", example=20)
|
| 553 |
-
bill_date: date = Field(..., description="Bill date", example="2025-01-03")
|
| 554 |
-
due_date: Optional[date] = Field(None, description="Due date", example="2025-01-18")
|
| 555 |
-
currency: str = Field(..., description="Currency code", example="USD")
|
| 556 |
-
amount: float = Field(..., description="Bill amount", example=325.5)
|
| 557 |
-
description: Optional[str] = Field(None, description="Bill description", example="Printer ink and paper")
|
| 558 |
-
department_id: Optional[int] = Field(None, description="Department ID", example=3)
|
| 559 |
-
reimbursement_status: str = Field(..., description="Reimbursement status", example="Not Reimbursable")
|
| 560 |
-
payment_terms_id: Optional[int] = Field(None, description="Payment terms ID", example=1)
|
| 561 |
-
status: str = Field(..., description="Bill status", example="open")
|
| 562 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2025-01-03T09:30:00Z")
|
| 563 |
-
updated_at: Optional[datetime] = Field(None, description="Update timestamp", example=None)
|
| 564 |
-
|
| 565 |
-
class RecurringExpenseCreateRequest(BaseModel):
|
| 566 |
-
name: str = Field(..., description="Name of the recurring expense", example="Monthly Co-working Space Rent")
|
| 567 |
-
vendor_id: Optional[int] = Field(None, description="Vendor providing the recurring service", example=30)
|
| 568 |
-
amount: float = Field(..., description="Recurring amount for each run", example=650.0)
|
| 569 |
-
expense_account_id: int = Field(..., description="Expense account ID to debit", example=80)
|
| 570 |
-
department_id: Optional[int] = Field(None, description="Department that bears this recurring expense", example=4)
|
| 571 |
-
frequency: str = Field(..., description="Run frequency (daily, weekly, monthly, quarterly, yearly)", example="monthly")
|
| 572 |
-
next_run_date: str = Field(..., description="Next date the template should generate an expense (YYYY-MM-DD)", example="2025-02-01")
|
| 573 |
-
end_date: Optional[str] = Field(None, description="Date after which no more runs occur", example="2025-12-01")
|
| 574 |
-
is_active: Optional[bool] = Field(True, description="Whether this template is active", example=True)
|
| 575 |
-
|
| 576 |
-
class RecurringExpenseResponse(BaseModel):
|
| 577 |
-
model_config = ConfigDict(from_attributes=True)
|
| 578 |
-
id: int = Field(..., description="Recurring expense template ID", example=9001)
|
| 579 |
-
name: str = Field(..., description="Template name", example="Monthly Co-working Space Rent")
|
| 580 |
-
vendor_id: Optional[int] = Field(None, description="Vendor ID", example=30)
|
| 581 |
-
amount: float = Field(..., description="Recurring amount", example=650.0)
|
| 582 |
-
expense_account_id: int = Field(..., description="Expense account ID", example=80)
|
| 583 |
-
department_id: Optional[int] = Field(None, description="Department ID", example=4)
|
| 584 |
-
frequency: str = Field(..., description="Frequency", example="monthly")
|
| 585 |
-
next_run_date: date = Field(..., description="Next run date", example="2025-02-01")
|
| 586 |
-
end_date: Optional[date] = Field(None, description="End date", example="2025-12-01")
|
| 587 |
-
is_active: bool = Field(..., description="Whether template is active", example=True)
|
| 588 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2025-01-15T09:00:00Z")
|
| 589 |
-
updated_at: Optional[datetime] = Field(None, description="Update timestamp", example=None)
|
| 590 |
-
|
| 591 |
-
class BankTransactionItemRequest(BaseModel):
|
| 592 |
-
transaction_date: str = Field(..., description="Transaction date (YYYY-MM-DD)", example="2025-01-01")
|
| 593 |
-
posted_date: Optional[str] = Field(None, description="Posted date (YYYY-MM-DD)", example="2025-01-02")
|
| 594 |
-
description: str = Field(..., description="Bank description", example="Client payment ACME")
|
| 595 |
-
amount: float = Field(..., description="Transaction amount (positive or negative)", example=1500.0)
|
| 596 |
-
external_id: Optional[str] = Field(None, description="External bank transaction identifier", example="txn_001")
|
| 597 |
-
|
| 598 |
-
class BankTransactionsBatchImportRequest(BaseModel):
|
| 599 |
-
bank_account_id: int = Field(..., description="Bank account ID these transactions belong to", example=1)
|
| 600 |
-
transactions: List[BankTransactionItemRequest] = Field(..., description="Array of bank transactions to import", example=[])
|
| 601 |
-
|
| 602 |
-
class BankTransactionResponse(BaseModel):
|
| 603 |
-
model_config = ConfigDict(from_attributes=True)
|
| 604 |
-
id: int = Field(..., description="Bank transaction ID", example=6001)
|
| 605 |
-
bank_account_id: int = Field(..., description="Bank account ID", example=1)
|
| 606 |
-
transaction_date: date = Field(..., description="Transaction date", example="2025-01-01")
|
| 607 |
-
posted_date: Optional[date] = Field(None, description="Posted date", example="2025-01-02")
|
| 608 |
-
description: str = Field(..., description="Transaction description", example="Client payment ACME")
|
| 609 |
-
amount: float = Field(..., description="Transaction amount", example=1500.0)
|
| 610 |
-
external_id: Optional[str] = Field(None, description="External transaction ID", example="txn_001")
|
| 611 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2025-01-07T10:00:00Z")
|
| 612 |
-
updated_at: Optional[datetime] = Field(None, description="Update timestamp", example=None)
|
| 613 |
-
|
| 614 |
-
class BankTransactionsBatchImportResponse(BaseModel):
|
| 615 |
-
bank_transactions: List[BankTransactionResponse] = Field(..., description="Imported bank transactions", example=[])
|
| 616 |
-
|
| 617 |
-
class BankTransactionsListResponse(BaseModel):
|
| 618 |
-
bank_transactions: List[BankTransactionResponse] = Field(..., description="List of bank transactions", example=[])
|
| 619 |
-
|
| 620 |
-
class JournalEntryCreateRequest(BaseModel):
|
| 621 |
-
entry_date: str = Field(..., description="Date of the journal entry (YYYY-MM-DD)", example="2024-12-31")
|
| 622 |
-
description: Optional[str] = Field(None, description="Narrative description of the entry", example="Year-end accrual for expenses")
|
| 623 |
-
department_id: Optional[int] = Field(None, description="Department that this entry belongs to", example=4)
|
| 624 |
-
source: Optional[str] = Field(None, description="System source of this entry", example="manual")
|
| 625 |
-
source_id: Optional[int] = Field(None, description="External source ID if applicable", example=None)
|
| 626 |
-
|
| 627 |
-
class JournalEntryResponse(BaseModel):
|
| 628 |
-
model_config = ConfigDict(from_attributes=True)
|
| 629 |
-
id: int = Field(..., description="Journal entry ID", example=8001)
|
| 630 |
-
entry_date: date = Field(..., description="Entry date", example="2024-12-31")
|
| 631 |
-
description: Optional[str] = Field(None, description="Entry description", example="Year-end accrual for expenses")
|
| 632 |
-
department_id: Optional[int] = Field(None, description="Department ID", example=4)
|
| 633 |
-
source: Optional[str] = Field(None, description="Source system", example="manual")
|
| 634 |
-
source_id: Optional[int] = Field(None, description="Source record ID", example=None)
|
| 635 |
-
created_by_user_id: Optional[int] = Field(None, description="User who created the entry (always 1)", example=1)
|
| 636 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2024-12-31T23:50:00Z")
|
| 637 |
-
updated_at: Optional[datetime] = Field(None, description="Update timestamp", example=None)
|
| 638 |
-
|
| 639 |
-
class JournalEntryLineCreateRequest(BaseModel):
|
| 640 |
-
journal_entry_id: int = Field(..., description="Parent journal entry ID", example=8001)
|
| 641 |
-
account_id: int = Field(..., description="Account to debit or credit", example=50)
|
| 642 |
-
department_id: Optional[int] = Field(None, description="Department for this line if different from header", example=4)
|
| 643 |
-
description: Optional[str] = Field(None, description="Line-specific description", example="Accrual for December software expenses")
|
| 644 |
-
debit: Optional[float] = Field(0.0, description="Debit amount (0 if this is a credit line)", example=300.0)
|
| 645 |
-
credit: Optional[float] = Field(0.0, description="Credit amount (0 if this is a debit line)", example=0.0)
|
| 646 |
-
|
| 647 |
-
class JournalEntryLineResponse(BaseModel):
|
| 648 |
-
model_config = ConfigDict(from_attributes=True)
|
| 649 |
-
id: int = Field(..., description="Journal entry line ID", example=8101)
|
| 650 |
-
journal_entry_id: int = Field(..., description="Parent journal entry ID", example=8001)
|
| 651 |
-
account_id: int = Field(..., description="Account ID", example=50)
|
| 652 |
-
department_id: Optional[int] = Field(None, description="Department ID", example=4)
|
| 653 |
-
description: Optional[str] = Field(None, description="Line description", example="Accrual for December software expenses")
|
| 654 |
-
debit: float = Field(..., description="Debit amount", example=300.0)
|
| 655 |
-
credit: float = Field(..., description="Credit amount", example=0.0)
|
| 656 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2024-12-31T23:51:00Z")
|
| 657 |
-
updated_at: Optional[datetime] = Field(None, description="Update timestamp", example=None)
|
| 658 |
-
|
| 659 |
-
class BankTransactionJournalLinkCreateRequest(BaseModel):
|
| 660 |
-
bank_transaction_id: int = Field(..., description="Bank transaction ID being reconciled", example=6001)
|
| 661 |
-
journal_entry_id: int = Field(..., description="Journal entry ID representing the accounting for this transaction", example=8005)
|
| 662 |
-
|
| 663 |
-
class BankTransactionJournalLinkResponse(BaseModel):
|
| 664 |
-
model_config = ConfigDict(from_attributes=True)
|
| 665 |
-
id: int = Field(..., description="Link ID", example=90001)
|
| 666 |
-
bank_transaction_id: int = Field(..., description="Bank transaction ID", example=6001)
|
| 667 |
-
journal_entry_id: int = Field(..., description="Journal entry ID", example=8005)
|
| 668 |
-
created_at: Optional[datetime] = Field(None, description="Link creation timestamp", example="2025-01-07T11:00:00Z")
|
| 669 |
-
|
| 670 |
-
class RecurringInvoiceCreateRequest(BaseModel):
|
| 671 |
-
customer_id: int = Field(..., description="Customer who will receive recurring invoices", example=15)
|
| 672 |
-
name: str = Field(..., description="Name of the recurring invoice template", example="Monthly SEO Retainer")
|
| 673 |
-
description: Optional[str] = Field(None, description="Description of the service or product", example="Monthly SEO services retainer")
|
| 674 |
-
quantity: float = Field(..., description="Quantity per recurring invoice", example=1.0)
|
| 675 |
-
unit_price: float = Field(..., description="Unit price per run", example=1500.0)
|
| 676 |
-
discount_percent: Optional[float] = Field(0.0, description="Discount percent per run", example=0.0)
|
| 677 |
-
frequency: str = Field(..., description="Frequency (daily, weekly, monthly, quarterly, yearly)", example="monthly")
|
| 678 |
-
next_run_date: str = Field(..., description="Date of next invoice generation (YYYY-MM-DD)", example="2025-02-01")
|
| 679 |
-
end_date: Optional[str] = Field(None, description="Final date for invoice generation", example="2025-07-01")
|
| 680 |
-
payment_terms_id: Optional[int] = Field(None, description="Payment terms applied to generated invoices", example=4)
|
| 681 |
-
tax_category_id: Optional[int] = Field(None, description="Tax category for generated invoices", example=5)
|
| 682 |
-
department_id: Optional[int] = Field(None, description="Department for generated invoices", example=2)
|
| 683 |
-
currency: Optional[str] = Field("USD", description="Currency for generated invoices", example="USD")
|
| 684 |
-
is_active: Optional[bool] = Field(True, description="Whether this recurring schedule is active", example=True)
|
| 685 |
-
|
| 686 |
-
class RecurringInvoiceResponse(BaseModel):
|
| 687 |
-
model_config = ConfigDict(from_attributes=True)
|
| 688 |
-
id: int = Field(..., description="Recurring invoice template ID", example=9501)
|
| 689 |
-
customer_id: int = Field(..., description="Customer ID", example=15)
|
| 690 |
-
name: str = Field(..., description="Template name", example="Monthly SEO Retainer")
|
| 691 |
-
description: Optional[str] = Field(None, description="Template description", example="Monthly SEO services retainer")
|
| 692 |
-
quantity: float = Field(..., description="Quantity per invoice", example=1.0)
|
| 693 |
-
unit_price: float = Field(..., description="Unit price", example=1500.0)
|
| 694 |
-
discount_percent: float = Field(..., description="Discount percent", example=0.0)
|
| 695 |
-
frequency: str = Field(..., description="Frequency", example="monthly")
|
| 696 |
-
next_run_date: date = Field(..., description="Next run date", example="2025-02-01")
|
| 697 |
-
end_date: Optional[date] = Field(None, description="End date", example="2025-07-01")
|
| 698 |
-
payment_terms_id: Optional[int] = Field(None, description="Payment terms ID", example=4)
|
| 699 |
-
tax_category_id: Optional[int] = Field(None, description="Tax category ID", example=5)
|
| 700 |
-
department_id: Optional[int] = Field(None, description="Department ID", example=2)
|
| 701 |
-
currency: str = Field(..., description="Currency", example="USD")
|
| 702 |
-
is_active: bool = Field(..., description="Whether template is active", example=True)
|
| 703 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2025-01-20T09:00:00Z")
|
| 704 |
-
updated_at: Optional[datetime] = Field(None, description="Update timestamp", example=None)
|
| 705 |
-
|
| 706 |
-
class AccountingPeriodCreateRequest(BaseModel):
|
| 707 |
-
start_date: str = Field(..., description="Start date of the period (YYYY-MM-DD)", example="2024-01-01")
|
| 708 |
-
end_date: str = Field(..., description="End date of the period (YYYY-MM-DD)", example="2024-12-31")
|
| 709 |
-
close_date: Optional[str] = Field(None, description="Date when the period was closed", example="2024-12-31")
|
| 710 |
-
is_locked: Optional[bool] = Field(False, description="Whether the period is locked against changes", example=True)
|
| 711 |
-
|
| 712 |
-
class AccountingPeriodUpdateRequest(BaseModel):
|
| 713 |
-
close_date: Optional[str] = Field(None, description="New close date or null to clear", example="2024-12-31")
|
| 714 |
-
is_locked: Optional[bool] = Field(None, description="Set true to lock or false to unlock", example=True)
|
| 715 |
-
|
| 716 |
-
class AccountingPeriodResponse(BaseModel):
|
| 717 |
-
model_config = ConfigDict(from_attributes=True)
|
| 718 |
-
id: int = Field(..., description="Accounting period ID", example=10001)
|
| 719 |
-
start_date: date = Field(..., description="Start date", example="2024-01-01")
|
| 720 |
-
end_date: date = Field(..., description="End date", example="2024-12-31")
|
| 721 |
-
close_date: Optional[date] = Field(None, description="Close date or null", example="2024-12-31")
|
| 722 |
-
is_locked: bool = Field(..., description="Locked flag", example=True)
|
| 723 |
-
created_at: Optional[datetime] = Field(None, description="Creation timestamp", example="2024-12-31T23:55:00Z")
|
| 724 |
-
updated_at: Optional[datetime] = Field(None, description="Update timestamp", example=None)
|
| 725 |
-
|
| 726 |
-
class ProfitAndLossReportResponse(BaseModel):
|
| 727 |
-
start_date: str = Field(..., description="Report start date", example="2025-01-01")
|
| 728 |
-
end_date: str = Field(..., description="Report end date", example="2025-01-31")
|
| 729 |
-
department_id: Optional[int] = Field(None, description="Department filter or null if not filtered", example=2)
|
| 730 |
-
total_revenue: float = Field(..., description="Sum of income account balances for the period", example=5000.0)
|
| 731 |
-
total_expenses: float = Field(..., description="Sum of expense account balances for the period", example=3000.0)
|
| 732 |
-
net_profit: float = Field(..., description="total_revenue - total_expenses", example=2000.0)
|
| 733 |
-
detail: Dict[str, List[Dict[str, Optional[float]]]] = Field(..., description="Optional breakdown of accounts", example={"income_accounts": [], "expense_accounts": []})
|
| 734 |
-
|
| 735 |
-
@app.post(
|
| 736 |
-
"/api/customers",
|
| 737 |
-
response_model=CustomerResponse,
|
| 738 |
-
summary="Create a new customer",
|
| 739 |
-
description="Create a customer with optional payment terms and tax category.",
|
| 740 |
-
tags=["customers"],
|
| 741 |
-
operation_id="create_customer",
|
| 742 |
-
)
|
| 743 |
-
async def create_customer_endpoint(body: CustomerCreateRequest = Body(...)) -> CustomerResponse:
|
| 744 |
-
session = SessionLocal()
|
| 745 |
-
customer = Customer(
|
| 746 |
-
name=body.name,
|
| 747 |
-
billing_email=body.billing_email,
|
| 748 |
-
payment_terms_id=body.payment_terms_id,
|
| 749 |
-
default_tax_category_id=body.default_tax_category_id,
|
| 750 |
-
created_at=datetime.utcnow(),
|
| 751 |
-
updated_at=None,
|
| 752 |
-
)
|
| 753 |
-
session.add(customer)
|
| 754 |
-
session.commit()
|
| 755 |
-
session.refresh(customer)
|
| 756 |
-
session.close()
|
| 757 |
-
return CustomerResponse(
|
| 758 |
-
id=customer.id,
|
| 759 |
-
name=customer.name,
|
| 760 |
-
billing_email=customer.billing_email,
|
| 761 |
-
payment_terms_id=customer.payment_terms_id,
|
| 762 |
-
default_tax_category_id=customer.default_tax_category_id,
|
| 763 |
-
created_at=customer.created_at,
|
| 764 |
-
updated_at=customer.updated_at,
|
| 765 |
-
)
|
| 766 |
-
|
| 767 |
-
@app.get(
|
| 768 |
-
"/api/customers",
|
| 769 |
-
response_model=CustomersListResponse,
|
| 770 |
-
summary="List customers with optional filters",
|
| 771 |
-
description="Retrieve customers filtered by name or billing email.",
|
| 772 |
-
tags=["customers"],
|
| 773 |
-
operation_id="list_customers",
|
| 774 |
-
)
|
| 775 |
-
async def list_customers_endpoint(
|
| 776 |
-
name: Optional[str] = Query(None, description="Filter by exact or partial customer name", example="Acme"),
|
| 777 |
-
billing_email: Optional[str] = Query(None, description="Filter customers by billing_email exact match", example="billing@acmedesign.com"),
|
| 778 |
-
limit: Optional[int] = Query(50, description="Maximum number of records to return", example=50),
|
| 779 |
-
offset: Optional[int] = Query(0, description="Number of records to skip for pagination", example=0),
|
| 780 |
-
) -> CustomersListResponse:
|
| 781 |
-
session = SessionLocal()
|
| 782 |
-
query = session.query(Customer)
|
| 783 |
-
if name is not None:
|
| 784 |
-
query = query.filter(Customer.name.contains(name))
|
| 785 |
-
if billing_email is not None:
|
| 786 |
-
query = query.filter(Customer.billing_email == billing_email)
|
| 787 |
-
customers = query.offset(offset).limit(limit).all()
|
| 788 |
-
session.close()
|
| 789 |
-
return CustomersListResponse(customers=customers)
|
| 790 |
-
|
| 791 |
-
@app.get(
|
| 792 |
-
"/api/customers/{customer_id}",
|
| 793 |
-
response_model=CustomerResponse,
|
| 794 |
-
summary="Get a single customer by ID",
|
| 795 |
-
description="Fetch one customer by ID to inspect billing settings.",
|
| 796 |
-
tags=["customers"],
|
| 797 |
-
operation_id="get_customer",
|
| 798 |
-
)
|
| 799 |
-
async def get_customer_endpoint(
|
| 800 |
-
customer_id: int = Path(..., description="Customer ID to retrieve", example=10)
|
| 801 |
-
) -> CustomerResponse:
|
| 802 |
-
session = SessionLocal()
|
| 803 |
-
customer = session.query(Customer).filter(Customer.id == customer_id).first()
|
| 804 |
-
session.close()
|
| 805 |
-
if customer is None:
|
| 806 |
-
return CustomerResponse(
|
| 807 |
-
id=0,
|
| 808 |
-
name="",
|
| 809 |
-
billing_email=None,
|
| 810 |
-
payment_terms_id=None,
|
| 811 |
-
default_tax_category_id=None,
|
| 812 |
-
created_at=None,
|
| 813 |
-
updated_at=None,
|
| 814 |
-
)
|
| 815 |
-
return CustomerResponse(
|
| 816 |
-
id=customer.id,
|
| 817 |
-
name=customer.name,
|
| 818 |
-
billing_email=customer.billing_email,
|
| 819 |
-
payment_terms_id=customer.payment_terms_id,
|
| 820 |
-
default_tax_category_id=customer.default_tax_category_id,
|
| 821 |
-
created_at=customer.created_at,
|
| 822 |
-
updated_at=customer.updated_at,
|
| 823 |
-
)
|
| 824 |
-
|
| 825 |
-
@app.get(
|
| 826 |
-
"/api/payment_terms",
|
| 827 |
-
response_model=PaymentTermsListResponse,
|
| 828 |
-
summary="List payment terms",
|
| 829 |
-
description="Retrieve payment_terms records optionally filtered by name.",
|
| 830 |
-
tags=["payment_terms"],
|
| 831 |
-
operation_id="list_payment_terms",
|
| 832 |
-
)
|
| 833 |
-
async def list_payment_terms_endpoint(
|
| 834 |
-
name: Optional[str] = Query(None, description="Filter terms by name", example="Net 30")
|
| 835 |
-
) -> PaymentTermsListResponse:
|
| 836 |
-
session = SessionLocal()
|
| 837 |
-
query = session.query(PaymentTerm)
|
| 838 |
-
if name is not None:
|
| 839 |
-
query = query.filter(PaymentTerm.name.contains(name))
|
| 840 |
-
payment_terms = query.all()
|
| 841 |
-
session.close()
|
| 842 |
-
return PaymentTermsListResponse(payment_terms=payment_terms)
|
| 843 |
-
|
| 844 |
-
@app.get(
|
| 845 |
-
"/api/tax_categories",
|
| 846 |
-
response_model=TaxCategoriesListResponse,
|
| 847 |
-
summary="List tax categories",
|
| 848 |
-
description="Retrieve available tax_categories optionally filtered by name.",
|
| 849 |
-
tags=["tax_categories"],
|
| 850 |
-
operation_id="list_tax_categories",
|
| 851 |
-
)
|
| 852 |
-
async def list_tax_categories_endpoint(
|
| 853 |
-
name: Optional[str] = Query(None, description="Filter tax categories by exact or partial name", example="Standard Sales Tax 8.5%")
|
| 854 |
-
) -> TaxCategoriesListResponse:
|
| 855 |
-
session = SessionLocal()
|
| 856 |
-
query = session.query(TaxCategory)
|
| 857 |
-
if name is not None:
|
| 858 |
-
query = query.filter(TaxCategory.name.contains(name))
|
| 859 |
-
rows = query.all()
|
| 860 |
-
tax_categories: List[TaxCategoryResponse] = []
|
| 861 |
-
for r in rows:
|
| 862 |
-
tax_categories.append(
|
| 863 |
-
TaxCategoryResponse(
|
| 864 |
-
id=r.id,
|
| 865 |
-
name=r.name,
|
| 866 |
-
description=r.description,
|
| 867 |
-
rate=r.rate,
|
| 868 |
-
is_compound=bool(r.is_compound),
|
| 869 |
-
created_at=r.created_at,
|
| 870 |
-
updated_at=r.updated_at,
|
| 871 |
-
)
|
| 872 |
-
)
|
| 873 |
-
session.close()
|
| 874 |
-
return TaxCategoriesListResponse(tax_categories=tax_categories)
|
| 875 |
-
|
| 876 |
-
@app.get(
|
| 877 |
-
"/api/departments",
|
| 878 |
-
response_model=DepartmentsListResponse,
|
| 879 |
-
summary="List departments",
|
| 880 |
-
description="Retrieve departments to map human-readable names to IDs.",
|
| 881 |
-
tags=["departments"],
|
| 882 |
-
operation_id="list_departments",
|
| 883 |
-
)
|
| 884 |
-
async def list_departments_endpoint(
|
| 885 |
-
name: Optional[str] = Query(None, description="Filter departments by name", example="Design")
|
| 886 |
-
) -> DepartmentsListResponse:
|
| 887 |
-
session = SessionLocal()
|
| 888 |
-
query = session.query(Department)
|
| 889 |
-
if name is not None:
|
| 890 |
-
query = query.filter(Department.name.contains(name))
|
| 891 |
-
departments = query.all()
|
| 892 |
-
session.close()
|
| 893 |
-
return DepartmentsListResponse(departments=departments)
|
| 894 |
-
|
| 895 |
-
@app.get(
|
| 896 |
-
"/api/accounts",
|
| 897 |
-
response_model=AccountsListResponse,
|
| 898 |
-
summary="List chart of accounts",
|
| 899 |
-
description="Retrieve accounts filtered by type or name.",
|
| 900 |
-
tags=["accounts"],
|
| 901 |
-
operation_id="list_accounts",
|
| 902 |
-
)
|
| 903 |
-
async def list_accounts_endpoint(
|
| 904 |
-
type: Optional[str] = Query(None, description="Filter accounts by type (asset, liability, equity, income, expense, contra)", example="expense"),
|
| 905 |
-
name: Optional[str] = Query(None, description="Filter accounts by name", example="Software Subscriptions"),
|
| 906 |
-
) -> AccountsListResponse:
|
| 907 |
-
session = SessionLocal()
|
| 908 |
-
query = session.query(Account)
|
| 909 |
-
if type is not None:
|
| 910 |
-
query = query.filter(Account.type == type)
|
| 911 |
-
if name is not None:
|
| 912 |
-
query = query.filter(Account.name.contains(name))
|
| 913 |
-
rows = query.all()
|
| 914 |
-
accounts_list: List[AccountResponse] = []
|
| 915 |
-
for a in rows:
|
| 916 |
-
accounts_list.append(
|
| 917 |
-
AccountResponse(
|
| 918 |
-
id=a.id,
|
| 919 |
-
name=a.name,
|
| 920 |
-
code=a.code,
|
| 921 |
-
type=a.type,
|
| 922 |
-
sub_type=a.sub_type,
|
| 923 |
-
is_active=bool(a.is_active),
|
| 924 |
-
created_at=a.created_at,
|
| 925 |
-
updated_at=a.updated_at,
|
| 926 |
-
)
|
| 927 |
-
)
|
| 928 |
-
session.close()
|
| 929 |
-
return AccountsListResponse(accounts=accounts_list)
|
| 930 |
-
|
| 931 |
-
@app.get(
|
| 932 |
-
"/api/bank_accounts",
|
| 933 |
-
response_model=BankAccountsListResponse,
|
| 934 |
-
summary="List bank accounts",
|
| 935 |
-
description="Retrieve bank_accounts to find IDs for bank transactions.",
|
| 936 |
-
tags=["bank_accounts"],
|
| 937 |
-
operation_id="list_bank_accounts",
|
| 938 |
-
)
|
| 939 |
-
async def list_bank_accounts_endpoint(
|
| 940 |
-
name: Optional[str] = Query(None, description="Filter bank accounts by name", example="Chase Business Checking ****1023")
|
| 941 |
-
) -> BankAccountsListResponse:
|
| 942 |
-
session = SessionLocal()
|
| 943 |
-
query = session.query(BankAccount)
|
| 944 |
-
if name is not None:
|
| 945 |
-
query = query.filter(BankAccount.name.contains(name))
|
| 946 |
-
bank_accounts = query.all()
|
| 947 |
-
session.close()
|
| 948 |
-
return BankAccountsListResponse(bank_accounts=bank_accounts)
|
| 949 |
-
|
| 950 |
-
@app.post(
|
| 951 |
-
"/api/invoices",
|
| 952 |
-
response_model=InvoiceResponse,
|
| 953 |
-
summary="Create a new invoice header",
|
| 954 |
-
description="Create an invoice record without line items.",
|
| 955 |
-
tags=["invoices"],
|
| 956 |
-
operation_id="create_invoice",
|
| 957 |
-
)
|
| 958 |
-
async def create_invoice_endpoint(body: InvoiceCreateRequest = Body(...)) -> InvoiceResponse:
|
| 959 |
-
session = SessionLocal()
|
| 960 |
-
invoice = Invoice(
|
| 961 |
-
invoice_number=body.invoice_number,
|
| 962 |
-
customer_id=body.customer_id,
|
| 963 |
-
department_id=body.department_id,
|
| 964 |
-
tax_category_id=body.tax_category_id,
|
| 965 |
-
invoice_date=date.fromisoformat(body.invoice_date),
|
| 966 |
-
due_date=date.fromisoformat(body.due_date),
|
| 967 |
-
currency=body.currency if body.currency is not None else "USD",
|
| 968 |
-
status=body.status if body.status is not None else "draft",
|
| 969 |
-
subtotal=0.0,
|
| 970 |
-
tax_amount=0.0,
|
| 971 |
-
total=0.0,
|
| 972 |
-
balance_due=0.0,
|
| 973 |
-
payment_terms_id=body.payment_terms_id,
|
| 974 |
-
created_at=datetime.utcnow(),
|
| 975 |
-
updated_at=None,
|
| 976 |
-
)
|
| 977 |
-
session.add(invoice)
|
| 978 |
-
session.commit()
|
| 979 |
-
session.refresh(invoice)
|
| 980 |
-
session.close()
|
| 981 |
-
return InvoiceResponse(
|
| 982 |
-
id=invoice.id,
|
| 983 |
-
invoice_number=invoice.invoice_number,
|
| 984 |
-
customer_id=invoice.customer_id,
|
| 985 |
-
department_id=invoice.department_id,
|
| 986 |
-
tax_category_id=invoice.tax_category_id,
|
| 987 |
-
invoice_date=invoice.invoice_date,
|
| 988 |
-
due_date=invoice.due_date,
|
| 989 |
-
currency=invoice.currency,
|
| 990 |
-
status=invoice.status,
|
| 991 |
-
subtotal=invoice.subtotal,
|
| 992 |
-
tax_amount=invoice.tax_amount,
|
| 993 |
-
total=invoice.total,
|
| 994 |
-
balance_due=invoice.balance_due,
|
| 995 |
-
payment_terms_id=invoice.payment_terms_id,
|
| 996 |
-
created_at=invoice.created_at,
|
| 997 |
-
updated_at=invoice.updated_at,
|
| 998 |
-
)
|
| 999 |
-
|
| 1000 |
-
@app.post(
|
| 1001 |
-
"/api/invoice_line_items",
|
| 1002 |
-
response_model=InvoiceLineItemResponse,
|
| 1003 |
-
summary="Add a line item to an invoice",
|
| 1004 |
-
description="Create an invoice line and update invoice totals.",
|
| 1005 |
-
tags=["invoices", "invoice_line_items"],
|
| 1006 |
-
operation_id="create_invoice_line_item",
|
| 1007 |
-
)
|
| 1008 |
-
async def create_invoice_line_item_endpoint(
|
| 1009 |
-
body: InvoiceLineItemCreateRequest = Body(...)
|
| 1010 |
-
) -> InvoiceLineItemResponse:
|
| 1011 |
-
session = SessionLocal()
|
| 1012 |
-
invoice = session.query(Invoice).filter(Invoice.id == body.invoice_id).first()
|
| 1013 |
-
tax_rate = 0.0
|
| 1014 |
-
if invoice is not None and invoice.tax_category_id is not None:
|
| 1015 |
-
tax_cat = session.query(TaxCategory).filter(TaxCategory.id == invoice.tax_category_id).first()
|
| 1016 |
-
if tax_cat is not None:
|
| 1017 |
-
tax_rate = tax_cat.rate
|
| 1018 |
-
discount_percent = body.discount_percent if body.discount_percent is not None else 0.0
|
| 1019 |
-
gross = body.quantity * body.unit_price
|
| 1020 |
-
discount_amount = gross * (discount_percent / 100.0)
|
| 1021 |
-
line_subtotal = gross - discount_amount
|
| 1022 |
-
tax_amount = line_subtotal * tax_rate
|
| 1023 |
-
total = line_subtotal + tax_amount
|
| 1024 |
-
item = InvoiceLineItem(
|
| 1025 |
-
invoice_id=body.invoice_id,
|
| 1026 |
-
description=body.description,
|
| 1027 |
-
quantity=body.quantity,
|
| 1028 |
-
unit_price=body.unit_price,
|
| 1029 |
-
discount_percent=discount_percent,
|
| 1030 |
-
line_subtotal=line_subtotal,
|
| 1031 |
-
tax_amount=tax_amount,
|
| 1032 |
-
total=total,
|
| 1033 |
-
revenue_account_id=body.revenue_account_id,
|
| 1034 |
-
department_id=body.department_id if body.department_id is not None else (invoice.department_id if invoice is not None else None),
|
| 1035 |
-
created_at=datetime.utcnow(),
|
| 1036 |
-
updated_at=None,
|
| 1037 |
-
)
|
| 1038 |
-
session.add(item)
|
| 1039 |
-
if invoice is not None:
|
| 1040 |
-
subtotal_sum = session.query(InvoiceLineItem).filter(InvoiceLineItem.invoice_id == invoice.id).all()
|
| 1041 |
-
subtotal_value = 0.0
|
| 1042 |
-
tax_value = 0.0
|
| 1043 |
-
total_value = 0.0
|
| 1044 |
-
for li in subtotal_sum:
|
| 1045 |
-
subtotal_value += li.line_subtotal
|
| 1046 |
-
tax_value += li.tax_amount
|
| 1047 |
-
total_value += li.total
|
| 1048 |
-
subtotal_value += line_subtotal
|
| 1049 |
-
tax_value += tax_amount
|
| 1050 |
-
total_value += total
|
| 1051 |
-
invoice.subtotal = subtotal_value
|
| 1052 |
-
invoice.tax_amount = tax_value
|
| 1053 |
-
invoice.total = total_value
|
| 1054 |
-
payments = session.query(PaymentApplication).filter(PaymentApplication.invoice_id == invoice.id).all()
|
| 1055 |
-
paid_amount = 0.0
|
| 1056 |
-
for p in payments:
|
| 1057 |
-
paid_amount += p.amount
|
| 1058 |
-
invoice.balance_due = invoice.total - paid_amount
|
| 1059 |
-
invoice.updated_at = datetime.utcnow()
|
| 1060 |
-
session.commit()
|
| 1061 |
-
session.refresh(item)
|
| 1062 |
-
session.close()
|
| 1063 |
-
return InvoiceLineItemResponse(
|
| 1064 |
-
id=item.id,
|
| 1065 |
-
invoice_id=item.invoice_id,
|
| 1066 |
-
description=item.description,
|
| 1067 |
-
quantity=item.quantity,
|
| 1068 |
-
unit_price=item.unit_price,
|
| 1069 |
-
discount_percent=item.discount_percent,
|
| 1070 |
-
line_subtotal=item.line_subtotal,
|
| 1071 |
-
tax_amount=item.tax_amount,
|
| 1072 |
-
total=item.total,
|
| 1073 |
-
revenue_account_id=item.revenue_account_id,
|
| 1074 |
-
department_id=item.department_id,
|
| 1075 |
-
created_at=item.created_at,
|
| 1076 |
-
updated_at=item.updated_at,
|
| 1077 |
-
)
|
| 1078 |
-
|
| 1079 |
-
@app.post(
|
| 1080 |
-
"/api/invoices/{invoice_id}/recalculate_totals",
|
| 1081 |
-
response_model=InvoiceRecalculateTotalsResponse,
|
| 1082 |
-
summary="Recalculate invoice totals",
|
| 1083 |
-
description="Recompute totals from line items and applied payments.",
|
| 1084 |
-
tags=["invoices"],
|
| 1085 |
-
operation_id="recalculate_invoice_totals",
|
| 1086 |
-
)
|
| 1087 |
-
async def recalculate_invoice_totals_endpoint(
|
| 1088 |
-
invoice_id: int = Path(..., description="Invoice ID whose totals should be recalculated", example=1001)
|
| 1089 |
-
) -> InvoiceRecalculateTotalsResponse:
|
| 1090 |
-
session = SessionLocal()
|
| 1091 |
-
invoice = session.query(Invoice).filter(Invoice.id == invoice_id).first()
|
| 1092 |
-
if invoice is None:
|
| 1093 |
-
session.close()
|
| 1094 |
-
return InvoiceRecalculateTotalsResponse(invoice_id=0, subtotal=0.0, tax_amount=0.0, total=0.0, balance_due=0.0)
|
| 1095 |
-
lines = session.query(InvoiceLineItem).filter(InvoiceLineItem.invoice_id == invoice_id).all()
|
| 1096 |
-
subtotal = 0.0
|
| 1097 |
-
tax_amount = 0.0
|
| 1098 |
-
total = 0.0
|
| 1099 |
-
for li in lines:
|
| 1100 |
-
subtotal += li.line_subtotal
|
| 1101 |
-
tax_amount += li.tax_amount
|
| 1102 |
-
total += li.total
|
| 1103 |
-
payments = session.query(PaymentApplication).filter(PaymentApplication.invoice_id == invoice_id).all()
|
| 1104 |
-
paid_amount = 0.0
|
| 1105 |
-
for pa in payments:
|
| 1106 |
-
paid_amount += pa.amount
|
| 1107 |
-
invoice.subtotal = subtotal
|
| 1108 |
-
invoice.tax_amount = tax_amount
|
| 1109 |
-
invoice.total = total
|
| 1110 |
-
invoice.balance_due = total - paid_amount
|
| 1111 |
-
invoice.updated_at = datetime.utcnow()
|
| 1112 |
-
session.commit()
|
| 1113 |
-
session.close()
|
| 1114 |
-
return InvoiceRecalculateTotalsResponse(
|
| 1115 |
-
invoice_id=invoice_id,
|
| 1116 |
-
subtotal=subtotal,
|
| 1117 |
-
tax_amount=tax_amount,
|
| 1118 |
-
total=total,
|
| 1119 |
-
balance_due=invoice.balance_due,
|
| 1120 |
-
)
|
| 1121 |
-
|
| 1122 |
-
@app.get(
|
| 1123 |
-
"/api/invoices",
|
| 1124 |
-
response_model=InvoicesListResponse,
|
| 1125 |
-
summary="List invoices with filters",
|
| 1126 |
-
description="Retrieve invoices filtered by number, customer, status, or dates.",
|
| 1127 |
-
tags=["invoices"],
|
| 1128 |
-
operation_id="list_invoices",
|
| 1129 |
-
)
|
| 1130 |
-
async def list_invoices_endpoint(
|
| 1131 |
-
invoice_number: Optional[str] = Query(None, description="Filter by invoice_number", example="INV-2025-001"),
|
| 1132 |
-
customer_id: Optional[int] = Query(None, description="Filter invoices for a given customer ID", example=10),
|
| 1133 |
-
status: Optional[str] = Query(None, description="Filter by invoice status (draft, open, paid, void)", example="open"),
|
| 1134 |
-
from_date: Optional[str] = Query(None, description="Filter by minimum invoice_date (YYYY-MM-DD)", example="2025-01-01"),
|
| 1135 |
-
to_date: Optional[str] = Query(None, description="Filter by maximum invoice_date (YYYY-MM-DD)", example="2025-01-31"),
|
| 1136 |
-
limit: Optional[int] = Query(50, description="Max number of invoices to return", example=50),
|
| 1137 |
-
offset: Optional[int] = Query(0, description="Number of invoices to skip", example=0),
|
| 1138 |
-
) -> InvoicesListResponse:
|
| 1139 |
-
session = SessionLocal()
|
| 1140 |
-
query = session.query(Invoice)
|
| 1141 |
-
if invoice_number is not None:
|
| 1142 |
-
query = query.filter(Invoice.invoice_number == invoice_number)
|
| 1143 |
-
if customer_id is not None:
|
| 1144 |
-
query = query.filter(Invoice.customer_id == customer_id)
|
| 1145 |
-
if status is not None:
|
| 1146 |
-
query = query.filter(Invoice.status == status)
|
| 1147 |
-
if from_date is not None:
|
| 1148 |
-
query = query.filter(Invoice.invoice_date >= date.fromisoformat(from_date))
|
| 1149 |
-
if to_date is not None:
|
| 1150 |
-
query = query.filter(Invoice.invoice_date <= date.fromisoformat(to_date))
|
| 1151 |
-
invoices = query.offset(offset).limit(limit).all()
|
| 1152 |
-
session.close()
|
| 1153 |
-
return InvoicesListResponse(invoices=invoices)
|
| 1154 |
-
|
| 1155 |
-
@app.post(
|
| 1156 |
-
"/api/payments",
|
| 1157 |
-
response_model=PaymentResponse,
|
| 1158 |
-
summary="Record a customer payment",
|
| 1159 |
-
description="Create a payment row for a customer without allocations.",
|
| 1160 |
-
tags=["payments"],
|
| 1161 |
-
operation_id="create_payment",
|
| 1162 |
-
)
|
| 1163 |
-
async def create_payment_endpoint(body: PaymentCreateRequest = Body(...)) -> PaymentResponse:
|
| 1164 |
-
session = SessionLocal()
|
| 1165 |
-
payment = Payment(
|
| 1166 |
-
customer_id=body.customer_id,
|
| 1167 |
-
payment_date=date.fromisoformat(body.payment_date),
|
| 1168 |
-
settlement_date=date.fromisoformat(body.settlement_date) if body.settlement_date is not None else None,
|
| 1169 |
-
amount=body.amount,
|
| 1170 |
-
currency=body.currency if body.currency is not None else "USD",
|
| 1171 |
-
method=body.method,
|
| 1172 |
-
reference=body.reference,
|
| 1173 |
-
created_at=datetime.utcnow(),
|
| 1174 |
-
updated_at=None,
|
| 1175 |
-
)
|
| 1176 |
-
session.add(payment)
|
| 1177 |
-
session.commit()
|
| 1178 |
-
session.refresh(payment)
|
| 1179 |
-
session.close()
|
| 1180 |
-
return PaymentResponse(
|
| 1181 |
-
id=payment.id,
|
| 1182 |
-
customer_id=payment.customer_id,
|
| 1183 |
-
payment_date=payment.payment_date,
|
| 1184 |
-
settlement_date=payment.settlement_date,
|
| 1185 |
-
amount=payment.amount,
|
| 1186 |
-
currency=payment.currency,
|
| 1187 |
-
method=payment.method,
|
| 1188 |
-
reference=payment.reference,
|
| 1189 |
-
created_at=payment.created_at,
|
| 1190 |
-
updated_at=payment.updated_at,
|
| 1191 |
-
)
|
| 1192 |
-
|
| 1193 |
-
@app.post(
|
| 1194 |
-
"/api/payment_applications",
|
| 1195 |
-
response_model=PaymentApplicationResponse,
|
| 1196 |
-
summary="Apply a payment to an invoice",
|
| 1197 |
-
description="Allocate part or all of a payment amount to a specific invoice.",
|
| 1198 |
-
tags=["payments", "payment_applications"],
|
| 1199 |
-
operation_id="create_payment_application",
|
| 1200 |
-
)
|
| 1201 |
-
async def create_payment_application_endpoint(
|
| 1202 |
-
body: PaymentApplicationCreateRequest = Body(...)
|
| 1203 |
-
) -> PaymentApplicationResponse:
|
| 1204 |
-
session = SessionLocal()
|
| 1205 |
-
payment_app = PaymentApplication(
|
| 1206 |
-
payment_id=body.payment_id,
|
| 1207 |
-
invoice_id=body.invoice_id,
|
| 1208 |
-
amount=body.amount,
|
| 1209 |
-
created_at=datetime.utcnow(),
|
| 1210 |
-
updated_at=None,
|
| 1211 |
-
)
|
| 1212 |
-
session.add(payment_app)
|
| 1213 |
-
invoice = session.query(Invoice).filter(Invoice.id == body.invoice_id).first()
|
| 1214 |
-
if invoice is not None:
|
| 1215 |
-
payments = session.query(PaymentApplication).filter(PaymentApplication.invoice_id == body.invoice_id).all()
|
| 1216 |
-
total_applied = 0.0
|
| 1217 |
-
for p in payments:
|
| 1218 |
-
total_applied += p.amount
|
| 1219 |
-
total_applied += body.amount
|
| 1220 |
-
invoice.balance_due = invoice.total - total_applied
|
| 1221 |
-
if invoice.balance_due <= 0:
|
| 1222 |
-
invoice.status = "paid"
|
| 1223 |
-
invoice.updated_at = datetime.utcnow()
|
| 1224 |
-
session.commit()
|
| 1225 |
-
session.refresh(payment_app)
|
| 1226 |
-
session.close()
|
| 1227 |
-
return PaymentApplicationResponse(
|
| 1228 |
-
id=payment_app.id,
|
| 1229 |
-
payment_id=payment_app.payment_id,
|
| 1230 |
-
invoice_id=payment_app.invoice_id,
|
| 1231 |
-
amount=payment_app.amount,
|
| 1232 |
-
created_at=payment_app.created_at,
|
| 1233 |
-
updated_at=payment_app.updated_at,
|
| 1234 |
-
)
|
| 1235 |
-
|
| 1236 |
-
@app.post(
|
| 1237 |
-
"/api/vendors",
|
| 1238 |
-
response_model=VendorResponse,
|
| 1239 |
-
summary="Create a new vendor",
|
| 1240 |
-
description="Create a vendor with default payment terms and expense category.",
|
| 1241 |
-
tags=["vendors"],
|
| 1242 |
-
operation_id="create_vendor",
|
| 1243 |
-
)
|
| 1244 |
-
async def create_vendor_endpoint(body: VendorCreateRequest = Body(...)) -> VendorResponse:
|
| 1245 |
-
session = SessionLocal()
|
| 1246 |
-
vendor = Vendor(
|
| 1247 |
-
name=body.name,
|
| 1248 |
-
contact_email=body.contact_email,
|
| 1249 |
-
payment_terms_id=body.payment_terms_id,
|
| 1250 |
-
default_expense_category_id=body.default_expense_category_id,
|
| 1251 |
-
created_at=datetime.utcnow(),
|
| 1252 |
-
updated_at=None,
|
| 1253 |
-
)
|
| 1254 |
-
session.add(vendor)
|
| 1255 |
-
session.commit()
|
| 1256 |
-
session.refresh(vendor)
|
| 1257 |
-
session.close()
|
| 1258 |
-
return VendorResponse(
|
| 1259 |
-
id=vendor.id,
|
| 1260 |
-
name=vendor.name,
|
| 1261 |
-
contact_email=vendor.contact_email,
|
| 1262 |
-
payment_terms_id=vendor.payment_terms_id,
|
| 1263 |
-
default_expense_category_id=vendor.default_expense_category_id,
|
| 1264 |
-
created_at=vendor.created_at,
|
| 1265 |
-
updated_at=vendor.updated_at,
|
| 1266 |
-
)
|
| 1267 |
-
|
| 1268 |
-
@app.get(
|
| 1269 |
-
"/api/vendors",
|
| 1270 |
-
response_model=VendorsListResponse,
|
| 1271 |
-
summary="List vendors",
|
| 1272 |
-
description="Retrieve vendors to find IDs when creating bills.",
|
| 1273 |
-
tags=["vendors"],
|
| 1274 |
-
operation_id="list_vendors",
|
| 1275 |
-
)
|
| 1276 |
-
async def list_vendors_endpoint(
|
| 1277 |
-
name: Optional[str] = Query(None, description="Filter vendors by name", example="PixelPrint")
|
| 1278 |
-
) -> VendorsListResponse:
|
| 1279 |
-
session = SessionLocal()
|
| 1280 |
-
query = session.query(Vendor)
|
| 1281 |
-
if name is not None:
|
| 1282 |
-
query = query.filter(Vendor.name.contains(name))
|
| 1283 |
-
vendors = query.all()
|
| 1284 |
-
session.close()
|
| 1285 |
-
return VendorsListResponse(vendors=vendors)
|
| 1286 |
-
|
| 1287 |
-
@app.post(
|
| 1288 |
-
"/api/bills",
|
| 1289 |
-
response_model=BillResponse,
|
| 1290 |
-
summary="Create a bill",
|
| 1291 |
-
description="Create a bills row for vendor expenses.",
|
| 1292 |
-
tags=["bills"],
|
| 1293 |
-
operation_id="create_bill",
|
| 1294 |
-
)
|
| 1295 |
-
async def create_bill_endpoint(body: BillCreateRequest = Body(...)) -> BillResponse:
|
| 1296 |
-
session = SessionLocal()
|
| 1297 |
-
bill = Bill(
|
| 1298 |
-
bill_number=body.bill_number,
|
| 1299 |
-
vendor_id=body.vendor_id,
|
| 1300 |
-
bill_date=date.fromisoformat(body.bill_date),
|
| 1301 |
-
due_date=date.fromisoformat(body.due_date) if body.due_date is not None else None,
|
| 1302 |
-
currency=body.currency if body.currency is not None else "USD",
|
| 1303 |
-
amount=body.amount,
|
| 1304 |
-
description=body.description,
|
| 1305 |
-
department_id=body.department_id,
|
| 1306 |
-
reimbursement_status=body.reimbursement_status,
|
| 1307 |
-
payment_terms_id=body.payment_terms_id,
|
| 1308 |
-
status=body.status if body.status is not None else "open",
|
| 1309 |
-
created_at=datetime.utcnow(),
|
| 1310 |
-
updated_at=None,
|
| 1311 |
-
)
|
| 1312 |
-
session.add(bill)
|
| 1313 |
-
session.commit()
|
| 1314 |
-
session.refresh(bill)
|
| 1315 |
-
session.close()
|
| 1316 |
-
return BillResponse(
|
| 1317 |
-
id=bill.id,
|
| 1318 |
-
bill_number=bill.bill_number,
|
| 1319 |
-
vendor_id=bill.vendor_id,
|
| 1320 |
-
bill_date=bill.bill_date,
|
| 1321 |
-
due_date=bill.due_date,
|
| 1322 |
-
currency=bill.currency,
|
| 1323 |
-
amount=bill.amount,
|
| 1324 |
-
description=bill.description,
|
| 1325 |
-
department_id=bill.department_id,
|
| 1326 |
-
reimbursement_status=bill.reimbursement_status,
|
| 1327 |
-
payment_terms_id=bill.payment_terms_id,
|
| 1328 |
-
status=bill.status,
|
| 1329 |
-
created_at=bill.created_at,
|
| 1330 |
-
updated_at=bill.updated_at,
|
| 1331 |
-
)
|
| 1332 |
-
|
| 1333 |
-
@app.post(
|
| 1334 |
-
"/api/recurring_expenses",
|
| 1335 |
-
response_model=RecurringExpenseResponse,
|
| 1336 |
-
summary="Create a recurring expense template",
|
| 1337 |
-
description="Create recurring_expenses templates such as monthly rent.",
|
| 1338 |
-
tags=["recurring_expenses"],
|
| 1339 |
-
operation_id="create_recurring_expense",
|
| 1340 |
-
)
|
| 1341 |
-
async def create_recurring_expense_endpoint(
|
| 1342 |
-
body: RecurringExpenseCreateRequest = Body(...)
|
| 1343 |
-
) -> RecurringExpenseResponse:
|
| 1344 |
-
session = SessionLocal()
|
| 1345 |
-
recurring = RecurringExpense(
|
| 1346 |
-
name=body.name,
|
| 1347 |
-
vendor_id=body.vendor_id,
|
| 1348 |
-
amount=body.amount,
|
| 1349 |
-
expense_account_id=body.expense_account_id,
|
| 1350 |
-
department_id=body.department_id,
|
| 1351 |
-
frequency=body.frequency,
|
| 1352 |
-
next_run_date=date.fromisoformat(body.next_run_date),
|
| 1353 |
-
end_date=date.fromisoformat(body.end_date) if body.end_date is not None else None,
|
| 1354 |
-
is_active=1 if (body.is_active if body.is_active is not None else True) else 0,
|
| 1355 |
-
created_at=datetime.utcnow(),
|
| 1356 |
-
updated_at=None,
|
| 1357 |
-
)
|
| 1358 |
-
session.add(recurring)
|
| 1359 |
-
session.commit()
|
| 1360 |
-
session.refresh(recurring)
|
| 1361 |
-
session.close()
|
| 1362 |
-
return RecurringExpenseResponse(
|
| 1363 |
-
id=recurring.id,
|
| 1364 |
-
name=recurring.name,
|
| 1365 |
-
vendor_id=recurring.vendor_id,
|
| 1366 |
-
amount=recurring.amount,
|
| 1367 |
-
expense_account_id=recurring.expense_account_id,
|
| 1368 |
-
department_id=recurring.department_id,
|
| 1369 |
-
frequency=recurring.frequency,
|
| 1370 |
-
next_run_date=recurring.next_run_date,
|
| 1371 |
-
end_date=recurring.end_date,
|
| 1372 |
-
is_active=bool(recurring.is_active),
|
| 1373 |
-
created_at=recurring.created_at,
|
| 1374 |
-
updated_at=recurring.updated_at,
|
| 1375 |
-
)
|
| 1376 |
-
|
| 1377 |
-
@app.post(
|
| 1378 |
-
"/api/bank_transactions/batch_import",
|
| 1379 |
-
response_model=BankTransactionsBatchImportResponse,
|
| 1380 |
-
summary="Import a batch of bank transactions",
|
| 1381 |
-
description="Insert multiple bank_transactions for a bank account in one call.",
|
| 1382 |
-
tags=["bank_transactions"],
|
| 1383 |
-
operation_id="batch_import_bank_transactions",
|
| 1384 |
-
)
|
| 1385 |
-
async def batch_import_bank_transactions_endpoint(
|
| 1386 |
-
body: BankTransactionsBatchImportRequest = Body(...)
|
| 1387 |
-
) -> BankTransactionsBatchImportResponse:
|
| 1388 |
-
session = SessionLocal()
|
| 1389 |
-
created_items: List[BankTransactionResponse] = []
|
| 1390 |
-
for t in body.transactions:
|
| 1391 |
-
bt = BankTransaction(
|
| 1392 |
-
bank_account_id=body.bank_account_id,
|
| 1393 |
-
transaction_date=date.fromisoformat(t.transaction_date),
|
| 1394 |
-
posted_date=date.fromisoformat(t.posted_date) if t.posted_date is not None else None,
|
| 1395 |
-
description=t.description,
|
| 1396 |
-
amount=t.amount,
|
| 1397 |
-
external_id=t.external_id,
|
| 1398 |
-
created_at=datetime.utcnow(),
|
| 1399 |
-
updated_at=None,
|
| 1400 |
-
)
|
| 1401 |
-
session.add(bt)
|
| 1402 |
-
session.commit()
|
| 1403 |
-
session.refresh(bt)
|
| 1404 |
-
created_items.append(
|
| 1405 |
-
BankTransactionResponse(
|
| 1406 |
-
id=bt.id,
|
| 1407 |
-
bank_account_id=bt.bank_account_id,
|
| 1408 |
-
transaction_date=bt.transaction_date,
|
| 1409 |
-
posted_date=bt.posted_date,
|
| 1410 |
-
description=bt.description,
|
| 1411 |
-
amount=bt.amount,
|
| 1412 |
-
external_id=bt.external_id,
|
| 1413 |
-
created_at=bt.created_at,
|
| 1414 |
-
updated_at=bt.updated_at,
|
| 1415 |
-
)
|
| 1416 |
-
)
|
| 1417 |
-
session.close()
|
| 1418 |
-
return BankTransactionsBatchImportResponse(bank_transactions=created_items)
|
| 1419 |
-
|
| 1420 |
-
@app.get(
|
| 1421 |
-
"/api/bank_transactions",
|
| 1422 |
-
response_model=BankTransactionsListResponse,
|
| 1423 |
-
summary="List bank transactions",
|
| 1424 |
-
description="Retrieve bank_transactions for a bank account filtered by date.",
|
| 1425 |
-
tags=["bank_transactions"],
|
| 1426 |
-
operation_id="list_bank_transactions",
|
| 1427 |
-
)
|
| 1428 |
-
async def list_bank_transactions_endpoint(
|
| 1429 |
-
bank_account_id: int = Query(..., description="Bank account ID to filter transactions", example=1),
|
| 1430 |
-
from_date: Optional[str] = Query(None, description="Minimum transaction_date (YYYY-MM-DD)", example="2025-01-01"),
|
| 1431 |
-
to_date: Optional[str] = Query(None, description="Maximum transaction_date (YYYY-MM-DD)", example="2025-01-07"),
|
| 1432 |
-
limit: Optional[int] = Query(100, description="Maximum number of records", example=100),
|
| 1433 |
-
offset: Optional[int] = Query(0, description="Records to skip", example=0),
|
| 1434 |
-
) -> BankTransactionsListResponse:
|
| 1435 |
-
session = SessionLocal()
|
| 1436 |
-
query = session.query(BankTransaction).filter(BankTransaction.bank_account_id == bank_account_id)
|
| 1437 |
-
if from_date is not None:
|
| 1438 |
-
query = query.filter(BankTransaction.transaction_date >= date.fromisoformat(from_date))
|
| 1439 |
-
if to_date is not None:
|
| 1440 |
-
query = query.filter(BankTransaction.transaction_date <= date.fromisoformat(to_date))
|
| 1441 |
-
transactions = query.offset(offset).limit(limit).all()
|
| 1442 |
-
session.close()
|
| 1443 |
-
return BankTransactionsListResponse(bank_transactions=transactions)
|
| 1444 |
-
|
| 1445 |
-
@app.post(
|
| 1446 |
-
"/api/journal_entries",
|
| 1447 |
-
response_model=JournalEntryResponse,
|
| 1448 |
-
summary="Create a journal entry header",
|
| 1449 |
-
description="Create a journal_entries header with entry_date and description.",
|
| 1450 |
-
tags=["journal_entries"],
|
| 1451 |
-
operation_id="create_journal_entry",
|
| 1452 |
-
)
|
| 1453 |
-
async def create_journal_entry_endpoint(
|
| 1454 |
-
body: JournalEntryCreateRequest = Body(...)
|
| 1455 |
-
) -> JournalEntryResponse:
|
| 1456 |
-
session = SessionLocal()
|
| 1457 |
-
entry = JournalEntry(
|
| 1458 |
-
entry_date=date.fromisoformat(body.entry_date),
|
| 1459 |
-
description=body.description,
|
| 1460 |
-
department_id=body.department_id,
|
| 1461 |
-
source=body.source,
|
| 1462 |
-
source_id=body.source_id,
|
| 1463 |
-
created_by_user_id=1,
|
| 1464 |
-
created_at=datetime.utcnow(),
|
| 1465 |
-
updated_at=None,
|
| 1466 |
-
)
|
| 1467 |
-
session.add(entry)
|
| 1468 |
-
session.commit()
|
| 1469 |
-
session.refresh(entry)
|
| 1470 |
-
session.close()
|
| 1471 |
-
return JournalEntryResponse(
|
| 1472 |
-
id=entry.id,
|
| 1473 |
-
entry_date=entry.entry_date,
|
| 1474 |
-
description=entry.description,
|
| 1475 |
-
department_id=entry.department_id,
|
| 1476 |
-
source=entry.source,
|
| 1477 |
-
source_id=entry.source_id,
|
| 1478 |
-
created_by_user_id=entry.created_by_user_id,
|
| 1479 |
-
created_at=entry.created_at,
|
| 1480 |
-
updated_at=entry.updated_at,
|
| 1481 |
-
)
|
| 1482 |
-
|
| 1483 |
-
@app.post(
|
| 1484 |
-
"/api/journal_entry_lines",
|
| 1485 |
-
response_model=JournalEntryLineResponse,
|
| 1486 |
-
summary="Add a line to a journal entry",
|
| 1487 |
-
description="Create a journal_entry_lines row for an account with debit or credit.",
|
| 1488 |
-
tags=["journal_entries", "journal_entry_lines"],
|
| 1489 |
-
operation_id="create_journal_entry_line",
|
| 1490 |
-
)
|
| 1491 |
-
async def create_journal_entry_line_endpoint(
|
| 1492 |
-
body: JournalEntryLineCreateRequest = Body(...)
|
| 1493 |
-
) -> JournalEntryLineResponse:
|
| 1494 |
-
session = SessionLocal()
|
| 1495 |
-
debit_value = body.debit if body.debit is not None else 0.0
|
| 1496 |
-
credit_value = body.credit if body.credit is not None else 0.0
|
| 1497 |
-
line = JournalEntryLine(
|
| 1498 |
-
journal_entry_id=body.journal_entry_id,
|
| 1499 |
-
account_id=body.account_id,
|
| 1500 |
-
department_id=body.department_id,
|
| 1501 |
-
description=body.description,
|
| 1502 |
-
debit=debit_value,
|
| 1503 |
-
credit=credit_value,
|
| 1504 |
-
created_at=datetime.utcnow(),
|
| 1505 |
-
updated_at=None,
|
| 1506 |
-
)
|
| 1507 |
-
session.add(line)
|
| 1508 |
-
session.commit()
|
| 1509 |
-
session.refresh(line)
|
| 1510 |
-
session.close()
|
| 1511 |
-
return JournalEntryLineResponse(
|
| 1512 |
-
id=line.id,
|
| 1513 |
-
journal_entry_id=line.journal_entry_id,
|
| 1514 |
-
account_id=line.account_id,
|
| 1515 |
-
department_id=line.department_id,
|
| 1516 |
-
description=line.description,
|
| 1517 |
-
debit=line.debit,
|
| 1518 |
-
credit=line.credit,
|
| 1519 |
-
created_at=line.created_at,
|
| 1520 |
-
updated_at=line.updated_at,
|
| 1521 |
-
)
|
| 1522 |
-
|
| 1523 |
-
@app.post(
|
| 1524 |
-
"/api/bank_transaction_journal_links",
|
| 1525 |
-
response_model=BankTransactionJournalLinkResponse,
|
| 1526 |
-
summary="Link a bank transaction to a journal entry",
|
| 1527 |
-
description="Create a bank_transaction_journal_links row to connect bank_transactions with journal_entries.",
|
| 1528 |
-
tags=["bank_transactions", "journal_entries"],
|
| 1529 |
-
operation_id="create_bank_transaction_journal_link",
|
| 1530 |
-
)
|
| 1531 |
-
async def create_bank_transaction_journal_link_endpoint(
|
| 1532 |
-
body: BankTransactionJournalLinkCreateRequest = Body(...)
|
| 1533 |
-
) -> BankTransactionJournalLinkResponse:
|
| 1534 |
-
session = SessionLocal()
|
| 1535 |
-
link = BankTransactionJournalLink(
|
| 1536 |
-
bank_transaction_id=body.bank_transaction_id,
|
| 1537 |
-
journal_entry_id=body.journal_entry_id,
|
| 1538 |
-
created_at=datetime.utcnow(),
|
| 1539 |
-
)
|
| 1540 |
-
session.add(link)
|
| 1541 |
-
session.commit()
|
| 1542 |
-
session.refresh(link)
|
| 1543 |
-
session.close()
|
| 1544 |
-
return BankTransactionJournalLinkResponse(
|
| 1545 |
-
id=link.id,
|
| 1546 |
-
bank_transaction_id=link.bank_transaction_id,
|
| 1547 |
-
journal_entry_id=link.journal_entry_id,
|
| 1548 |
-
created_at=link.created_at,
|
| 1549 |
-
)
|
| 1550 |
-
|
| 1551 |
-
@app.post(
|
| 1552 |
-
"/api/recurring_invoices",
|
| 1553 |
-
response_model=RecurringInvoiceResponse,
|
| 1554 |
-
summary="Create a recurring invoice schedule",
|
| 1555 |
-
description="Create a recurring_invoices template specifying settings.",
|
| 1556 |
-
tags=["recurring_invoices"],
|
| 1557 |
-
operation_id="create_recurring_invoice",
|
| 1558 |
-
)
|
| 1559 |
-
async def create_recurring_invoice_endpoint(
|
| 1560 |
-
body: RecurringInvoiceCreateRequest = Body(...)
|
| 1561 |
-
) -> RecurringInvoiceResponse:
|
| 1562 |
-
session = SessionLocal()
|
| 1563 |
-
recurring = RecurringInvoice(
|
| 1564 |
-
customer_id=body.customer_id,
|
| 1565 |
-
name=body.name,
|
| 1566 |
-
description=body.description,
|
| 1567 |
-
quantity=body.quantity,
|
| 1568 |
-
unit_price=body.unit_price,
|
| 1569 |
-
discount_percent=body.discount_percent if body.discount_percent is not None else 0.0,
|
| 1570 |
-
frequency=body.frequency,
|
| 1571 |
-
next_run_date=date.fromisoformat(body.next_run_date),
|
| 1572 |
-
end_date=date.fromisoformat(body.end_date) if body.end_date is not None else None,
|
| 1573 |
-
payment_terms_id=body.payment_terms_id,
|
| 1574 |
-
tax_category_id=body.tax_category_id,
|
| 1575 |
-
department_id=body.department_id,
|
| 1576 |
-
currency=body.currency if body.currency is not None else "USD",
|
| 1577 |
-
is_active=1 if (body.is_active if body.is_active is not None else True) else 0,
|
| 1578 |
-
created_at=datetime.utcnow(),
|
| 1579 |
-
updated_at=None,
|
| 1580 |
-
)
|
| 1581 |
-
session.add(recurring)
|
| 1582 |
-
session.commit()
|
| 1583 |
-
session.refresh(recurring)
|
| 1584 |
-
session.close()
|
| 1585 |
-
return RecurringInvoiceResponse(
|
| 1586 |
-
id=recurring.id,
|
| 1587 |
-
customer_id=recurring.customer_id,
|
| 1588 |
-
name=recurring.name,
|
| 1589 |
-
description=recurring.description,
|
| 1590 |
-
quantity=recurring.quantity,
|
| 1591 |
-
unit_price=recurring.unit_price,
|
| 1592 |
-
discount_percent=recurring.discount_percent,
|
| 1593 |
-
frequency=recurring.frequency,
|
| 1594 |
-
next_run_date=recurring.next_run_date,
|
| 1595 |
-
end_date=recurring.end_date,
|
| 1596 |
-
payment_terms_id=recurring.payment_terms_id,
|
| 1597 |
-
tax_category_id=recurring.tax_category_id,
|
| 1598 |
-
department_id=recurring.department_id,
|
| 1599 |
-
currency=recurring.currency,
|
| 1600 |
-
is_active=bool(recurring.is_active),
|
| 1601 |
-
created_at=recurring.created_at,
|
| 1602 |
-
updated_at=recurring.updated_at,
|
| 1603 |
-
)
|
| 1604 |
-
|
| 1605 |
-
@app.post(
|
| 1606 |
-
"/api/accounting_periods",
|
| 1607 |
-
response_model=AccountingPeriodResponse,
|
| 1608 |
-
summary="Create an accounting period",
|
| 1609 |
-
description="Create an accounting_periods row representing a fiscal period.",
|
| 1610 |
-
tags=["accounting_periods"],
|
| 1611 |
-
operation_id="create_accounting_period",
|
| 1612 |
-
)
|
| 1613 |
-
async def create_accounting_period_endpoint(
|
| 1614 |
-
body: AccountingPeriodCreateRequest = Body(...)
|
| 1615 |
-
) -> AccountingPeriodResponse:
|
| 1616 |
-
session = SessionLocal()
|
| 1617 |
-
period = AccountingPeriod(
|
| 1618 |
-
start_date=date.fromisoformat(body.start_date),
|
| 1619 |
-
end_date=date.fromisoformat(body.end_date),
|
| 1620 |
-
close_date=date.fromisoformat(body.close_date) if body.close_date is not None else None,
|
| 1621 |
-
is_locked=1 if (body.is_locked if body.is_locked is not None else False) else 0,
|
| 1622 |
-
created_at=datetime.utcnow(),
|
| 1623 |
-
updated_at=None,
|
| 1624 |
-
)
|
| 1625 |
-
session.add(period)
|
| 1626 |
-
session.commit()
|
| 1627 |
-
session.refresh(period)
|
| 1628 |
-
session.close()
|
| 1629 |
-
return AccountingPeriodResponse(
|
| 1630 |
-
id=period.id,
|
| 1631 |
-
start_date=period.start_date,
|
| 1632 |
-
end_date=period.end_date,
|
| 1633 |
-
close_date=period.close_date,
|
| 1634 |
-
is_locked=bool(period.is_locked),
|
| 1635 |
-
created_at=period.created_at,
|
| 1636 |
-
updated_at=period.updated_at,
|
| 1637 |
-
)
|
| 1638 |
-
|
| 1639 |
-
@app.patch(
|
| 1640 |
-
"/api/accounting_periods/{period_id}",
|
| 1641 |
-
response_model=AccountingPeriodResponse,
|
| 1642 |
-
summary="Update an accounting period lock status",
|
| 1643 |
-
description="Update close_date and is_locked for an accounting period.",
|
| 1644 |
-
tags=["accounting_periods"],
|
| 1645 |
-
operation_id="update_accounting_period_lock",
|
| 1646 |
-
)
|
| 1647 |
-
async def update_accounting_period_lock_endpoint(
|
| 1648 |
-
period_id: int = Path(..., description="Accounting period ID to update", example=10001),
|
| 1649 |
-
body: AccountingPeriodUpdateRequest = Body(...),
|
| 1650 |
-
) -> AccountingPeriodResponse:
|
| 1651 |
-
session = SessionLocal()
|
| 1652 |
-
period = session.query(AccountingPeriod).filter(AccountingPeriod.id == period_id).first()
|
| 1653 |
-
if period is None:
|
| 1654 |
-
session.close()
|
| 1655 |
-
return AccountingPeriodResponse(
|
| 1656 |
-
id=0,
|
| 1657 |
-
start_date=date.fromisoformat("1970-01-01"),
|
| 1658 |
-
end_date=date.fromisoformat("1970-01-01"),
|
| 1659 |
-
close_date=None,
|
| 1660 |
-
is_locked=False,
|
| 1661 |
-
created_at=None,
|
| 1662 |
-
updated_at=None,
|
| 1663 |
-
)
|
| 1664 |
-
if body.close_date is not None:
|
| 1665 |
-
period.close_date = date.fromisoformat(body.close_date)
|
| 1666 |
-
if body.close_date is None and body.close_date is not ...:
|
| 1667 |
-
if body.close_date is None:
|
| 1668 |
-
period.close_date = None
|
| 1669 |
-
if body.is_locked is not None:
|
| 1670 |
-
period.is_locked = 1 if body.is_locked else 0
|
| 1671 |
-
period.updated_at = datetime.utcnow()
|
| 1672 |
-
session.commit()
|
| 1673 |
-
session.refresh(period)
|
| 1674 |
-
session.close()
|
| 1675 |
-
return AccountingPeriodResponse(
|
| 1676 |
-
id=period.id,
|
| 1677 |
-
start_date=period.start_date,
|
| 1678 |
-
end_date=period.end_date,
|
| 1679 |
-
close_date=period.close_date,
|
| 1680 |
-
is_locked=bool(period.is_locked),
|
| 1681 |
-
created_at=period.created_at,
|
| 1682 |
-
updated_at=period.updated_at,
|
| 1683 |
-
)
|
| 1684 |
-
|
| 1685 |
-
@app.get(
|
| 1686 |
-
"/api/reports/profit_and_loss",
|
| 1687 |
-
response_model=ProfitAndLossReportResponse,
|
| 1688 |
-
summary="Generate a profit and loss report",
|
| 1689 |
-
description="Compute revenue, expenses, and net profit for a date range.",
|
| 1690 |
-
tags=["reports"],
|
| 1691 |
-
operation_id="generate_profit_and_loss",
|
| 1692 |
-
)
|
| 1693 |
-
async def generate_profit_and_loss_endpoint(
|
| 1694 |
-
start_date: str = Query(..., description="Start date for the report (YYYY-MM-DD)", example="2025-01-01"),
|
| 1695 |
-
end_date: str = Query(..., description="End date for the report (YYYY-MM-DD)", example="2025-01-31"),
|
| 1696 |
-
department_id: Optional[int] = Query(None, description="Optional department filter to restrict results", example=2),
|
| 1697 |
-
) -> ProfitAndLossReportResponse:
|
| 1698 |
-
session = SessionLocal()
|
| 1699 |
-
start = date.fromisoformat(start_date)
|
| 1700 |
-
end = date.fromisoformat(end_date)
|
| 1701 |
-
entries_query = session.query(JournalEntry).filter(
|
| 1702 |
-
JournalEntry.entry_date >= start, JournalEntry.entry_date <= end
|
| 1703 |
-
)
|
| 1704 |
-
if department_id is not None:
|
| 1705 |
-
entries_query = entries_query.filter(JournalEntry.department_id == department_id)
|
| 1706 |
-
entries = entries_query.all()
|
| 1707 |
-
entry_ids = [e.id for e in entries]
|
| 1708 |
-
lines_query = session.query(JournalEntryLine).filter(JournalEntryLine.journal_entry_id.in_(entry_ids)) if entry_ids else session.query(JournalEntryLine).filter(JournalEntryLine.id == -1)
|
| 1709 |
-
if department_id is not None:
|
| 1710 |
-
lines_query = lines_query.filter(
|
| 1711 |
-
(JournalEntryLine.department_id == department_id) | (JournalEntryLine.department_id.is_(None))
|
| 1712 |
-
)
|
| 1713 |
-
lines = lines_query.all()
|
| 1714 |
-
account_ids = list({l.account_id for l in lines})
|
| 1715 |
-
accounts = {}
|
| 1716 |
-
if account_ids:
|
| 1717 |
-
account_rows = session.query(Account).filter(Account.id.in_(account_ids)).all()
|
| 1718 |
-
for a in account_rows:
|
| 1719 |
-
accounts[a.id] = a
|
| 1720 |
-
total_revenue = 0.0
|
| 1721 |
-
total_expenses = 0.0
|
| 1722 |
-
income_details: List[Dict[str, Optional[float]]] = []
|
| 1723 |
-
expense_details: List[Dict[str, Optional[float]]] = []
|
| 1724 |
-
income_map: Dict[int, float] = {}
|
| 1725 |
-
expense_map: Dict[int, float] = {}
|
| 1726 |
-
for l in lines:
|
| 1727 |
-
a = accounts.get(l.account_id)
|
| 1728 |
-
if a is None:
|
| 1729 |
-
continue
|
| 1730 |
-
net_amount = l.debit - l.credit
|
| 1731 |
-
if a.type == "income":
|
| 1732 |
-
amount = -net_amount
|
| 1733 |
-
total_revenue += amount
|
| 1734 |
-
income_map[a.id] = income_map.get(a.id, 0.0) + amount
|
| 1735 |
-
if a.type == "expense":
|
| 1736 |
-
amount = net_amount
|
| 1737 |
-
total_expenses += amount
|
| 1738 |
-
expense_map[a.id] = expense_map.get(a.id, 0.0) + amount
|
| 1739 |
-
for aid, amt in income_map.items():
|
| 1740 |
-
a = accounts.get(aid)
|
| 1741 |
-
if a is not None:
|
| 1742 |
-
income_details.append({"account_id": float(a.id), "account_name": a.name, "amount": amt})
|
| 1743 |
-
for aid, amt in expense_map.items():
|
| 1744 |
-
a = accounts.get(aid)
|
| 1745 |
-
if a is not None:
|
| 1746 |
-
expense_details.append({"account_id": float(a.id), "account_name": a.name, "amount": amt})
|
| 1747 |
-
net_profit = total_revenue - total_expenses
|
| 1748 |
-
session.close()
|
| 1749 |
-
detail = {
|
| 1750 |
-
"income_accounts": income_details,
|
| 1751 |
-
"expense_accounts": expense_details,
|
| 1752 |
-
}
|
| 1753 |
-
return ProfitAndLossReportResponse(
|
| 1754 |
-
start_date=start_date,
|
| 1755 |
-
end_date=end_date,
|
| 1756 |
-
department_id=department_id,
|
| 1757 |
-
total_revenue=total_revenue,
|
| 1758 |
-
total_expenses=total_expenses,
|
| 1759 |
-
net_profit=net_profit,
|
| 1760 |
-
detail=detail,
|
| 1761 |
-
)
|
| 1762 |
-
|
| 1763 |
-
if __name__ == "__main__":
|
| 1764 |
-
import uvicorn, os
|
| 1765 |
-
host = os.getenv("HOST", "127.0.0.1")
|
| 1766 |
-
port = int(os.getenv("PORT", "8000"))
|
| 1767 |
-
uvicorn.run(app, host=host, port=port)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
components/awm/private/tasks/awm-accounting-1-invoice/original_verifier.py
DELETED
|
@@ -1,145 +0,0 @@
|
|
| 1 |
-
def verify_task_completion(initial_db_path: str, final_db_path: str, final_answer: str | None = None) -> dict:
|
| 2 |
-
import sqlite3
|
| 3 |
-
|
| 4 |
-
def safe_query(db_path: str, query: str, params: tuple = ()) -> list:
|
| 5 |
-
try:
|
| 6 |
-
conn = sqlite3.connect(f"file:{db_path}?mode=ro", uri=True)
|
| 7 |
-
cursor = conn.cursor()
|
| 8 |
-
cursor.execute(query, params)
|
| 9 |
-
results = cursor.fetchall()
|
| 10 |
-
conn.close()
|
| 11 |
-
return results
|
| 12 |
-
except Exception:
|
| 13 |
-
return []
|
| 14 |
-
|
| 15 |
-
# Get customer_id for 'Acme Design Studio'
|
| 16 |
-
customer_query = "SELECT id FROM customers WHERE name = 'Acme Design Studio'"
|
| 17 |
-
customer_result = safe_query(final_db_path, customer_query)
|
| 18 |
-
if not customer_result:
|
| 19 |
-
return {"result": "others"}
|
| 20 |
-
customer_id = customer_result[0][0]
|
| 21 |
-
|
| 22 |
-
# Get department_id for 'Design'
|
| 23 |
-
dept_query = "SELECT id FROM departments WHERE name = 'Design'"
|
| 24 |
-
dept_result = safe_query(final_db_path, dept_query)
|
| 25 |
-
if not dept_result:
|
| 26 |
-
return {"result": "others"}
|
| 27 |
-
dept_id = dept_result[0][0]
|
| 28 |
-
|
| 29 |
-
# Get tax_category_id for 'Standard Sales Tax 8.5%'
|
| 30 |
-
tax_query = "SELECT id, rate FROM tax_categories WHERE name = 'Standard Sales Tax 8.5%'"
|
| 31 |
-
tax_result = safe_query(final_db_path, tax_query)
|
| 32 |
-
if not tax_result:
|
| 33 |
-
return {"result": "others"}
|
| 34 |
-
tax_category_id = tax_result[0][0]
|
| 35 |
-
tax_rate = tax_result[0][1]
|
| 36 |
-
|
| 37 |
-
# Find invoices in initial state for this customer with these dates
|
| 38 |
-
initial_invoice_query = """SELECT id FROM invoices
|
| 39 |
-
WHERE customer_id = ? AND invoice_date = '2025-01-05' AND due_date = '2025-02-04'
|
| 40 |
-
AND department_id = ? AND tax_category_id = ?"""
|
| 41 |
-
initial_invoices = safe_query(initial_db_path, initial_invoice_query,
|
| 42 |
-
(customer_id, dept_id, tax_category_id))
|
| 43 |
-
|
| 44 |
-
# Find invoices in final state for this customer with these dates
|
| 45 |
-
final_invoice_query = """SELECT id, subtotal, tax_amount, total FROM invoices
|
| 46 |
-
WHERE customer_id = ? AND invoice_date = '2025-01-05' AND due_date = '2025-02-04'
|
| 47 |
-
AND department_id = ? AND tax_category_id = ?"""
|
| 48 |
-
final_invoices = safe_query(final_db_path, final_invoice_query,
|
| 49 |
-
(customer_id, dept_id, tax_category_id))
|
| 50 |
-
|
| 51 |
-
# Check if a new invoice was created
|
| 52 |
-
if len(final_invoices) <= len(initial_invoices):
|
| 53 |
-
return {"result": "others"}
|
| 54 |
-
|
| 55 |
-
# Find the newly created invoice(s)
|
| 56 |
-
initial_invoice_ids = set(inv[0] for inv in initial_invoices)
|
| 57 |
-
new_invoices = [inv for inv in final_invoices if inv[0] not in initial_invoice_ids]
|
| 58 |
-
|
| 59 |
-
if not new_invoices:
|
| 60 |
-
return {"result": "others"}
|
| 61 |
-
|
| 62 |
-
# Check each new invoice to find one that matches our requirements
|
| 63 |
-
for invoice in new_invoices:
|
| 64 |
-
invoice_id = invoice[0]
|
| 65 |
-
invoice_subtotal = invoice[1]
|
| 66 |
-
invoice_tax = invoice[2]
|
| 67 |
-
invoice_total = invoice[3]
|
| 68 |
-
|
| 69 |
-
# Get line items for this invoice
|
| 70 |
-
line_items_query = """SELECT description, quantity, unit_price, discount_percent,
|
| 71 |
-
line_subtotal, tax_amount, total, department_id
|
| 72 |
-
FROM invoice_line_items WHERE invoice_id = ? ORDER BY id"""
|
| 73 |
-
line_items = safe_query(final_db_path, line_items_query, (invoice_id,))
|
| 74 |
-
|
| 75 |
-
# Must have exactly 2 line items
|
| 76 |
-
if len(line_items) != 2:
|
| 77 |
-
continue
|
| 78 |
-
|
| 79 |
-
# Check first line item: 'Logo redesign'
|
| 80 |
-
item1 = line_items[0]
|
| 81 |
-
if item1[0] != 'Logo redesign':
|
| 82 |
-
continue
|
| 83 |
-
if abs(item1[1] - 1.0) > 0.001: # quantity
|
| 84 |
-
continue
|
| 85 |
-
if abs(item1[2] - 1200.0) > 0.001: # unit_price
|
| 86 |
-
continue
|
| 87 |
-
if abs(item1[3] - 0.0) > 0.001: # discount_percent
|
| 88 |
-
continue
|
| 89 |
-
if item1[7] != dept_id: # department_id
|
| 90 |
-
continue
|
| 91 |
-
|
| 92 |
-
# Calculate expected values for item1
|
| 93 |
-
expected_subtotal1 = 1200.0 * 1.0 * (1 - 0.0 / 100.0)
|
| 94 |
-
expected_tax1 = expected_subtotal1 * tax_rate
|
| 95 |
-
expected_total1 = expected_subtotal1 + expected_tax1
|
| 96 |
-
|
| 97 |
-
if abs(item1[4] - expected_subtotal1) > 0.01: # line_subtotal
|
| 98 |
-
continue
|
| 99 |
-
if abs(item1[5] - expected_tax1) > 0.01: # tax_amount
|
| 100 |
-
continue
|
| 101 |
-
if abs(item1[6] - expected_total1) > 0.01: # total
|
| 102 |
-
continue
|
| 103 |
-
|
| 104 |
-
# Check second line item: 'Brand guideline document'
|
| 105 |
-
item2 = line_items[1]
|
| 106 |
-
if item2[0] != 'Brand guideline document':
|
| 107 |
-
continue
|
| 108 |
-
if abs(item2[1] - 1.0) > 0.001: # quantity
|
| 109 |
-
continue
|
| 110 |
-
if abs(item2[2] - 800.0) > 0.001: # unit_price
|
| 111 |
-
continue
|
| 112 |
-
if abs(item2[3] - 10.0) > 0.001: # discount_percent
|
| 113 |
-
continue
|
| 114 |
-
if item2[7] != dept_id: # department_id
|
| 115 |
-
continue
|
| 116 |
-
|
| 117 |
-
# Calculate expected values for item2
|
| 118 |
-
expected_subtotal2 = 800.0 * 1.0 * (1 - 10.0 / 100.0)
|
| 119 |
-
expected_tax2 = expected_subtotal2 * tax_rate
|
| 120 |
-
expected_total2 = expected_subtotal2 + expected_tax2
|
| 121 |
-
|
| 122 |
-
if abs(item2[4] - expected_subtotal2) > 0.01: # line_subtotal
|
| 123 |
-
continue
|
| 124 |
-
if abs(item2[5] - expected_tax2) > 0.01: # tax_amount
|
| 125 |
-
continue
|
| 126 |
-
if abs(item2[6] - expected_total2) > 0.01: # total
|
| 127 |
-
continue
|
| 128 |
-
|
| 129 |
-
# Verify invoice totals match sum of line items
|
| 130 |
-
total_subtotal = expected_subtotal1 + expected_subtotal2
|
| 131 |
-
total_tax = expected_tax1 + expected_tax2
|
| 132 |
-
total_amount = expected_total1 + expected_total2
|
| 133 |
-
|
| 134 |
-
if abs(invoice_subtotal - total_subtotal) > 0.01:
|
| 135 |
-
continue
|
| 136 |
-
if abs(invoice_tax - total_tax) > 0.01:
|
| 137 |
-
continue
|
| 138 |
-
if abs(invoice_total - total_amount) > 0.01:
|
| 139 |
-
continue
|
| 140 |
-
|
| 141 |
-
# All checks passed for this invoice
|
| 142 |
-
return {"result": "complete"}
|
| 143 |
-
|
| 144 |
-
# No invoice matched all requirements
|
| 145 |
-
return {"result": "others"}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
components/awm/requirements.lock
DELETED
|
@@ -1,112 +0,0 @@
|
|
| 1 |
-
# Linux/amd64 CPython 3.12 wheel lock. Offline inputs: vendor/build-manifest.json.
|
| 2 |
-
# OpenEnv source commit: 86a180ede21e044f7929b9a7783ad83aa67d83a3.
|
| 3 |
-
aiofile==3.12.3 --hash=sha256:5c1bcc9e929c50834608e8cc1a4cc1d7503eb60c15a535b779fd39e2f372c017
|
| 4 |
-
annotated-doc==0.0.5 --hash=sha256:117bac03a25ede5df5440e855b32d556049ca169ead221505badf432fed4b101
|
| 5 |
-
annotated-types==0.8.0 --hash=sha256:f072f4d804ea359e4eaf198b1af7a8b0943881a87f31bb764f8bf219bb9419e0
|
| 6 |
-
anyio==4.15.1 --hash=sha256:6152fdbbf9a77fdec97731721bebf7c4c44f7c29b424b0065826173efc7ed101
|
| 7 |
-
attrs==26.1.0 --hash=sha256:c647aa4a12dfbad9333ca4e71fe62ddc36f4e63b2d260a37a8b83d2f043ac309
|
| 8 |
-
Authlib==1.8.0 --hash=sha256:88aebbd9af6757e14e912d5dc007ae1dc1f3e27e3b2152ce7c552ee2c3b3c121
|
| 9 |
-
beartype==0.22.9 --hash=sha256:d16c9bbc61ea14637596c5f6fbff2ee99cbe3573e46a716401734ef50c3060c2
|
| 10 |
-
brotli==1.2.0 --hash=sha256:072e7624b1fc4d601036ab3f4f27942ef772887e876beff0301d261210bca97f
|
| 11 |
-
cachetools==7.2.1 --hash=sha256:63aa53dfe7473c10cccdd5a01dedf76ef2c4b73a58840d9396e7d0752cbdac3b
|
| 12 |
-
caio==0.12.9 --hash=sha256:bf12d4f014b2a33e642ed7905b5787656ede2fc24be21f7c086826ff0d32cec3
|
| 13 |
-
certifi==2026.7.22 --hash=sha256:62f22742b58a1a33014a2b6b706588a8d7e2a88ae7bd1a6ebe8c992928483775
|
| 14 |
-
cffi==2.1.1 --hash=sha256:c1453022f490d2459a11819d83ad1d586e9ff65a12ac3e705ffebd46d3685dcf
|
| 15 |
-
charset-normalizer==3.5.2 --hash=sha256:3d31298449090ab8d47b7b1b2a555ff73cac7ed438a08b7ac160980c7ebed649
|
| 16 |
-
click==8.5.0 --hash=sha256:255bc9599cf7748b4b1a446ccc735421bd08a2ae529a8b88597d3de5664ee360
|
| 17 |
-
cryptography==50.0.2 --hash=sha256:4061c0079120205fb760c58acab6443e217307dcf05e3702cf970e0689972856
|
| 18 |
-
cyclopts==5.2.0 --hash=sha256:5da2a5d65164e03008621fc4795946b88a722b881398b5dfa58afa6218342cff
|
| 19 |
-
dnspython==2.9.0 --hash=sha256:9a4aedb833c3c1b49214d04d44d3032ab7a9135f7c1d29a549b4ff78fd82fda9
|
| 20 |
-
docstring_parser==0.18.0 --hash=sha256:b3fcbed555c47d8479be0796ef7e19c2670d428d72e96da63f3a40122860374b
|
| 21 |
-
email-validator==2.3.0 --hash=sha256:80f13f623413e6b197ae73bb10bf4eb0908faf509ad8362c5edeb0be7fd450b4
|
| 22 |
-
exceptiongroup==1.3.1 --hash=sha256:a7a39a3bd276781e98394987d3a5701d0c4edffb633bb7a5144577f82c773598
|
| 23 |
-
fastapi==0.143.0 --hash=sha256:3e9395fd35276425b61b516a31fdd7c77fe2af83e41b4da22e30696fb1304c5d
|
| 24 |
-
fastmcp==3.4.8 --hash=sha256:ab4e8abe6c9d50b110f367e8c29f82b90c1478ac9180be61af10354f84f0ad8c
|
| 25 |
-
fastmcp-slim==3.4.8 --hash=sha256:e72c6b74e90c5dcdc8f58087fbdf213636d8b5d339384a498de1c5df6fc037a7
|
| 26 |
-
filelock==4.1.0 --hash=sha256:2ce9818e3e2d8f284c1a964414447ef148d42a5fd5e2a477a7118e574b293ec1
|
| 27 |
-
fsspec==2026.9.0 --hash=sha256:8dd6e646e99ea382bd85f97a45e6b526a442d79423a7dc673f1e2756d05fcb5f
|
| 28 |
-
gradio==6.30.0 --hash=sha256:aae3aa81ec9f44e55781b498ad2ba12b117aa512e8d2bb0ef3e52af7f2ee6305
|
| 29 |
-
gradio_client==2.7.2 --hash=sha256:12c9d2d940df28eb8dce58eef61f5e808265ad87bbbca53704d1330aa701e5e2
|
| 30 |
-
griffelib==2.3.2 --hash=sha256:8e710afededd5607f95bf3c8ccc175ee306e7084459faf27b9f9f44ef2a7a274
|
| 31 |
-
groovy==0.1.2 --hash=sha256:7f7975bab18c729a257a8b1ae9dcd70b7cafb1720481beae47719af57c35fa64
|
| 32 |
-
h11==0.16.0 --hash=sha256:63cf8bbe7522de3bf65932fda1d9c2772064ffb3dae62d55932da54b31cb6c86
|
| 33 |
-
hf-gradio==0.4.1 --hash=sha256:76b8cb8be6abe62d74c1ad2d35b42f0629db89aa9e1a8d033cecfe7c856eeab3
|
| 34 |
-
hf-xet==1.7.0 --hash=sha256:2814a6e999d13464c4d679b788cc5d784eb5a4edfc638a31f10e9a11ab531ef8
|
| 35 |
-
httpcore==1.0.9 --hash=sha256:2d400746a40668fc9dec9810239072b40b4484b640a8c38fd654a024c7a1bf55
|
| 36 |
-
httpcore2==2.13.1 --hash=sha256:e1e05d4f25f7d7d496bfb96748f6f4b67657b03da069b3a68c36069f3db73d0a
|
| 37 |
-
httpx==0.28.1 --hash=sha256:d909fcccc110f8c7faf814ca82a9a4d816bc5a6dbfea25d6591d6985b8ba59ad
|
| 38 |
-
httpx-sse==0.4.3 --hash=sha256:0ac1c9fe3c0afad2e0ebb25a934a59f4c7823b60792691f779fad2c5568830fc
|
| 39 |
-
httpx2==2.13.1 --hash=sha256:6dff50fabc270ee5fd25d845d0b078ed20564579744d6d962850975996d2f9a4
|
| 40 |
-
huggingface_hub==2.2.0 --hash=sha256:1667f145dc56dc210d60966069397df9ecfca9607a5d43db88b308c89dae56b3
|
| 41 |
-
idna==3.20 --hash=sha256:ab7ae7122974553370f0bdb919e1a960b2cd1bc1ef0276416d896db81c14582c
|
| 42 |
-
iniconfig==2.3.1 --hash=sha256:9121e2c1fdb355232495be3194c8dfe87ccc2d5dee45947b78e68f499790d7a7
|
| 43 |
-
jaraco.classes==3.4.0 --hash=sha256:f662826b6bed8cace05e7ff873ce0f9283b5c924470fe664fff1c2f00f581790
|
| 44 |
-
jaraco.context==6.1.2 --hash=sha256:bf8150b79a2d5d91ae48629d8b427a8f7ba0e1097dd6202a9059f29a36379535
|
| 45 |
-
jaraco.functools==4.6.0 --hash=sha256:99e3dc0060c5cbe8fcd1cdb36258e2a65ca40f1566b2033b12abb1bb44dd3c30
|
| 46 |
-
jeepney==0.9.0 --hash=sha256:97e5714520c16fc0a45695e5365a2e11b81ea79bba796e26f9f1d178cb182683
|
| 47 |
-
Jinja2==3.1.6 --hash=sha256:85ece4451f492d0c13c5dd7c13a64681a86afae63a5f347908daf103ce6d2f67
|
| 48 |
-
jiter==0.17.0 --hash=sha256:8c21265b251d99bbb40080d178a8953e35601d3a1564e05c4de4c0d2ca616797
|
| 49 |
-
joserfc==1.7.5 --hash=sha256:add2c2c84e8373b084d526a8b53daba5d7a513a118cd2dcd9fc9f979d0922159
|
| 50 |
-
jsonref==1.1.0 --hash=sha256:590dc7773df6c21cbf948b5dac07a72a251db28b0238ceecce0a2abfa8ec30a9
|
| 51 |
-
jsonschema==4.26.0 --hash=sha256:d489f15263b8d200f8387e64b4c3a75f06629559fb73deb8fdfb525f2dab50ce
|
| 52 |
-
jsonschema-path==0.5.0 --hash=sha256:2790a070bc7abb08ea3dbe4d340ece4efadf639223001f020c7503229ba068e2
|
| 53 |
-
jsonschema-specifications==2025.9.1 --hash=sha256:98802fee3a11ee76ecaca44429fda8a41bff98b00a0f2838151b113f210cc6fe
|
| 54 |
-
keyring==25.7.0 --hash=sha256:be4a0b195f149690c166e850609a477c532ddbfbaed96a404d4e43f8d5e2689f
|
| 55 |
-
markdown-it-py==4.2.0 --hash=sha256:9f7ebbcd14fe59494226453aed97c1070d83f8d24b6fc3a3bcf9a38092641c4a
|
| 56 |
-
MarkupSafe==3.0.4 --hash=sha256:8e124f974786f831d6043728e38296969d3579db8896fe004682f5758e613581
|
| 57 |
-
mcp==1.30.0 --hash=sha256:666edb5009503e1047c9d60346a756f94b261f05cc2625f23d41c728ffc484d0
|
| 58 |
-
mdurl==0.1.2 --hash=sha256:84008a41e51615a49fc9966191ff91509e3c40b939176e643fd50a5c2196b8f8
|
| 59 |
-
more-itertools==11.1.0 --hash=sha256:4b65538ae22f6fed0ce4874efd317463a7489796a0939fa66824dd542125a192
|
| 60 |
-
numpy==2.5.3 --hash=sha256:b7e18c623bb5c95acb3b3328861272816ba199fb531921c5d6d0b675f1fde9e3
|
| 61 |
-
openai==3.28.0 --hash=sha256:1ea40a084ffe2f9f16fd3bea6e870f757853b536b18d8e737c518ef849a2920c
|
| 62 |
-
openapi-pydantic==0.6.0 --hash=sha256:8bd6d548a250da37db96f461bcd52b3468e8834ad7d6db14b00a6b2ebbd163a3
|
| 63 |
-
openenv==0.6.1.dev0 --hash=sha256:93a5781b64e2f174f17fff40a558d43745a7f4e48a8b247363da4f27906be53a
|
| 64 |
-
opentelemetry-api==1.45.1 --hash=sha256:b31553efa588ae44bc306f863c785c5333a9ecc091248c6ee68b4b6c87fdedfb
|
| 65 |
-
orjson==3.13.0 --hash=sha256:bceadfd314bd238f584fc229a4bbaf0e573597e7a026dec5429fbf29fd66c641
|
| 66 |
-
packaging==26.3 --hash=sha256:d7193f7c8e4e93f444fde0262bf90af30e16fa0ad0ad44cb553c87339b23cd1c
|
| 67 |
-
pandas==3.0.6 --hash=sha256:0704044b676496b8350e023b09f174a26772456c974a2b11c36bebb558c9490d
|
| 68 |
-
pathable==0.6.0 --hash=sha256:82c4ca6c98c502ad12e0d4e9779b6210afee93c38990988c8c5d1b49bdcdf566
|
| 69 |
-
pillow==12.3.0 --hash=sha256:78cb2c6865a35ab8ff8b75fd122f6033b92a62c82801110e48ddd6c936a45d91
|
| 70 |
-
platformdirs==4.12.4 --hash=sha256:78bfb9db2a8471ed7eebe3c3c932da413911042994e699b384fbb4493fa872d7
|
| 71 |
-
pluggy==1.6.0 --hash=sha256:e920276dd6813095e9377c0bc5566d94c932c33b27a3e3945d8389c374dd4746
|
| 72 |
-
py-key-value-aio==0.4.6 --hash=sha256:820b30c7959fc738ea3d00160cdb10cd258f51e38737b2add530defeea1ded77
|
| 73 |
-
pycparser==3.11 --hash=sha256:51d5a8ba2be0bbe440b99d2112604c95bbbc3c2748a64260186c541e1729cd80
|
| 74 |
-
pydantic==2.14.0 --hash=sha256:15fab1bea6f1dc5003b54fc2ecab230c1fd1dbade2acd4addc52d81e32416d4b
|
| 75 |
-
pydantic-settings==2.15.0 --hash=sha256:0ba092c291c94baceb5eff768aa0d56400a457585bc0175925a5a5510303da42
|
| 76 |
-
pydantic_core==2.50.0 --hash=sha256:f187030fc3d62c668feb0f09e92852e0eb414d7fcefc4748f2e67d245aade37e
|
| 77 |
-
pydub==0.25.1 --hash=sha256:65617e33033874b59d87db603aa1ed450633288aefead953b30bded59cb599a6
|
| 78 |
-
Pygments==2.21.0 --hash=sha256:2363c69b61c4a97c838da3b130dcd6468f4848992b21a82f2a63ec34377137d9
|
| 79 |
-
PyJWT==2.15.1 --hash=sha256:42d59d631f7768a1028a64c7ff581a9bf7519804daf91fc5b6c56e30eec5e193
|
| 80 |
-
pyperclip==1.11.0 --hash=sha256:299403e9ff44581cb9ba2ffeed69c7aa96a008622ad0c46cb575ca75b5b84273
|
| 81 |
-
pytest==9.1.1 --hash=sha256:37a86b45efb9a47a61a36449063e8e18d0cab3161329fc099eb21783169c4f0c
|
| 82 |
-
python-dateutil==2.9.0.post0 --hash=sha256:a8b2bc7bffae282281c8140a97d3aa9c14da0b136dfe83f850eea9a5f7470427
|
| 83 |
-
python-dotenv==1.2.4 --hash=sha256:42269a8a5b3fd54ffa6f3d84b18abed50064717576b4ecf03dc4a55d8aa04fdc
|
| 84 |
-
python-multipart==0.0.32 --hash=sha256:ff6d3f776f16878c894e52e107296ffc890e913c611b1a4ec6c44e2821fe2e23
|
| 85 |
-
pytz==2026.5 --hash=sha256:e658af3757f9e26a9d25dd2aff38335acd92bc9104f890a894b2c1ba28311b03
|
| 86 |
-
PyYAML==6.0.3 --hash=sha256:ba1cc08a7ccde2d2ec775841541641e4548226580ab850948cbfda66a1befcdc
|
| 87 |
-
referencing==0.37.0 --hash=sha256:381329a9f99628c9069361716891d34ad94af76e461dcb0335825aecc7692231
|
| 88 |
-
requests==2.34.2 --hash=sha256:2a0d60c172f83ac6ab31e4554906c0f3b3588d37b5cb939b1c061f4907e278e0
|
| 89 |
-
rich==15.0.0 --hash=sha256:33bd4ef74232fb73fe9279a257718407f169c09b78a87ad3d296f548e27de0bb
|
| 90 |
-
rich-rst==2.2.0 --hash=sha256:1ea1c43813dc4a8d86475fce27ffb74e0ada3d4656c9f8130ba2a59868055fe9
|
| 91 |
-
rpds-py==2026.9.1 --hash=sha256:addeda51556dac7c1a2f14cda62db8b621cd12afba3091d03a96c72932387eab
|
| 92 |
-
safehttpx==0.1.7 --hash=sha256:c4f4a162db6993464d7ca3d7cc4af0ffc6515a606dfd220b9f82c6945d869cde
|
| 93 |
-
SecretStorage==3.5.0 --hash=sha256:0ce65888c0725fcb2c5bc0fdb8e5438eece02c523557ea40ce0703c266248137
|
| 94 |
-
semantic-version==2.10.0 --hash=sha256:de78a3b8e0feda74cabc54aab2da702113e33ac9d9eb9d2389bcf1f58b7d9177
|
| 95 |
-
shellingham==1.5.4 --hash=sha256:7ecfff8f2fd72616f7481040475a65b2bf8af90a56c89140852d1120324e8686
|
| 96 |
-
six==1.17.0 --hash=sha256:4721f391ed90541fddacab5acf947aa0d3dc7d27b2e1e8eda2be8970586c3274
|
| 97 |
-
sniffio==1.3.1 --hash=sha256:2f6da418d1f1e0fddd844478f41680e794e6051915791a034ff65e5f100525a2
|
| 98 |
-
sse-starlette==3.5.0 --hash=sha256:3e6e1070df3f0f5d9cea81496de92dbb72f6721871d99748ece67441dd8b7997
|
| 99 |
-
starlette==1.7.0 --hash=sha256:67f8e99895493dd2911a03f11314af6ceebeae4e704bb9f43dfc6a9db151c93e
|
| 100 |
-
tomli==2.5.0 --hash=sha256:6cf74416bdc94ae458b14e37286c1073081850ac8459a00d0c5efef5d44294c6
|
| 101 |
-
tomli_w==1.2.0 --hash=sha256:188306098d013b691fcadc011abd66727d3c414c571bb01b1a174ba8c983cf90
|
| 102 |
-
tomlkit==0.14.0 --hash=sha256:592064ed85b40fa213469f81ac584f67a4f2992509a7c3ea2d632208623a3680
|
| 103 |
-
tqdm==4.70.1 --hash=sha256:c293e525e6fef9c20e8728fd4612df02a0aa31bb5fe91ecd93e123b1b7bffa73
|
| 104 |
-
truststore==0.10.4 --hash=sha256:adaeaecf1cbb5f4de3b1959b42d41f6fab57b2b1666adb59e89cb0b53361d981
|
| 105 |
-
typer==0.27.3 --hash=sha256:e50022f28b82a86313e54501317a1db64bf8f8d036ff8cfe5ca7e47675454aff
|
| 106 |
-
typing-inspection==0.4.4 --hash=sha256:65b8397ba37ccbce054456aaccddfc91e6e3083c92824df348d96ca832f3f147
|
| 107 |
-
typing_extensions==4.16.0 --hash=sha256:481caa481374e813c1b176ada14e97f1f67a4539ce9cfeb3f350d78d6370c2e8
|
| 108 |
-
uncalled-for==0.4.1 --hash=sha256:b611b38879d9fe5088297e7bb28f2ddd12d2d73dad933d93da107fb63eb4058e
|
| 109 |
-
urllib3==2.8.0 --hash=sha256:0cf3cae568d36aa9576b28dfb35f11328f1cb974ca7647d9475ebb86c75ac6e3
|
| 110 |
-
uvicorn==0.54.0 --hash=sha256:505bdb0f318731d45f1f712071fc781a8981f6847a31c902c9f5e652d4f67faf
|
| 111 |
-
watchfiles==1.3.0 --hash=sha256:b5768b49e426fd5b550b012c866db347cdf15c398ef98dc557b6e6b72fa74cd1
|
| 112 |
-
websockets==17.2 --hash=sha256:6627b913b8586b1c06db9516b31dd0dfbc621de3bb9312616d92a7e44f268a5b
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
components/awm/runtime/awm/adapter.py
DELETED
|
@@ -1,92 +0,0 @@
|
|
| 1 |
-
|
| 2 |
-
import base64
|
| 3 |
-
from functools import wraps
|
| 4 |
-
import hashlib
|
| 5 |
-
import json
|
| 6 |
-
import math
|
| 7 |
-
import os
|
| 8 |
-
from pathlib import Path
|
| 9 |
-
import subprocess
|
| 10 |
-
import tempfile
|
| 11 |
-
from threading import RLock
|
| 12 |
-
import time
|
| 13 |
-
|
| 14 |
-
import jsonschema
|
| 15 |
-
from common.contracts import ACTION_SCHEMA, observation_payload
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
def serialized(method):
|
| 19 |
-
@wraps(method)
|
| 20 |
-
def invoke(self,*args,**kwargs):
|
| 21 |
-
with self._lock:return method(self,*args,**kwargs)
|
| 22 |
-
return invoke
|
| 23 |
-
|
| 24 |
-
|
| 25 |
-
class AWMAdapter:
|
| 26 |
-
def __init__(self, task_entries, runtime_parent):
|
| 27 |
-
self._lock=RLock();self.registry=dict(task_entries);self.runtime_parent=Path(runtime_parent)
|
| 28 |
-
self.runtime_parent.mkdir(parents=True,exist_ok=True)
|
| 29 |
-
for name,entry in self.registry.items():
|
| 30 |
-
if entry['task_id']!=name or entry['split']!='train':raise ValueError('Invalid registry')
|
| 31 |
-
for relative,digest in entry['original_sha256'].items():
|
| 32 |
-
p=Path(entry['directory'])/relative
|
| 33 |
-
if p.is_symlink() or hashlib.sha256(p.read_bytes()).hexdigest()!=digest:raise ValueError('Original source integrity mismatch')
|
| 34 |
-
self.temporary=None;self.task_id=None;self.done=False;self.reward=None;self.tool_calls=0;self.started=None
|
| 35 |
-
|
| 36 |
-
def _worker(self, operation, payload=None):
|
| 37 |
-
if self.temporary is None:raise ValueError('reset is required')
|
| 38 |
-
request=base64.b64encode(json.dumps(payload or {},allow_nan=False).encode()).decode()
|
| 39 |
-
args=['/opt/awm-venv/bin/python','-I','-B','/opt/awm/runtime/awm/worker.py',str(self.registry[self.task_id]['directory']),str(Path(self.temporary.name)/'state'),operation,request]
|
| 40 |
-
env={'PATH':'/opt/awm-venv/bin:/usr/local/bin:/usr/bin:/bin','HOME':'/nonexistent','LANG':'C.UTF-8','LC_ALL':'C.UTF-8','PYTHONDONTWRITEBYTECODE':'1'}
|
| 41 |
-
try:r=subprocess.run(args,env=env,capture_output=True,text=True,timeout=60)
|
| 42 |
-
except (OSError,subprocess.TimeoutExpired) as exc:raise RuntimeError('Original AWM worker did not complete') from exc
|
| 43 |
-
if r.returncode:
|
| 44 |
-
|
| 45 |
-
(Path(self.temporary.name)/'worker-error.log').write_text(r.stderr[-24000:])
|
| 46 |
-
raise RuntimeError('Original AWM worker failed; inspect its private log')
|
| 47 |
-
if len(r.stdout)>4*1024*1024:raise RuntimeError('Original AWM worker response is too large')
|
| 48 |
-
return json.loads(r.stdout)
|
| 49 |
-
|
| 50 |
-
@serialized
|
| 51 |
-
def reset(self, task_id=None):
|
| 52 |
-
if task_id is None and len(self.registry)==1:task_id=next(iter(self.registry))
|
| 53 |
-
if task_id not in self.registry:raise ValueError('Unknown task id')
|
| 54 |
-
self.close();self.task_id=task_id;self.temporary=tempfile.TemporaryDirectory(prefix='awm-',dir=self.runtime_parent)
|
| 55 |
-
self.done=False;self.reward=None;self.tool_calls=0
|
| 56 |
-
value=self._worker('reset');self.started=time.monotonic()
|
| 57 |
-
return observation_payload(task_id,value['instructions'],{'available_ops':['call','finish'],'tools':value['tools'],'situation':value['situation'],'original_format':value['original_format'],'delivery':'Return one JSON action per step. Use the listed business tools through op=call; finish when the requested business state is complete.'},reward=0.0,done=False)
|
| 58 |
-
|
| 59 |
-
def _terminal(self):
|
| 60 |
-
if self.reward is None:
|
| 61 |
-
value=self._worker('finish');reward=value['reward']
|
| 62 |
-
if type(reward) not in (int,float) or not math.isfinite(reward) or reward not in (0,1):raise RuntimeError('Invalid original AWM reward')
|
| 63 |
-
self.reward=float(reward)
|
| 64 |
-
self.done=True
|
| 65 |
-
return observation_payload(self.task_id,'The business workflow episode has ended.',{'tool_calls':self.tool_calls},reward=self.reward,done=True)
|
| 66 |
-
|
| 67 |
-
@serialized
|
| 68 |
-
def step(self, action):
|
| 69 |
-
if self.temporary is None:raise ValueError('reset is required')
|
| 70 |
-
if hasattr(action,'action_payload'):action=action.action_payload()
|
| 71 |
-
jsonschema.validate(action,ACTION_SCHEMA)
|
| 72 |
-
if self.done:return self._terminal()
|
| 73 |
-
if action['op']=='finish':return self._terminal()
|
| 74 |
-
if time.monotonic()-self.started>=self.registry[self.task_id]['timeout_seconds']:
|
| 75 |
-
return observation_payload(self.task_id,'Episode time limit reached. Send {"op":"finish"}.',{'finish_required':True,'tool_calls':self.tool_calls},reward=0.0,done=False)
|
| 76 |
-
if action['op']=='exec':
|
| 77 |
-
return observation_payload(self.task_id,'Shell execution is unavailable. Use a listed business tool.',{'is_error':True,'tool_calls':self.tool_calls},reward=0.0,done=False)
|
| 78 |
-
value=self._worker('call',{'name':action['tool'],'arguments':action['arguments']});self.tool_calls=value['tool_calls']
|
| 79 |
-
data={'is_error':value['is_error'],'tool_calls':self.tool_calls}
|
| 80 |
-
if time.monotonic()-self.started>=self.registry[self.task_id]['timeout_seconds']:
|
| 81 |
-
data['finish_required']=True
|
| 82 |
-
return observation_payload(self.task_id,value['content'],data,reward=0.0,done=False)
|
| 83 |
-
|
| 84 |
-
@property
|
| 85 |
-
@serialized
|
| 86 |
-
def state(self):
|
| 87 |
-
return {'task_id':self.task_id,'initialized':self.temporary is not None,'done':self.done,'tool_calls':self.tool_calls}
|
| 88 |
-
|
| 89 |
-
@serialized
|
| 90 |
-
def close(self):
|
| 91 |
-
if self.temporary is not None:self.temporary.cleanup()
|
| 92 |
-
self.temporary=None;self.task_id=None;self.done=False;self.reward=None;self.tool_calls=0;self.started=None
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
components/awm/runtime/awm/launch_service.py
DELETED
|
@@ -1,52 +0,0 @@
|
|
| 1 |
-
|
| 2 |
-
import argparse
|
| 3 |
-
import json
|
| 4 |
-
import os
|
| 5 |
-
from pathlib import Path
|
| 6 |
-
import subprocess
|
| 7 |
-
import time
|
| 8 |
-
import urllib.request
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
class RejectRedirects(urllib.request.HTTPRedirectHandler):
|
| 12 |
-
def redirect_request(self,*args,**kwargs):
|
| 13 |
-
raise RuntimeError('Redirects are forbidden for the local readiness probe')
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
def main():
|
| 17 |
-
parser=argparse.ArgumentParser()
|
| 18 |
-
parser.add_argument('--python',default='/usr/local/bin/python')
|
| 19 |
-
parser.add_argument('--config',default='/opt/awm/config.json')
|
| 20 |
-
args=parser.parse_args()
|
| 21 |
-
if os.geteuid()!=0:raise PermissionError('Only the trusted supervisor may launch this service')
|
| 22 |
-
if args.config!='/opt/awm/config.json':raise ValueError('This prototype uses its fixed image registry')
|
| 23 |
-
opener=urllib.request.build_opener(urllib.request.ProxyHandler({}),RejectRedirects())
|
| 24 |
-
url='http://127.0.0.1:8000/metadata'
|
| 25 |
-
def ready():
|
| 26 |
-
try:
|
| 27 |
-
with opener.open(url,timeout=2) as response:
|
| 28 |
-
return json.load(response).get('name')=='awm_original'
|
| 29 |
-
except Exception:return False
|
| 30 |
-
if ready():
|
| 31 |
-
print(json.dumps({'status':'already_running','base_url':'http://127.0.0.1:8000'}));return
|
| 32 |
-
private=Path('/opt/awm/private');private.mkdir(parents=True,exist_ok=True);private.chmod(0o700)
|
| 33 |
-
log=private/'service.log'
|
| 34 |
-
env={'PATH':'/usr/local/bin:/usr/bin:/bin','HOME':'/root','LANG':'C.UTF-8','LC_ALL':'C.UTF-8',
|
| 35 |
-
'PYTHONPATH':'/opt/awm/runtime','PYTHONDONTWRITEBYTECODE':'1','PYTHONUNBUFFERED':'1',
|
| 36 |
-
'ARENA_DEDICATED_CONTAINER':'1','ENABLE_WEB_INTERFACE':'false',
|
| 37 |
-
'OPENENV_MODE':'simulation','GRADIO_ANALYTICS_ENABLED':'false','HF_HUB_OFFLINE':'1'}
|
| 38 |
-
with log.open('w') as stream:
|
| 39 |
-
process=subprocess.Popen([args.python,'-m','awm.server'],env=env,stdin=subprocess.DEVNULL,
|
| 40 |
-
stdout=stream,stderr=subprocess.STDOUT,start_new_session=True)
|
| 41 |
-
(private/'service.pid').write_text(str(process.pid)+'\n')
|
| 42 |
-
deadline=time.monotonic()+90
|
| 43 |
-
while time.monotonic()<deadline:
|
| 44 |
-
if process.poll() is not None:raise RuntimeError('OpenEnv service exited; inspect its private service.log')
|
| 45 |
-
if ready():
|
| 46 |
-
print(json.dumps({'status':'ready','pid':process.pid,'base_url':'http://127.0.0.1:8000'}));return
|
| 47 |
-
time.sleep(.1)
|
| 48 |
-
process.terminate()
|
| 49 |
-
raise RuntimeError('OpenEnv service did not become ready')
|
| 50 |
-
|
| 51 |
-
|
| 52 |
-
if __name__=='__main__':main()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
components/awm/runtime/awm/openenv_app.py
DELETED
|
@@ -1,95 +0,0 @@
|
|
| 1 |
-
|
| 2 |
-
from pathlib import Path
|
| 3 |
-
from threading import RLock
|
| 4 |
-
from uuid import uuid4
|
| 5 |
-
|
| 6 |
-
from openenv.core.env_server.http_server import create_app
|
| 7 |
-
from openenv.core.env_server.interfaces import Environment
|
| 8 |
-
from openenv.core.env_server.types import EnvironmentMetadata, State
|
| 9 |
-
from common.models import ArenaAction, ArenaObservation
|
| 10 |
-
from common.http_routes import install_persistent_http_routes
|
| 11 |
-
from .adapter import AWMAdapter
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
def create_awm_app(task_entries, runtime_parent: Path, *, max_sessions=4):
|
| 15 |
-
task_entries = dict(task_entries)
|
| 16 |
-
|
| 17 |
-
class AWMEnvironment(Environment):
|
| 18 |
-
SUPPORTS_CONCURRENT_SESSIONS = True
|
| 19 |
-
|
| 20 |
-
def __init__(self):
|
| 21 |
-
super().__init__()
|
| 22 |
-
self.backend = AWMAdapter(task_entries, runtime_parent)
|
| 23 |
-
self.lock = RLock()
|
| 24 |
-
self.episode_id = None
|
| 25 |
-
self.step_count = 0
|
| 26 |
-
|
| 27 |
-
def reset(self, *, task_id=None, index=None, split='train', seed=None, episode_id=None, **kwargs):
|
| 28 |
-
with self.lock:
|
| 29 |
-
if kwargs:
|
| 30 |
-
raise ValueError('Unknown reset parameters: ' + ', '.join(sorted(kwargs)))
|
| 31 |
-
if split != 'train':
|
| 32 |
-
raise ValueError('Unknown split')
|
| 33 |
-
names = list(task_entries)
|
| 34 |
-
if index is not None:
|
| 35 |
-
if type(index) is not int or not 0 <= index < len(names):
|
| 36 |
-
raise ValueError('Invalid task index')
|
| 37 |
-
if task_id is not None and task_id != names[index]:
|
| 38 |
-
raise ValueError('task_id and index select different tasks')
|
| 39 |
-
task_id = names[index]
|
| 40 |
-
if task_id is None:
|
| 41 |
-
task_id = names[0]
|
| 42 |
-
value = self.backend.reset(task_id)
|
| 43 |
-
self.episode_id = episode_id or uuid4().hex
|
| 44 |
-
self.step_count = 0
|
| 45 |
-
return ArenaObservation.model_validate(value)
|
| 46 |
-
|
| 47 |
-
def step(self, action, timeout_s=None, **kwargs):
|
| 48 |
-
with self.lock:
|
| 49 |
-
if kwargs:
|
| 50 |
-
raise ValueError('Unknown step parameters')
|
| 51 |
-
validated = action if isinstance(action, ArenaAction) else ArenaAction.model_validate(action)
|
| 52 |
-
was_done = self.backend.state.get('done', False)
|
| 53 |
-
value = self.backend.step(validated)
|
| 54 |
-
if not was_done:
|
| 55 |
-
self.step_count += 1
|
| 56 |
-
return ArenaObservation.model_validate(value)
|
| 57 |
-
|
| 58 |
-
@property
|
| 59 |
-
def state(self):
|
| 60 |
-
with self.lock:
|
| 61 |
-
return State.model_validate({'episode_id': self.episode_id,
|
| 62 |
-
'step_count': self.step_count, **self.backend.state})
|
| 63 |
-
|
| 64 |
-
def close(self):
|
| 65 |
-
with self.lock:
|
| 66 |
-
self.backend.close()
|
| 67 |
-
self.episode_id = None
|
| 68 |
-
self.step_count = 0
|
| 69 |
-
|
| 70 |
-
def get_metadata(self):
|
| 71 |
-
return EnvironmentMetadata(name='awm_original', version='0.1.0',
|
| 72 |
-
description='Original AWM business workflows with multi-step API tools, isolated state and unchanged state verifiers.')
|
| 73 |
-
|
| 74 |
-
def list_splits(self): return ['train']
|
| 75 |
-
|
| 76 |
-
def list_tasks(self, split):
|
| 77 |
-
if split != 'train':
|
| 78 |
-
raise ValueError('Unknown split')
|
| 79 |
-
return [{'id': name, 'index': index} for index, name in enumerate(task_entries)]
|
| 80 |
-
|
| 81 |
-
def num_tasks(self, split): return len(self.list_tasks(split))
|
| 82 |
-
|
| 83 |
-
def get_task(self, split, index):
|
| 84 |
-
values = self.list_tasks(split)
|
| 85 |
-
if type(index) is not int or not 0 <= index < len(values):
|
| 86 |
-
raise ValueError('Invalid task index')
|
| 87 |
-
return values[index]
|
| 88 |
-
|
| 89 |
-
def get_task_range(self, split, start=None, stop=None):
|
| 90 |
-
return self.list_tasks(split)[start:stop]
|
| 91 |
-
|
| 92 |
-
app = create_app(AWMEnvironment, ArenaAction, ArenaObservation,
|
| 93 |
-
env_name='awm_original', max_concurrent_envs=max_sessions)
|
| 94 |
-
install_persistent_http_routes(app, AWMEnvironment())
|
| 95 |
-
return app
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
components/awm/runtime/awm/server.py
DELETED
|
@@ -1,31 +0,0 @@
|
|
| 1 |
-
|
| 2 |
-
import json
|
| 3 |
-
import os
|
| 4 |
-
from pathlib import Path
|
| 5 |
-
|
| 6 |
-
from .openenv_app import create_awm_app
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
def load_registry(root):
|
| 10 |
-
root = Path(root).resolve()
|
| 11 |
-
config = json.loads((root / 'config.json').read_text())
|
| 12 |
-
entries = {}
|
| 13 |
-
for item in config['tasks']:
|
| 14 |
-
name = item['task_id']
|
| 15 |
-
directory = (root / 'private/tasks' / name).resolve()
|
| 16 |
-
if directory.parent != root / 'private/tasks' or name in entries:
|
| 17 |
-
raise ValueError('Invalid trusted task registry')
|
| 18 |
-
entries[name] = dict(item, directory=directory)
|
| 19 |
-
return entries
|
| 20 |
-
|
| 21 |
-
|
| 22 |
-
def main():
|
| 23 |
-
import uvicorn
|
| 24 |
-
os.umask(0o077)
|
| 25 |
-
root = Path('/opt/awm')
|
| 26 |
-
app = create_awm_app(load_registry(root), Path('/var/lib/awm'))
|
| 27 |
-
uvicorn.run(app, host='0.0.0.0', port=8000, log_level='warning')
|
| 28 |
-
|
| 29 |
-
|
| 30 |
-
if __name__ == '__main__':
|
| 31 |
-
main()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
components/awm/runtime/awm/wire_client.py
DELETED
|
@@ -1,123 +0,0 @@
|
|
| 1 |
-
|
| 2 |
-
import argparse
|
| 3 |
-
import base64
|
| 4 |
-
import json
|
| 5 |
-
import math
|
| 6 |
-
import os
|
| 7 |
-
import sys
|
| 8 |
-
import urllib.error
|
| 9 |
-
import urllib.parse
|
| 10 |
-
import urllib.request
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
class WireProtocolError(RuntimeError):
|
| 14 |
-
pass
|
| 15 |
-
|
| 16 |
-
|
| 17 |
-
class RejectRedirects(urllib.request.HTTPRedirectHandler):
|
| 18 |
-
def redirect_request(self,request,fp,code,message,headers,new_url):
|
| 19 |
-
raise WireProtocolError('Redirects are forbidden for the local OpenEnv transport')
|
| 20 |
-
|
| 21 |
-
|
| 22 |
-
def _constant(value):
|
| 23 |
-
raise WireProtocolError('Non-finite JSON number: '+value)
|
| 24 |
-
|
| 25 |
-
|
| 26 |
-
def _unique(pairs):
|
| 27 |
-
result={}
|
| 28 |
-
for key,value in pairs:
|
| 29 |
-
if key in result:raise WireProtocolError('Duplicate JSON key')
|
| 30 |
-
result[key]=value
|
| 31 |
-
return result
|
| 32 |
-
|
| 33 |
-
|
| 34 |
-
def _finite(value):
|
| 35 |
-
if isinstance(value,float) and not math.isfinite(value):
|
| 36 |
-
raise WireProtocolError('Non-finite wire value')
|
| 37 |
-
if isinstance(value,dict):
|
| 38 |
-
for item in value.values():_finite(item)
|
| 39 |
-
elif isinstance(value,list):
|
| 40 |
-
for item in value:_finite(item)
|
| 41 |
-
|
| 42 |
-
|
| 43 |
-
def loads(raw):
|
| 44 |
-
value=json.loads(raw,parse_constant=_constant,object_pairs_hook=_unique)
|
| 45 |
-
_finite(value)
|
| 46 |
-
return value
|
| 47 |
-
|
| 48 |
-
|
| 49 |
-
def validate_envelope(value,*,require_done=False):
|
| 50 |
-
if not isinstance(value,dict) or not isinstance(value.get('observation'),dict):
|
| 51 |
-
raise WireProtocolError('Missing SDK observation object')
|
| 52 |
-
observation=value['observation']
|
| 53 |
-
if (set(observation)!={'task_id','message','data','metadata'} or
|
| 54 |
-
not isinstance(observation['task_id'],str) or not isinstance(observation['message'],str) or
|
| 55 |
-
not isinstance(observation['data'],dict) or not isinstance(observation['metadata'],dict)):
|
| 56 |
-
raise WireProtocolError('Observation does not match the common public contract')
|
| 57 |
-
if type(value.get('done')) is not bool:
|
| 58 |
-
raise WireProtocolError('SDK done must be a JSON boolean')
|
| 59 |
-
reward=value.get('reward')
|
| 60 |
-
if reward is not None and (type(reward) not in (int,float) or not math.isfinite(reward) or not 0<=reward<=1):
|
| 61 |
-
raise WireProtocolError('SDK reward is not a finite number in [0,1]')
|
| 62 |
-
if require_done and (not value['done'] or reward is None):
|
| 63 |
-
raise WireProtocolError('Finish did not return a terminal numeric score')
|
| 64 |
-
_finite(value)
|
| 65 |
-
return value
|
| 66 |
-
|
| 67 |
-
|
| 68 |
-
class WireClient:
|
| 69 |
-
def __init__(self,base_url='http://127.0.0.1:8000',timeout=330):
|
| 70 |
-
if os.geteuid()!=0:
|
| 71 |
-
raise PermissionError('Wire client is reserved for the trusted supervisor')
|
| 72 |
-
url=urllib.parse.urlsplit(base_url)
|
| 73 |
-
if url.scheme!='http' or url.hostname not in ('127.0.0.1','localhost','::1') or url.username or url.password or url.query or url.fragment or url.path not in ('','/'):
|
| 74 |
-
raise ValueError('Only an unauthenticated local HTTP server is allowed')
|
| 75 |
-
self.base_url=base_url.rstrip('/')
|
| 76 |
-
self.timeout=timeout
|
| 77 |
-
self.opener=urllib.request.build_opener(urllib.request.ProxyHandler({}),RejectRedirects())
|
| 78 |
-
|
| 79 |
-
def _post(self,path,payload):
|
| 80 |
-
body=json.dumps(payload,ensure_ascii=False,allow_nan=False,separators=(',',':')).encode()
|
| 81 |
-
request=urllib.request.Request(self.base_url+path,data=body,headers={'Content-Type':'application/json'})
|
| 82 |
-
try:
|
| 83 |
-
with self.opener.open(request,timeout=self.timeout) as response:
|
| 84 |
-
if response.status!=200:raise WireProtocolError('Unexpected HTTP status')
|
| 85 |
-
raw=response.read(2*1024*1024+1)
|
| 86 |
-
except urllib.error.HTTPError as exc:
|
| 87 |
-
raise WireProtocolError(f'OpenEnv HTTP {exc.code}: '+exc.read(2048).decode(errors='replace')) from exc
|
| 88 |
-
if len(raw)>2*1024*1024:raise WireProtocolError('SDK response exceeds the transport limit')
|
| 89 |
-
return validate_envelope(loads(raw))
|
| 90 |
-
|
| 91 |
-
def reset(self,**kwargs):
|
| 92 |
-
return self._post('/reset',kwargs)
|
| 93 |
-
|
| 94 |
-
def step(self,action):
|
| 95 |
-
return self._post('/step',{'action':action})
|
| 96 |
-
|
| 97 |
-
def finish(self):
|
| 98 |
-
return validate_envelope(self.step({'op':'finish'}),require_done=True)
|
| 99 |
-
|
| 100 |
-
|
| 101 |
-
def main():
|
| 102 |
-
parser=argparse.ArgumentParser()
|
| 103 |
-
parser.add_argument('operation',choices=['reset','step','finish'])
|
| 104 |
-
parser.add_argument('--payload-base64')
|
| 105 |
-
parser.add_argument('--url',default='http://127.0.0.1:8000')
|
| 106 |
-
parser.add_argument('--timeout',type=float,default=330)
|
| 107 |
-
args=parser.parse_args()
|
| 108 |
-
payload={} if args.payload_base64 is None else loads(base64.b64decode(args.payload_base64,validate=True))
|
| 109 |
-
if not isinstance(payload,dict):raise WireProtocolError('Payload must be a JSON object')
|
| 110 |
-
client=WireClient(args.url,args.timeout)
|
| 111 |
-
if args.operation=='reset':result=client.reset(**payload)
|
| 112 |
-
elif args.operation=='step':result=client.step(payload)
|
| 113 |
-
else:
|
| 114 |
-
if payload:raise WireProtocolError('Finish has no payload')
|
| 115 |
-
result=client.finish()
|
| 116 |
-
print(json.dumps(result,ensure_ascii=False,allow_nan=False,separators=(',',':')))
|
| 117 |
-
|
| 118 |
-
|
| 119 |
-
if __name__=='__main__':
|
| 120 |
-
try:main()
|
| 121 |
-
except Exception as exc:
|
| 122 |
-
print(type(exc).__name__+': '+str(exc),file=sys.stderr)
|
| 123 |
-
raise SystemExit(1)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|