From 3d34c445c3a34c7889b4b8dbd0fc993582dd0674 Mon Sep 17 00:00:00 2001 From: sudoskys Date: Sat, 21 Dec 2024 23:16:36 +0800 Subject: [PATCH 1/8] feat: nai4 --- pdm.lock | 181 +-- playground/generate_image.py | 42 +- playground/generate_image_img2img.py | 9 +- playground/simple.py | 10 +- playground/vibe.py | 16 +- playground/vibe_img2img.py | 12 +- playground/vibe_inpaint.py | 14 +- pyproject.toml | 4 +- src/novelai_python/sdk/ai/_cost.py | 14 +- src/novelai_python/sdk/ai/_enum.py | 159 ++- .../sdk/ai/augment_image/__init__.py | 4 +- .../sdk/ai/generate_image/__init__.py | 1023 ++++++++++------- .../sdk/ai/generate_image/schema.py | 129 +++ 13 files changed, 1090 insertions(+), 527 deletions(-) create mode 100644 src/novelai_python/sdk/ai/generate_image/schema.py diff --git a/pdm.lock b/pdm.lock index 839d57a..2ff78ba 100755 --- a/pdm.lock +++ b/pdm.lock @@ -5,7 +5,7 @@ groups = ["default", "dev", "testing"] strategy = ["cross_platform", "inherit_metadata"] lock_version = "4.5.0" -content_hash = "sha256:4cb43b4c0c3afd86ddade7ea104a158a15196b2663f7c2c079e7121414c4c111" +content_hash = "sha256:ebe3086cd1e551d730d245a3b012fafcac9ebf7898424df23e32dc52805ec1df" [[metadata.targets]] requires_python = ">=3.9" @@ -1031,24 +1031,25 @@ files = [ [[package]] name = "pydantic" -version = "2.9.2" +version = "2.9.0" requires_python = ">=3.8" summary = "Data validation using Python type hints" groups = ["default"] dependencies = [ - "annotated-types>=0.6.0", - "pydantic-core==2.23.4", + "annotated-types>=0.4.0", + "pydantic-core==2.23.2", "typing-extensions>=4.12.2; python_version >= \"3.13\"", "typing-extensions>=4.6.1; python_version < \"3.13\"", + "tzdata; python_version >= \"3.9\"", ] files = [ - {file = "pydantic-2.9.2-py3-none-any.whl", hash = "sha256:f048cec7b26778210e28a0459867920654d48e5e62db0958433636cde4254f12"}, - {file = "pydantic-2.9.2.tar.gz", hash = "sha256:d155cef71265d1e9807ed1c32b4c8deec042a44a50a4188b25ac67ecd81a9c0f"}, + {file = "pydantic-2.9.0-py3-none-any.whl", hash = "sha256:f66a7073abd93214a20c5f7b32d56843137a7a2e70d02111f3be287035c45370"}, + {file = "pydantic-2.9.0.tar.gz", hash = "sha256:c7a8a9fdf7d100afa49647eae340e2d23efa382466a8d177efcd1381e9be5598"}, ] [[package]] name = "pydantic-core" -version = "2.23.4" +version = "2.23.2" requires_python = ">=3.8" summary = "Core functionality for Pydantic validation and serialization" groups = ["default"] @@ -1056,83 +1057,83 @@ dependencies = [ "typing-extensions!=4.7.0,>=4.6.0", ] files = [ - {file = "pydantic_core-2.23.4-cp310-cp310-macosx_10_12_x86_64.whl", hash = "sha256:b10bd51f823d891193d4717448fab065733958bdb6a6b351967bd349d48d5c9b"}, - {file = "pydantic_core-2.23.4-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:4fc714bdbfb534f94034efaa6eadd74e5b93c8fa6315565a222f7b6f42ca1166"}, - {file = "pydantic_core-2.23.4-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:63e46b3169866bd62849936de036f901a9356e36376079b05efa83caeaa02ceb"}, - {file = "pydantic_core-2.23.4-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ed1a53de42fbe34853ba90513cea21673481cd81ed1be739f7f2efb931b24916"}, - {file = "pydantic_core-2.23.4-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:cfdd16ab5e59fc31b5e906d1a3f666571abc367598e3e02c83403acabc092e07"}, - {file = "pydantic_core-2.23.4-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:255a8ef062cbf6674450e668482456abac99a5583bbafb73f9ad469540a3a232"}, - {file = "pydantic_core-2.23.4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4a7cd62e831afe623fbb7aabbb4fe583212115b3ef38a9f6b71869ba644624a2"}, - {file = "pydantic_core-2.23.4-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:f09e2ff1f17c2b51f2bc76d1cc33da96298f0a036a137f5440ab3ec5360b624f"}, - {file = "pydantic_core-2.23.4-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:e38e63e6f3d1cec5a27e0afe90a085af8b6806ee208b33030e65b6516353f1a3"}, - {file = "pydantic_core-2.23.4-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0dbd8dbed2085ed23b5c04afa29d8fd2771674223135dc9bc937f3c09284d071"}, - {file = "pydantic_core-2.23.4-cp310-none-win32.whl", hash = "sha256:6531b7ca5f951d663c339002e91aaebda765ec7d61b7d1e3991051906ddde119"}, - {file = "pydantic_core-2.23.4-cp310-none-win_amd64.whl", hash = "sha256:7c9129eb40958b3d4500fa2467e6a83356b3b61bfff1b414c7361d9220f9ae8f"}, - {file = "pydantic_core-2.23.4-cp311-cp311-macosx_10_12_x86_64.whl", hash = "sha256:77733e3892bb0a7fa797826361ce8a9184d25c8dffaec60b7ffe928153680ba8"}, - {file = "pydantic_core-2.23.4-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:1b84d168f6c48fabd1f2027a3d1bdfe62f92cade1fb273a5d68e621da0e44e6d"}, - {file = "pydantic_core-2.23.4-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:df49e7a0861a8c36d089c1ed57d308623d60416dab2647a4a17fe050ba85de0e"}, - {file = "pydantic_core-2.23.4-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ff02b6d461a6de369f07ec15e465a88895f3223eb75073ffea56b84d9331f607"}, - {file = "pydantic_core-2.23.4-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:996a38a83508c54c78a5f41456b0103c30508fed9abcad0a59b876d7398f25fd"}, - {file = "pydantic_core-2.23.4-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:d97683ddee4723ae8c95d1eddac7c192e8c552da0c73a925a89fa8649bf13eea"}, - {file = "pydantic_core-2.23.4-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:216f9b2d7713eb98cb83c80b9c794de1f6b7e3145eef40400c62e86cee5f4e1e"}, - {file = "pydantic_core-2.23.4-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:6f783e0ec4803c787bcea93e13e9932edab72068f68ecffdf86a99fd5918878b"}, - {file = "pydantic_core-2.23.4-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:d0776dea117cf5272382634bd2a5c1b6eb16767c223c6a5317cd3e2a757c61a0"}, - {file = "pydantic_core-2.23.4-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:d5f7a395a8cf1621939692dba2a6b6a830efa6b3cee787d82c7de1ad2930de64"}, - {file = "pydantic_core-2.23.4-cp311-none-win32.whl", hash = "sha256:74b9127ffea03643e998e0c5ad9bd3811d3dac8c676e47db17b0ee7c3c3bf35f"}, - {file = "pydantic_core-2.23.4-cp311-none-win_amd64.whl", hash = "sha256:98d134c954828488b153d88ba1f34e14259284f256180ce659e8d83e9c05eaa3"}, - {file = "pydantic_core-2.23.4-cp312-cp312-macosx_10_12_x86_64.whl", hash = "sha256:f3e0da4ebaef65158d4dfd7d3678aad692f7666877df0002b8a522cdf088f231"}, - {file = "pydantic_core-2.23.4-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:f69a8e0b033b747bb3e36a44e7732f0c99f7edd5cea723d45bc0d6e95377ffee"}, - {file = "pydantic_core-2.23.4-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:723314c1d51722ab28bfcd5240d858512ffd3116449c557a1336cbe3919beb87"}, - {file = "pydantic_core-2.23.4-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:bb2802e667b7051a1bebbfe93684841cc9351004e2badbd6411bf357ab8d5ac8"}, - {file = "pydantic_core-2.23.4-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:d18ca8148bebe1b0a382a27a8ee60350091a6ddaf475fa05ef50dc35b5df6327"}, - {file = "pydantic_core-2.23.4-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:33e3d65a85a2a4a0dc3b092b938a4062b1a05f3a9abde65ea93b233bca0e03f2"}, - {file = "pydantic_core-2.23.4-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:128585782e5bfa515c590ccee4b727fb76925dd04a98864182b22e89a4e6ed36"}, - {file = "pydantic_core-2.23.4-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:68665f4c17edcceecc112dfed5dbe6f92261fb9d6054b47d01bf6371a6196126"}, - {file = "pydantic_core-2.23.4-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:20152074317d9bed6b7a95ade3b7d6054845d70584216160860425f4fbd5ee9e"}, - {file = "pydantic_core-2.23.4-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:9261d3ce84fa1d38ed649c3638feefeae23d32ba9182963e465d58d62203bd24"}, - {file = "pydantic_core-2.23.4-cp312-none-win32.whl", hash = "sha256:4ba762ed58e8d68657fc1281e9bb72e1c3e79cc5d464be146e260c541ec12d84"}, - {file = "pydantic_core-2.23.4-cp312-none-win_amd64.whl", hash = "sha256:97df63000f4fea395b2824da80e169731088656d1818a11b95f3b173747b6cd9"}, - {file = "pydantic_core-2.23.4-cp313-cp313-macosx_10_12_x86_64.whl", hash = "sha256:7530e201d10d7d14abce4fb54cfe5b94a0aefc87da539d0346a484ead376c3cc"}, - {file = "pydantic_core-2.23.4-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:df933278128ea1cd77772673c73954e53a1c95a4fdf41eef97c2b779271bd0bd"}, - {file = "pydantic_core-2.23.4-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0cb3da3fd1b6a5d0279a01877713dbda118a2a4fc6f0d821a57da2e464793f05"}, - {file = "pydantic_core-2.23.4-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:42c6dcb030aefb668a2b7009c85b27f90e51e6a3b4d5c9bc4c57631292015b0d"}, - {file = "pydantic_core-2.23.4-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:696dd8d674d6ce621ab9d45b205df149399e4bb9aa34102c970b721554828510"}, - {file = "pydantic_core-2.23.4-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:2971bb5ffe72cc0f555c13e19b23c85b654dd2a8f7ab493c262071377bfce9f6"}, - {file = "pydantic_core-2.23.4-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8394d940e5d400d04cad4f75c0598665cbb81aecefaca82ca85bd28264af7f9b"}, - {file = "pydantic_core-2.23.4-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:0dff76e0602ca7d4cdaacc1ac4c005e0ce0dcfe095d5b5259163a80d3a10d327"}, - {file = "pydantic_core-2.23.4-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:7d32706badfe136888bdea71c0def994644e09fff0bfe47441deaed8e96fdbc6"}, - {file = "pydantic_core-2.23.4-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:ed541d70698978a20eb63d8c5d72f2cc6d7079d9d90f6b50bad07826f1320f5f"}, - {file = "pydantic_core-2.23.4-cp313-none-win32.whl", hash = "sha256:3d5639516376dce1940ea36edf408c554475369f5da2abd45d44621cb616f769"}, - {file = "pydantic_core-2.23.4-cp313-none-win_amd64.whl", hash = "sha256:5a1504ad17ba4210df3a045132a7baeeba5a200e930f57512ee02909fc5c4cb5"}, - {file = "pydantic_core-2.23.4-cp39-cp39-macosx_10_12_x86_64.whl", hash = "sha256:a4fa4fc04dff799089689f4fd502ce7d59de529fc2f40a2c8836886c03e0175a"}, - {file = "pydantic_core-2.23.4-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:0a7df63886be5e270da67e0966cf4afbae86069501d35c8c1b3b6c168f42cb36"}, - {file = "pydantic_core-2.23.4-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dcedcd19a557e182628afa1d553c3895a9f825b936415d0dbd3cd0bbcfd29b4b"}, - {file = "pydantic_core-2.23.4-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:5f54b118ce5de9ac21c363d9b3caa6c800341e8c47a508787e5868c6b79c9323"}, - {file = "pydantic_core-2.23.4-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:86d2f57d3e1379a9525c5ab067b27dbb8a0642fb5d454e17a9ac434f9ce523e3"}, - {file = "pydantic_core-2.23.4-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:de6d1d1b9e5101508cb37ab0d972357cac5235f5c6533d1071964c47139257df"}, - {file = "pydantic_core-2.23.4-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1278e0d324f6908e872730c9102b0112477a7f7cf88b308e4fc36ce1bdb6d58c"}, - {file = "pydantic_core-2.23.4-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:9a6b5099eeec78827553827f4c6b8615978bb4b6a88e5d9b93eddf8bb6790f55"}, - {file = "pydantic_core-2.23.4-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:e55541f756f9b3ee346b840103f32779c695a19826a4c442b7954550a0972040"}, - {file = "pydantic_core-2.23.4-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:a5c7ba8ffb6d6f8f2ab08743be203654bb1aaa8c9dcb09f82ddd34eadb695605"}, - {file = "pydantic_core-2.23.4-cp39-none-win32.whl", hash = "sha256:37b0fe330e4a58d3c58b24d91d1eb102aeec675a3db4c292ec3928ecd892a9a6"}, - {file = "pydantic_core-2.23.4-cp39-none-win_amd64.whl", hash = "sha256:1498bec4c05c9c787bde9125cfdcc63a41004ff167f495063191b863399b1a29"}, - {file = "pydantic_core-2.23.4-pp310-pypy310_pp73-macosx_10_12_x86_64.whl", hash = "sha256:f455ee30a9d61d3e1a15abd5068827773d6e4dc513e795f380cdd59932c782d5"}, - {file = "pydantic_core-2.23.4-pp310-pypy310_pp73-macosx_11_0_arm64.whl", hash = "sha256:1e90d2e3bd2c3863d48525d297cd143fe541be8bbf6f579504b9712cb6b643ec"}, - {file = "pydantic_core-2.23.4-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2e203fdf807ac7e12ab59ca2bfcabb38c7cf0b33c41efeb00f8e5da1d86af480"}, - {file = "pydantic_core-2.23.4-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e08277a400de01bc72436a0ccd02bdf596631411f592ad985dcee21445bd0068"}, - {file = "pydantic_core-2.23.4-pp310-pypy310_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:f220b0eea5965dec25480b6333c788fb72ce5f9129e8759ef876a1d805d00801"}, - {file = "pydantic_core-2.23.4-pp310-pypy310_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:d06b0c8da4f16d1d1e352134427cb194a0a6e19ad5db9161bf32b2113409e728"}, - {file = "pydantic_core-2.23.4-pp310-pypy310_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:ba1a0996f6c2773bd83e63f18914c1de3c9dd26d55f4ac302a7efe93fb8e7433"}, - {file = "pydantic_core-2.23.4-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:9a5bce9d23aac8f0cf0836ecfc033896aa8443b501c58d0602dbfd5bd5b37753"}, - {file = "pydantic_core-2.23.4-pp39-pypy39_pp73-macosx_10_12_x86_64.whl", hash = "sha256:78ddaaa81421a29574a682b3179d4cf9e6d405a09b99d93ddcf7e5239c742e21"}, - {file = "pydantic_core-2.23.4-pp39-pypy39_pp73-macosx_11_0_arm64.whl", hash = "sha256:883a91b5dd7d26492ff2f04f40fbb652de40fcc0afe07e8129e8ae779c2110eb"}, - {file = "pydantic_core-2.23.4-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:88ad334a15b32a791ea935af224b9de1bf99bcd62fabf745d5f3442199d86d59"}, - {file = "pydantic_core-2.23.4-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:233710f069d251feb12a56da21e14cca67994eab08362207785cf8c598e74577"}, - {file = "pydantic_core-2.23.4-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:19442362866a753485ba5e4be408964644dd6a09123d9416c54cd49171f50744"}, - {file = "pydantic_core-2.23.4-pp39-pypy39_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:624e278a7d29b6445e4e813af92af37820fafb6dcc55c012c834f9e26f9aaaef"}, - {file = "pydantic_core-2.23.4-pp39-pypy39_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:f5ef8f42bec47f21d07668a043f077d507e5bf4e668d5c6dfe6aaba89de1a5b8"}, - {file = "pydantic_core-2.23.4-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:aea443fffa9fbe3af1a9ba721a87f926fe548d32cab71d188a6ede77d0ff244e"}, - {file = "pydantic_core-2.23.4.tar.gz", hash = "sha256:2584f7cf844ac4d970fba483a717dbe10c1c1c96a969bf65d61ffe94df1b2863"}, + {file = "pydantic_core-2.23.2-cp310-cp310-macosx_10_12_x86_64.whl", hash = "sha256:7d0324a35ab436c9d768753cbc3c47a865a2cbc0757066cb864747baa61f6ece"}, + {file = "pydantic_core-2.23.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:276ae78153a94b664e700ac362587c73b84399bd1145e135287513442e7dfbc7"}, + {file = "pydantic_core-2.23.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:964c7aa318da542cdcc60d4a648377ffe1a2ef0eb1e996026c7f74507b720a78"}, + {file = "pydantic_core-2.23.2-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:1cf842265a3a820ebc6388b963ead065f5ce8f2068ac4e1c713ef77a67b71f7c"}, + {file = "pydantic_core-2.23.2-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:ae90b9e50fe1bd115b24785e962b51130340408156d34d67b5f8f3fa6540938e"}, + {file = "pydantic_core-2.23.2-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:8ae65fdfb8a841556b52935dfd4c3f79132dc5253b12c0061b96415208f4d622"}, + {file = "pydantic_core-2.23.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5c8aa40f6ca803f95b1c1c5aeaee6237b9e879e4dfb46ad713229a63651a95fb"}, + {file = "pydantic_core-2.23.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:c53100c8ee5a1e102766abde2158077d8c374bee0639201f11d3032e3555dfbc"}, + {file = "pydantic_core-2.23.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:d6b9dd6aa03c812017411734e496c44fef29b43dba1e3dd1fa7361bbacfc1354"}, + {file = "pydantic_core-2.23.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:b18cf68255a476b927910c6873d9ed00da692bb293c5b10b282bd48a0afe3ae2"}, + {file = "pydantic_core-2.23.2-cp310-none-win32.whl", hash = "sha256:e460475719721d59cd54a350c1f71c797c763212c836bf48585478c5514d2854"}, + {file = "pydantic_core-2.23.2-cp310-none-win_amd64.whl", hash = "sha256:5f3cf3721eaf8741cffaf092487f1ca80831202ce91672776b02b875580e174a"}, + {file = "pydantic_core-2.23.2-cp311-cp311-macosx_10_12_x86_64.whl", hash = "sha256:7ce8e26b86a91e305858e018afc7a6e932f17428b1eaa60154bd1f7ee888b5f8"}, + {file = "pydantic_core-2.23.2-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:7e9b24cca4037a561422bf5dc52b38d390fb61f7bfff64053ce1b72f6938e6b2"}, + {file = "pydantic_core-2.23.2-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:753294d42fb072aa1775bfe1a2ba1012427376718fa4c72de52005a3d2a22178"}, + {file = "pydantic_core-2.23.2-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:257d6a410a0d8aeb50b4283dea39bb79b14303e0fab0f2b9d617701331ed1515"}, + {file = "pydantic_core-2.23.2-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c8319e0bd6a7b45ad76166cc3d5d6a36c97d0c82a196f478c3ee5346566eebfd"}, + {file = "pydantic_core-2.23.2-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:7a05c0240f6c711eb381ac392de987ee974fa9336071fb697768dfdb151345ce"}, + {file = "pydantic_core-2.23.2-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8d5b0ff3218858859910295df6953d7bafac3a48d5cd18f4e3ed9999efd2245f"}, + {file = "pydantic_core-2.23.2-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:96ef39add33ff58cd4c112cbac076726b96b98bb8f1e7f7595288dcfb2f10b57"}, + {file = "pydantic_core-2.23.2-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:0102e49ac7d2df3379ef8d658d3bc59d3d769b0bdb17da189b75efa861fc07b4"}, + {file = "pydantic_core-2.23.2-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:a6612c2a844043e4d10a8324c54cdff0042c558eef30bd705770793d70b224aa"}, + {file = "pydantic_core-2.23.2-cp311-none-win32.whl", hash = "sha256:caffda619099cfd4f63d48462f6aadbecee3ad9603b4b88b60cb821c1b258576"}, + {file = "pydantic_core-2.23.2-cp311-none-win_amd64.whl", hash = "sha256:6f80fba4af0cb1d2344869d56430e304a51396b70d46b91a55ed4959993c0589"}, + {file = "pydantic_core-2.23.2-cp312-cp312-macosx_10_12_x86_64.whl", hash = "sha256:4c83c64d05ffbbe12d4e8498ab72bdb05bcc1026340a4a597dc647a13c1605ec"}, + {file = "pydantic_core-2.23.2-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:6294907eaaccf71c076abdd1c7954e272efa39bb043161b4b8aa1cd76a16ce43"}, + {file = "pydantic_core-2.23.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4a801c5e1e13272e0909c520708122496647d1279d252c9e6e07dac216accc41"}, + {file = "pydantic_core-2.23.2-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:cc0c316fba3ce72ac3ab7902a888b9dc4979162d320823679da270c2d9ad0cad"}, + {file = "pydantic_core-2.23.2-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:6b06c5d4e8701ac2ba99a2ef835e4e1b187d41095a9c619c5b185c9068ed2a49"}, + {file = "pydantic_core-2.23.2-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:82764c0bd697159fe9947ad59b6db6d7329e88505c8f98990eb07e84cc0a5d81"}, + {file = "pydantic_core-2.23.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2b1a195efd347ede8bcf723e932300292eb13a9d2a3c1f84eb8f37cbbc905b7f"}, + {file = "pydantic_core-2.23.2-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:b7efb12e5071ad8d5b547487bdad489fbd4a5a35a0fc36a1941517a6ad7f23e0"}, + {file = "pydantic_core-2.23.2-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:5dd0ec5f514ed40e49bf961d49cf1bc2c72e9b50f29a163b2cc9030c6742aa73"}, + {file = "pydantic_core-2.23.2-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:820f6ee5c06bc868335e3b6e42d7ef41f50dfb3ea32fbd523ab679d10d8741c0"}, + {file = "pydantic_core-2.23.2-cp312-none-win32.whl", hash = "sha256:3713dc093d5048bfaedbba7a8dbc53e74c44a140d45ede020dc347dda18daf3f"}, + {file = "pydantic_core-2.23.2-cp312-none-win_amd64.whl", hash = "sha256:e1895e949f8849bc2757c0dbac28422a04be031204df46a56ab34bcf98507342"}, + {file = "pydantic_core-2.23.2-cp313-cp313-macosx_10_12_x86_64.whl", hash = "sha256:da43cbe593e3c87d07108d0ebd73771dc414488f1f91ed2e204b0370b94b37ac"}, + {file = "pydantic_core-2.23.2-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:64d094ea1aa97c6ded4748d40886076a931a8bf6f61b6e43e4a1041769c39dd2"}, + {file = "pydantic_core-2.23.2-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:084414ffe9a85a52940b49631321d636dadf3576c30259607b75516d131fecd0"}, + {file = "pydantic_core-2.23.2-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:043ef8469f72609c4c3a5e06a07a1f713d53df4d53112c6d49207c0bd3c3bd9b"}, + {file = "pydantic_core-2.23.2-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:3649bd3ae6a8ebea7dc381afb7f3c6db237fc7cebd05c8ac36ca8a4187b03b30"}, + {file = "pydantic_core-2.23.2-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:6db09153d8438425e98cdc9a289c5fade04a5d2128faff8f227c459da21b9703"}, + {file = "pydantic_core-2.23.2-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5668b3173bb0b2e65020b60d83f5910a7224027232c9f5dc05a71a1deac9f960"}, + {file = "pydantic_core-2.23.2-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:1c7b81beaf7c7ebde978377dc53679c6cba0e946426fc7ade54251dfe24a7604"}, + {file = "pydantic_core-2.23.2-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:ae579143826c6f05a361d9546446c432a165ecf1c0b720bbfd81152645cb897d"}, + {file = "pydantic_core-2.23.2-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:19f1352fe4b248cae22a89268720fc74e83f008057a652894f08fa931e77dced"}, + {file = "pydantic_core-2.23.2-cp313-none-win32.whl", hash = "sha256:e1a79ad49f346aa1a2921f31e8dbbab4d64484823e813a002679eaa46cba39e1"}, + {file = "pydantic_core-2.23.2-cp313-none-win_amd64.whl", hash = "sha256:582871902e1902b3c8e9b2c347f32a792a07094110c1bca6c2ea89b90150caac"}, + {file = "pydantic_core-2.23.2-cp39-cp39-macosx_10_12_x86_64.whl", hash = "sha256:358331e21a897151e54d58e08d0219acf98ebb14c567267a87e971f3d2a3be59"}, + {file = "pydantic_core-2.23.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:c4d9f15ffe68bcd3898b0ad7233af01b15c57d91cd1667f8d868e0eacbfe3f87"}, + {file = "pydantic_core-2.23.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0123655fedacf035ab10c23450163c2f65a4174f2bb034b188240a6cf06bb123"}, + {file = "pydantic_core-2.23.2-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:e6e3ccebdbd6e53474b0bb7ab8b88e83c0cfe91484b25e058e581348ee5a01a5"}, + {file = "pydantic_core-2.23.2-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:fc535cb898ef88333cf317777ecdfe0faac1c2a3187ef7eb061b6f7ecf7e6bae"}, + {file = "pydantic_core-2.23.2-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:aab9e522efff3993a9e98ab14263d4e20211e62da088298089a03056980a3e69"}, + {file = "pydantic_core-2.23.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:05b366fb8fe3d8683b11ac35fa08947d7b92be78ec64e3277d03bd7f9b7cda79"}, + {file = "pydantic_core-2.23.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:7568f682c06f10f30ef643a1e8eec4afeecdafde5c4af1b574c6df079e96f96c"}, + {file = "pydantic_core-2.23.2-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:cdd02a08205dc90238669f082747612cb3c82bd2c717adc60f9b9ecadb540f80"}, + {file = "pydantic_core-2.23.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:1a2ab4f410f4b886de53b6bddf5dd6f337915a29dd9f22f20f3099659536b2f6"}, + {file = "pydantic_core-2.23.2-cp39-none-win32.whl", hash = "sha256:0448b81c3dfcde439551bb04a9f41d7627f676b12701865c8a2574bcea034437"}, + {file = "pydantic_core-2.23.2-cp39-none-win_amd64.whl", hash = "sha256:4cebb9794f67266d65e7e4cbe5dcf063e29fc7b81c79dc9475bd476d9534150e"}, + {file = "pydantic_core-2.23.2-pp310-pypy310_pp73-macosx_10_12_x86_64.whl", hash = "sha256:e758d271ed0286d146cf7c04c539a5169a888dd0b57026be621547e756af55bc"}, + {file = "pydantic_core-2.23.2-pp310-pypy310_pp73-macosx_11_0_arm64.whl", hash = "sha256:f477d26183e94eaafc60b983ab25af2a809a1b48ce4debb57b343f671b7a90b6"}, + {file = "pydantic_core-2.23.2-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:da3131ef2b940b99106f29dfbc30d9505643f766704e14c5d5e504e6a480c35e"}, + {file = "pydantic_core-2.23.2-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:329a721253c7e4cbd7aad4a377745fbcc0607f9d72a3cc2102dd40519be75ed2"}, + {file = "pydantic_core-2.23.2-pp310-pypy310_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:7706e15cdbf42f8fab1e6425247dfa98f4a6f8c63746c995d6a2017f78e619ae"}, + {file = "pydantic_core-2.23.2-pp310-pypy310_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:e64ffaf8f6e17ca15eb48344d86a7a741454526f3a3fa56bc493ad9d7ec63936"}, + {file = "pydantic_core-2.23.2-pp310-pypy310_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:dd59638025160056687d598b054b64a79183f8065eae0d3f5ca523cde9943940"}, + {file = "pydantic_core-2.23.2-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:12625e69b1199e94b0ae1c9a95d000484ce9f0182f9965a26572f054b1537e44"}, + {file = "pydantic_core-2.23.2-pp39-pypy39_pp73-macosx_10_12_x86_64.whl", hash = "sha256:5d813fd871b3d5c3005157622ee102e8908ad6011ec915a18bd8fde673c4360e"}, + {file = "pydantic_core-2.23.2-pp39-pypy39_pp73-macosx_11_0_arm64.whl", hash = "sha256:1eb37f7d6a8001c0f86dc8ff2ee8d08291a536d76e49e78cda8587bb54d8b329"}, + {file = "pydantic_core-2.23.2-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7ce7eaf9a98680b4312b7cebcdd9352531c43db00fca586115845df388f3c465"}, + {file = "pydantic_core-2.23.2-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f087879f1ffde024dd2788a30d55acd67959dcf6c431e9d3682d1c491a0eb474"}, + {file = "pydantic_core-2.23.2-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:6ce883906810b4c3bd90e0ada1f9e808d9ecf1c5f0b60c6b8831d6100bcc7dd6"}, + {file = "pydantic_core-2.23.2-pp39-pypy39_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:a8031074a397a5925d06b590121f8339d34a5a74cfe6970f8a1124eb8b83f4ac"}, + {file = "pydantic_core-2.23.2-pp39-pypy39_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:23af245b8f2f4ee9e2c99cb3f93d0e22fb5c16df3f2f643f5a8da5caff12a653"}, + {file = "pydantic_core-2.23.2-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:c57e493a0faea1e4c38f860d6862ba6832723396c884fbf938ff5e9b224200e2"}, + {file = "pydantic_core-2.23.2.tar.gz", hash = "sha256:95d6bf449a1ac81de562d65d180af5d8c19672793c81877a2eda8fde5d08f2fd"}, ] [[package]] @@ -1642,6 +1643,18 @@ files = [ {file = "typing_extensions-4.12.2.tar.gz", hash = "sha256:1a7ead55c7e559dd4dee8856e3a88b41225abfe1ce8df57b7c13915fe121ffb8"}, ] +[[package]] +name = "tzdata" +version = "2024.2" +requires_python = ">=2" +summary = "Provider of IANA time zone data" +groups = ["default"] +marker = "python_version >= \"3.9\"" +files = [ + {file = "tzdata-2024.2-py2.py3-none-any.whl", hash = "sha256:a48093786cdcde33cad18c2555e8532f34422074448fbc874186f0abd79565cd"}, + {file = "tzdata-2024.2.tar.gz", hash = "sha256:7d85cc416e9382e69095b7bdf4afd9e3880418a2413feec7069d533d6b4e31cc"}, +] + [[package]] name = "urllib3" version = "2.2.1" diff --git a/playground/generate_image.py b/playground/generate_image.py index d3a32b4..9fdbb4b 100755 --- a/playground/generate_image.py +++ b/playground/generate_image.py @@ -13,11 +13,14 @@ from novelai_python import APIError, LoginCredential from novelai_python import GenerateImageInfer, ImageGenerateResp, JwtCredential from novelai_python.sdk.ai._enum import UCPreset -from novelai_python.sdk.ai.generate_image import Action, Model, Sampler +from novelai_python.sdk.ai.generate_image import Action, Model, Sampler, Character +from novelai_python.sdk.ai.generate_image.schema import PositionMap from novelai_python.utils.useful import enum_to_list -async def generate(prompt="1girl, year 2023, dynamic angle, best quality, amazing quality, very aesthetic, absurdres"): +async def generate( + prompt="1girl, year 2023, dynamic angle, best quality, amazing quality, very aesthetic, absurdres" +): jwt = os.getenv("NOVELAI_JWT", None) if jwt is None: raise ValueError("NOVELAI_JWT is not set in `.env` file, please create one and set it") @@ -29,16 +32,39 @@ async def generate(prompt="1girl, year 2023, dynamic angle, best quality, amazin ) # await _login_credential.request() print(f"Action List:{enum_to_list(Action)}") + print( + """ + .1 .3 .5 .7 .9 + A1 B1 C1 D1 E1 + A2 B2 C2 D2 E2 + A3 B3 C3 D3 E3 + .............. + A5 B5 C5 D5 E5 + """ + ) try: - agent = GenerateImageInfer.build( + agent = GenerateImageInfer.build_generate( prompt=prompt, - model=Model.NAI_DIFFUSION_3, - action=Action.GENERATE, - sampler=Sampler.K_DPMPP_2M, - ucPreset=UCPreset.TYPE0, # Recommended, using preset negative_prompt depends on selected model + model=Model.NAI_DIFFUSION_4_CURATED_PREVIEW, + character_prompts=[ + Character( + prompt="1girl", + uc="red hair", + center=PositionMap.AUTO + ), + Character( + prompt="1boy", + center=PositionMap.E5 + ) + ], + sampler=Sampler.K_EULER_ANCESTRAL, + ucPreset=UCPreset.TYPE0, + # Recommended, using preset negative_prompt depends on selected model + qualitySuffix=True, qualityToggle=True, decrisp_mode=False, - variety_boost=True, # Checkbox in website + variety_boost=True, + # Checkbox in novelai.net ) print(f"charge: {agent.calculate_cost(is_opus=True)} if you are vip3") print(f"charge: {agent.calculate_cost(is_opus=False)} if you are not vip3") diff --git a/playground/generate_image_img2img.py b/playground/generate_image_img2img.py index 97cc120..07a9543 100755 --- a/playground/generate_image_img2img.py +++ b/playground/generate_image_img2img.py @@ -41,15 +41,12 @@ async def generate( # Base64 encode the image image = base64.b64encode(f.read()).decode() # image = f.read() # Or you can use the raw bytes - agent = GenerateImageInfer.build( + agent = GenerateImageInfer.build_img2img( prompt=prompt, - action=Action.IMG2IMG, sampler=Sampler.K_DPMPP_SDE, image=image, - add_original_image=False, - strength=0.9, - noise=0.1, - qualityToggle=True, + seed=123456789, + extra_noise_seed=123123123, ) print(f"charge: {agent.calculate_cost(is_opus=True)} if you are vip3") print(f"charge: {agent.calculate_cost(is_opus=False)} if you are not vip3") diff --git a/playground/simple.py b/playground/simple.py index 0ae59ab..2bb3903 100644 --- a/playground/simple.py +++ b/playground/simple.py @@ -1,15 +1,19 @@ import asyncio +from novelai_python.sdk.ai.generate_image import Model + async def main(): from pydantic import SecretStr - from novelai_python import GenerateImageInfer, ApiCredential, LoginCredential + from novelai_python import GenerateImageInfer, LoginCredential credential = LoginCredential( username="NOVELAI_USERNAME", password=SecretStr("NOVELAI_PASSWORD") ) - gen = GenerateImageInfer.build( - prompt="1girl, year 2023, dynamic angle, best quality, amazing quality, very aesthetic, absurdres") + gen = GenerateImageInfer.build_generate( + prompt="1girl, year 2023, dynamic angle, best quality, amazing quality, very aesthetic, absurdres", + model=Model.NAI_DIFFUSION_3, + ) print(f"消耗点数: vip3:{gen.calculate_cost(is_opus=True)}, {gen.calculate_cost(is_opus=False)}") resp = await gen.request(session=credential) with open("image.png", "wb") as f: diff --git a/playground/vibe.py b/playground/vibe.py index 859bf66..e6fa4bd 100644 --- a/playground/vibe.py +++ b/playground/vibe.py @@ -8,7 +8,7 @@ from novelai_python import APIError, Login from novelai_python import GenerateImageInfer, ImageGenerateResp, JwtCredential -from novelai_python.sdk.ai.generate_image import Action, Sampler +from novelai_python.sdk.ai.generate_image import Action, Sampler, Model from novelai_python.utils.useful import enum_to_list @@ -32,15 +32,15 @@ async def generate( raise ValueError(f"Image not found: {image_path}") with open(image_path, "rb") as f: image = f.read() - agent = GenerateImageInfer.build( + agent = GenerateImageInfer.build_generate( prompt=prompt, - action=Action.GENERATE, sampler=Sampler.K_DPMPP_SDE, - reference_image=image, - reference_strength=0.9, - reference_information_extracted=1, - add_original_image=True, # This Not affect the vibe generation - qualityToggle=True, + model=Model.NAI_DIFFUSION_3, + reference_image_multiple=[image], + reference_strength_multiple=[0.9], + reference_information_extracted_multiple=[1], + add_original_image=True, + # This Not affect the vibe generation ) print(f"charge: {agent.calculate_cost(is_opus=True)} if you are vip3") print(f"charge: {agent.calculate_cost(is_opus=False)} if you are not vip3") diff --git a/playground/vibe_img2img.py b/playground/vibe_img2img.py index ab13145..d247d10 100644 --- a/playground/vibe_img2img.py +++ b/playground/vibe_img2img.py @@ -37,18 +37,14 @@ async def generate( image = f.read() with open(reference_image_path, "rb") as f: reference_image = f.read() - agent = GenerateImageInfer.build( + agent = GenerateImageInfer.build_img2img( prompt=prompt, - action=Action.IMG2IMG, sampler=Sampler.K_DPMPP_SDE, - image=image, strength=0.6, - - reference_image=reference_image, - reference_strength=0.6, - reference_information_extracted=1, - + reference_image_multiple=[reference_image], + reference_strength_multiple=[0.9], + reference_information_extracted_multiple=[1], add_original_image=True, # This Not affect the vibe generation qualityToggle=True, ) diff --git a/playground/vibe_inpaint.py b/playground/vibe_inpaint.py index b776295..394483b 100644 --- a/playground/vibe_inpaint.py +++ b/playground/vibe_inpaint.py @@ -2,14 +2,15 @@ import asyncio import os import pathlib + from dotenv import load_dotenv from pydantic import SecretStr from novelai_python import APIError, Login from novelai_python import GenerateImageInfer, ImageGenerateResp, JwtCredential from novelai_python.sdk.ai.generate_image import Action, Sampler, Model -from novelai_python.utils.useful import enum_to_list from novelai_python.tool.paint_mask import create_mask_from_sketch +from novelai_python.utils.useful import enum_to_list with open('static_image.png', 'rb') as f: ori_bytes = f.read() @@ -55,18 +56,17 @@ async def generate( reference_image = f.read() with open(mask_path, "rb") as f: mask = f.read() - agent = GenerateImageInfer.build( + agent = GenerateImageInfer.build_infill( prompt=prompt, - action=Action.INFILL, model=Model.NAI_DIFFUSION_3_INPAINTING, sampler=Sampler.K_DPMPP_SDE, image=image, mask=mask, strength=0.6, - reference_image=reference_image, - reference_strength=0.6, - reference_information_extracted=1, + reference_image_multiple=[reference_image], + reference_strength_multiple=[0.9], + reference_information_extracted_multiple=[1], add_original_image=True, # This Not affect the vibe generation qualityToggle=True, @@ -88,5 +88,5 @@ async def generate( load_dotenv() -loop = asyncio.get_event_loop() +loop = asyncio.new_event_loop() loop.run_until_complete(generate()) diff --git a/pyproject.toml b/pyproject.toml index 90c2e60..bffb529 100755 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "novelai-python" -version = "0.5.3" +version = "0.6.0" description = "NovelAI Python Binding With Pydantic" authors = [ { name = "sudoskys", email = "coldlando@hotmail.com" }, @@ -9,7 +9,7 @@ dependencies = [ "elara>=0.5.5", "loguru>=0.7.2", "pydantic-settings>=2.1.0", - "pydantic>=2.5.3", + "pydantic>=2.9.0", "httpx>=0.26.0", "shortuuid>=1.0.11", "Pillow>=10.2.0", diff --git a/src/novelai_python/sdk/ai/_cost.py b/src/novelai_python/sdk/ai/_cost.py index 8963110..3f9cc95 100644 --- a/src/novelai_python/sdk/ai/_cost.py +++ b/src/novelai_python/sdk/ai/_cost.py @@ -11,9 +11,9 @@ class Args(BaseModel): height: int width: int - image: Optional[str] + image: bool n_samples: int - strength: float + strength: Optional[float] steps: int sm: bool sm_dyn: bool @@ -34,11 +34,10 @@ def calculate( width: int, height: int, steps: int, - image: str, + image: bool, n_samples: int, account_tier: int, - strength: float, - + strength: Optional[float], is_sm_enabled: bool, is_sm_dynamic: bool, is_account_active: bool, @@ -138,14 +137,15 @@ def prepare_array() -> List[int]: dimension = 65536 base_dimension = 1048576 - strength_multiplier = params.strength if params.image else 1 + strength_multiplier = params.strength if (isinstance(params.strength, float) and params.image) else 1 steps = params.steps samples = params.n_samples if steps <= 28 and dimension <= base_dimension and account_tier >= 3 and is_account_active and not is_tool_active: samples -= 1 - if model_group and model_group in [ModelGroups.STABLE_DIFFUSION_XL, ModelGroups.STABLE_DIFFUSION_XL_FURRY]: + if model_group and model_group in [ModelGroups.STABLE_DIFFUSION_XL, ModelGroups.STABLE_DIFFUSION_XL_FURRY, + ModelGroups.V4]: cost = calculate_dimension_cost(img_width, img_height, steps, params.sm, params.sm_dyn) elif dimension <= base_dimension and params.sampler in [ Sampler.PLMS, Sampler.DDIM, diff --git a/src/novelai_python/sdk/ai/_enum.py b/src/novelai_python/sdk/ai/_enum.py index dc1d184..233a285 100644 --- a/src/novelai_python/sdk/ai/_enum.py +++ b/src/novelai_python/sdk/ai/_enum.py @@ -92,6 +92,8 @@ class Resolution(Enum): class Model(Enum): + NAI_DIFFUSION_4_CURATED_PREVIEW = "nai-diffusion-4-curated-preview" + NAI_DIFFUSION_3 = "nai-diffusion-3" NAI_DIFFUSION_3_INPAINTING = "nai-diffusion-3-inpainting" NAI_DIFFUSION_FURRY_3 = "nai-diffusion-furry-3" @@ -112,6 +114,7 @@ class Model(Enum): WAIFU_DIFFUSION = "waifu-diffusion" CURATED_DIFFUSION_TEST = "curated-diffusion-test" NAI_DIFFUSION_XL = "nai-diffusion-xl" + DALLE_MINI = "dalle-mini" class ModelGroups(Enum): @@ -119,6 +122,7 @@ class ModelGroups(Enum): STABLE_DIFFUSION_GROUP_2 = "stable_diffusion_group2" STABLE_DIFFUSION_XL = "stable_diffusion_xl" STABLE_DIFFUSION_XL_FURRY = "stable_diffusion_xl_furry" + V4 = "v4" INPAINTING_MODEL_LIST = [ @@ -155,6 +159,158 @@ class ModelGroups(Enum): UCPresetTypeAlias = Optional[Union[UCPreset, int]] +@dataclass +class SupportCondition: + controlnet: bool + vibetransfer: bool + scaleMax: int + negativePromptGuidance: bool + noiseSchedule: bool + inpainting: bool + cfgDelay: bool + characterPrompts: bool + v4Prompts: bool + smea: bool + text: bool + + +def get_supported_params(model: Model): + """ + Get supported parameters for a given model + :param model: Model + :return: SupportCondition + """ + if model in [ + Model.STABLE_DIFFUSION, + Model.NAI_DIFFUSION, + Model.SAFE_DIFFUSION, + Model.WAIFU_DIFFUSION, + Model.NAI_DIFFUSION_FURRY, + Model.CURATED_DIFFUSION_TEST, + Model.NAI_DIFFUSION_INPAINTING, + Model.SAFE_DIFFUSION_INPAINTING, + Model.FURRY_DIFFUSION_INPAINTING + ]: + return SupportCondition( + controlnet=True, + vibetransfer=False, + scaleMax=25, + negativePromptGuidance=False, + noiseSchedule=False, + inpainting=True, + cfgDelay=False, + characterPrompts=False, + v4Prompts=False, + smea=True, + text=False + ) + if model in [Model.NAI_DIFFUSION_2]: + return SupportCondition( + controlnet=True, + vibetransfer=False, + scaleMax=25, + negativePromptGuidance=True, + noiseSchedule=False, + inpainting=True, + cfgDelay=False, + characterPrompts=False, + v4Prompts=False, + smea=True, + text=False + ) + if model in [ + Model.NAI_DIFFUSION_XL, + Model.NAI_DIFFUSION_3, + Model.NAI_DIFFUSION_3_INPAINTING, + Model.NAI_DIFFUSION_FURRY_3, + Model.NAI_DIFFUSION_FURRY_3_INPAINTING + ]: + return SupportCondition( + controlnet=False, + vibetransfer=True, + scaleMax=10, + negativePromptGuidance=True, + noiseSchedule=True, + inpainting=True, + cfgDelay=True, + characterPrompts=False, + v4Prompts=False, + smea=True, + text=False + ) + if model in [Model.CUSTOM, Model.NAI_DIFFUSION_4_CURATED_PREVIEW]: + return SupportCondition( + controlnet=False, + vibetransfer=False, + scaleMax=10, + negativePromptGuidance=True, + noiseSchedule=True, + inpainting=True, + cfgDelay=False, + characterPrompts=True, + v4Prompts=True, + smea=False, + text=True + ) + return SupportCondition( + controlnet=False, + vibetransfer=False, + scaleMax=25, + negativePromptGuidance=False, + noiseSchedule=False, + inpainting=False, + cfgDelay=False, + characterPrompts=False, + v4Prompts=False, + smea=False, + text=False + ) + + +@dataclass +class Modifier(object): + qualityTags: str + suffix: str + + +def get_modifiers(model: Model) -> Modifier: + """ + Get modifiers from model + :param model: + :return: + """ + if model in [Model.CUSTOM, Model.NAI_DIFFUSION_4_CURATED_PREVIEW]: + return Modifier( + qualityTags="", + suffix=", rating:general, amazing quality, very aesthetic, absurdres" + ) + if model in [Model.NAI_DIFFUSION_2]: + return Modifier( + qualityTags="very aesthetic, best quality, absurdres, ", + suffix="" + ) + if model in [ + Model.NAI_DIFFUSION_3, + Model.NAI_DIFFUSION_3_INPAINTING + ]: + return Modifier( + qualityTags="", + suffix=", best quality, amazing quality, very aesthetic, absurdres" + ) + if model in [ + Model.NAI_DIFFUSION_FURRY_3, + Model.NAI_DIFFUSION_FURRY_3_INPAINTING + ]: + return Modifier( + qualityTags="", + suffix=", {best quality}, {amazing quality}" + ) + return Modifier( + qualityTags="masterpiece, best quality, ", + suffix="" + ) + + def get_supported_noise_schedule(sample_type: Sampler) -> List[NoiseSchedule]: """ Get supported noise schedule for a given sample type @@ -224,9 +380,10 @@ def get_model_group(model: ModelTypeAlias) -> ModelGroups: "nai-diffusion-xl": ModelGroups.STABLE_DIFFUSION_XL, "nai-diffusion-3": ModelGroups.STABLE_DIFFUSION_XL, "nai-diffusion-3-inpainting": ModelGroups.STABLE_DIFFUSION_XL, - "custom": ModelGroups.STABLE_DIFFUSION_XL, + "custom": ModelGroups.V4, "nai-diffusion-furry-3": ModelGroups.STABLE_DIFFUSION_XL_FURRY, "nai-diffusion-furry-3-inpainting": ModelGroups.STABLE_DIFFUSION_XL_FURRY, + "nai-diffusion-4-curated-preview": ModelGroups.V4, } return mapping.get(model, ModelGroups.STABLE_DIFFUSION) diff --git a/src/novelai_python/sdk/ai/augment_image/__init__.py b/src/novelai_python/sdk/ai/augment_image/__init__.py index 9a96630..11060bd 100644 --- a/src/novelai_python/sdk/ai/augment_image/__init__.py +++ b/src/novelai_python/sdk/ai/augment_image/__init__.py @@ -85,7 +85,7 @@ def calculate_cost(self, is_opus: bool = False) -> float: height=self.height, steps=28, model=Model.NAI_DIFFUSION_3, - image=self.image, + image=bool(self.image), n_samples=1, account_tier=1, strength=1, @@ -100,7 +100,7 @@ def calculate_cost(self, is_opus: bool = False) -> float: height=self.height, steps=28, model=Model.NAI_DIFFUSION_3, - image=self.image, + image=bool(self.image), n_samples=1, account_tier=3 if is_opus else 1, strength=1, diff --git a/src/novelai_python/sdk/ai/generate_image/__init__.py b/src/novelai_python/sdk/ai/generate_image/__init__.py index 4e998fb..b5c6770 100755 --- a/src/novelai_python/sdk/ai/generate_image/__init__.py +++ b/src/novelai_python/sdk/ai/generate_image/__init__.py @@ -1,12 +1,13 @@ # -*- coding: utf-8 -*- -# @Time : 2024/2/13 下午8:08 # @Author : sudoskys -# @File : __init__.py.py -# @Software: PyCharm +# @File : __init__.py + import base64 import json +import math import random from copy import deepcopy +from dataclasses import field from io import BytesIO from typing import Optional, Union, Tuple, List from urllib.parse import urlparse @@ -25,8 +26,10 @@ from novelai_python.sdk.ai._cost import CostCalculator from novelai_python.sdk.ai._enum import Model, Sampler, NoiseSchedule, ControlNetModel, Action, UCPreset, \ - INPAINTING_MODEL_LIST, get_default_noise_schedule, get_supported_noise_schedule, get_default_uc_preset, \ - ModelTypeAlias, ImageBytesTypeAlias, UCPresetTypeAlias + INPAINTING_MODEL_LIST, get_default_uc_preset, \ + ModelTypeAlias, UCPresetTypeAlias, get_default_noise_schedule, get_supported_noise_schedule, \ + get_model_group, ModelGroups, get_supported_params, get_modifiers +from .schema import Character, V4Prompt, V4NegativePrompt from ...schema import ApiBaseModel from ...._exceptions import APIError, AuthError, ConcurrentGenerationError, SessionHttpError from ...._response.ai.generate_image import ImageGenerateResp, RequestParams @@ -40,63 +43,208 @@ def is_multiple_of_01(num, precision=1e-10): class Params(BaseModel): - add_original_image: Optional[bool] = Field(True, description="Overlay Original Image") + width: int = Field(832, ge=64, le=49152) + """Width For Image""" + height: int = Field(1216, ge=64, le=49152) + """Height For Image""" + scale: float = Field(6.0, ge=0, le=10, multiple_of=0.1) + """Prompt Guidance""" + sampler: Sampler = Sampler.K_EULER_ANCESTRAL + """Sampler For Generate Image""" + steps: int = Field(23, ge=1, le=50) + """Steps""" + n_samples: int = Field(1, ge=1, le=8) + """Number of samples""" + strength: Optional[float] = Field(0.7, ge=0.01, le=0.99, multiple_of=0.01) + """Strength for img2img""" + noise: Optional[float] = Field(0, ge=0, le=0.99, multiple_of=0.01) + """Noise for img2img""" + ucPreset: UCPresetTypeAlias = Field(None, ge=0) + """The Negative Prompt Preset, Bigger or equal to 0""" + qualityToggle: bool = True + """Whether to add the quality prompt""" + sm: Optional[bool] = False + # TODO: find out the usage + sm_dyn: Optional[bool] = False + # TODO: find out the usage + dynamic_thresholding: bool = False + """Decrisp:Reduce artifacts caused by high prompt guidance values""" + controlnet_strength: float = Field(1.0, ge=0.1, le=2, multiple_of=0.1) + """ControlNet Strength""" + legacy: bool = False + """Legacy Mode""" + cfg_rescale: Optional[float] = Field(0, ge=0, le=1, multiple_of=0.02) + """Prompt Guidance Rescale""" + noise_schedule: Optional[NoiseSchedule] = None + """Noise Schedule""" + legacy_v3_extend: Optional[bool] = False + """Legacy V3 Extend""" + mask: Union[bytes, str] = None + """Mask for Inpainting""" + seed: int = Field( + default_factory=lambda: random.randint(0, 4294967295 - 7), + gt=0, + le=4294967295 - 7, + ) + """Seed""" + image: Union[bytes, str] = None + """Image for img2img""" + negative_prompt: Optional[str] = '' + """Negative Prompt""" + reference_image_multiple: Optional[List[Union[str, bytes]]] = field(default_factory=list) + """Reference Image For Vibe Mode""" + reference_information_extracted_multiple: Optional[List[float]] = field(default_factory=list) + """Reference Information Extracted For Vibe Mode""" + reference_strength_multiple: Optional[List[float]] = Field( + default=list, + description="Reference Strength For Vibe Mode" + ) + """Reference Strength For Vibe Mode""" + extra_noise_seed: Optional[int] = Field(None, gt=0, le=4294967295 - 7) + """Extra Noise Seed""" + + # ====Version3 ==== + params_version: int = 3 + """Params Version For Request""" + add_original_image: Optional[bool] = Field(False, description="Overlay Original Image") """ Overlay Original Image.Prevents the existing image from changing, but can introduce seams along the edge of the mask. - 叠加原始图像 - 防止现有图像发生更改,但可能会沿蒙版边缘引入接缝。 """ - mask: ImageBytesTypeAlias = None - """Mask for Inpainting""" - cfg_rescale: Optional[float] = Field(0, ge=0, le=1, multiple_of=0.02) - """Prompt Guidance Rescale""" - controlnet_strength: Optional[float] = Field(1.0, ge=0.1, le=2, multiple_of=0.1) - """ControlNet Strength""" - dynamic_thresholding: Optional[bool] = False - """Decrisp:Reduce artifacts caused by high prompt guidance values""" - height: Optional[int] = Field(1216, ge=64, le=49152) - """Height For Generate Image""" - image: ImageBytesTypeAlias = None - """Image for img2img""" - strength: Optional[float] = Field(default=0.5, ge=0.01, le=0.99, multiple_of=0.01) - """Strength for img2img""" - noise: Optional[float] = Field(default=0, ge=0, le=0.99, multiple_of=0.01) - """Noise for img2img""" + use_coords: bool = Field(True, description="Use Coordinates") + """Use Coordinates""" + characterPrompts: List[Character] = field(default_factory=list) + """Character Prompts""" + + v4_prompt: Optional[V4Prompt] = Field(None, description="V4 Prompt") + """V4 Prompt""" + v4_negative_prompt: Optional[V4NegativePrompt] = Field(None, description="V4 Negative Prompt") + """V4 Negative Prompt""" + + deliberate_euler_ancestral_bug: Optional[bool] = Field(False, description="Deliberate Euler Ancestral Bug") + """Deliberate Euler Ancestral Bug""" + prefer_brownian: bool = Field(True, description="Prefer Brownian") + """Prefer Brownian""" + + # ======== V1 ======== controlnet_condition: Optional[str] = None """ControlNet Condition""" controlnet_model: Optional[ControlNetModel] = None """ControlNet Model""" - n_samples: Optional[int] = Field(1, ge=1, le=8) - """Number of samples""" - negative_prompt: Optional[str] = '' - """Negative Prompt""" - noise_schedule: Optional[NoiseSchedule] = None - """Noise Schedule""" - # Misc - params_version: Optional[int] = 1 - """Params Version For Request""" - reference_image_multiple: Optional[List[Union[str, bytes]]] = None - """Reference Image For Vibe Mode""" - reference_information_extracted_multiple: Optional[List[float]] = None - """Reference Information Extracted For Vibe Mode""" + skip_cfg_above_sigma: Optional[int] = None + """Variety Boost, a new feature to improve the diversity of samples.""" + uncond_scale: Optional[float] = Field(None, ge=0, le=1.5, multiple_of=0.05) + """Undesired Content Strength""" - @field_validator('reference_information_extracted_multiple') - def reference_information_extracted_multiple_validator(cls, v): - # List[Field(..., ge=0, le=1, multiple_of=0.01)] - if v is None: - return v - for i in v: - if not 0 <= i <= 1: - raise ValueError("Invalid reference_information_extracted_multiple, must be in [0, 1].") - if not is_multiple_of_01(i): - raise ValueError("Invalid reference_information_extracted_multiple, must be multiple of 0.01.") + @field_validator('uncond_scale') + def v_uncond_scale(cls, v: float): + """ + Align + :param v: + :return: fixed value + """ + if v == 0: + v = 0.00001 return v - reference_strength_multiple: Optional[List[float]] = None + @field_validator('width') + def v_width(cls, v: int): + """ + Must be multiple of 64 + :param v: + :return: fixed value + """ + if v % 64 != 0: + raise ValueError("Invalid width, must be multiple of 64.") + return v + + @field_validator('height') + def v_height(cls, v: int): + """ + Must be multiple of 64 + :param v: + :return: fixed value + """ + if v % 64 != 0: + raise ValueError("Invalid height, must be multiple of 64.") + return v + + @model_validator(mode="after") + def _build_image(self): + # == Mask == + if self.mask is not None: + if isinstance(self.mask, str) and self.mask.startswith("data:"): + raise ValueError( + "Invalid `mask` format, must be base64 encoded directly, " + "you can also provide bytes directly." + ) + if isinstance(self.mask, bytes): + self.mask = base64.b64encode(self.mask).decode("utf-8") + + # == Image == + if self.image is not None: + if isinstance(self.image, str) and self.image.startswith("data:"): + raise ValueError( + "Invalid `image` format, must be base64 encoded directly, " + "you can also provide bytes directly." + ) + if isinstance(self.image, bytes): + self.image = base64.b64encode(self.image).decode("utf-8") + self.image = self.resize_image( + self.image, + self.width, + self.height + ) + return self + + @model_validator(mode="after") + def _build_reference_image(self): + # Resize the image to the specified size + if self.reference_image_multiple is not None: + new_images = [] + for reference_image in self.reference_image_multiple: + if isinstance(reference_image, str): + if reference_image.startswith("data:"): + raise ValueError("Invalid `reference_image` format, must be base64 encoded directly.") + new_images.append(reference_image) + elif isinstance(reference_image, bytes): + new_image = self.add_image_to_black_background( + reference_image, + target_size=(448, 448), + transparency=True + ) + if isinstance(new_image, bytes): + new_image = base64.b64encode(new_image).decode("utf-8") + new_images.append(new_image) + else: + raise ValueError("Invalid `reference_image` format, must be base64 encoded directly.") + self.reference_image_multiple = new_images + # 如果都不是 None 时,比较他们的长度 + if all([ + self.reference_strength_multiple, + self.reference_image_multiple, + self.reference_information_extracted_multiple + ]): + if len(self.reference_strength_multiple) != len(self.reference_image_multiple) != len( + self.reference_information_extracted_multiple): + raise ValueError( + f"All three reference_* must be of equal length, " + f"strength:{len(self.reference_strength_multiple)}, " + f"image:{len(self.reference_image_multiple)}, " + f"information:{len(self.reference_information_extracted_multiple)}" + ) + if len(self.reference_image_multiple) > 16: + raise ValueError("The maximum number of reference images is 16") + # 如果有一个存在,其他都必须存在 + ref_items = [self.reference_strength_multiple, + self.reference_image_multiple, + self.reference_information_extracted_multiple] + if any(ref_items) and not all(ref_items): + raise ValueError("All fields must be present together or none should be present") + return self @field_validator('reference_strength_multiple') - def reference_strength_multiple_validator(cls, v): + def v_reference_strength_multiple(cls, v): # Field(0.6,ge=0,le=1,multiple_of=0.01,description="the stronger the AI will try to emulate visual cues.") if v is None: return v @@ -104,47 +252,20 @@ def reference_strength_multiple_validator(cls, v): if not 0 <= i <= 1: raise ValueError("Invalid reference_strength_multiple, must be in [0, 1].") if not is_multiple_of_01(i): - raise ValueError("Invalid reference_strength_multiple, must be multiple of 0.01.") + raise ValueError("Invalid reference_strength_multiple item, must be multiple of 0.01.") return v - """Reference Strength For Vibe Mode""" - legacy: Optional[bool] = False - # TODO: find out the usage - legacy_v3_extend: Optional[bool] = False - # TODO: find out the usage - qualityToggle: Optional[bool] = True - """Whether to add the quality prompt""" - sampler: Optional[Sampler] = Sampler.K_EULER_ANCESTRAL - """Sampler For Generate Image""" - scale: Optional[float] = Field(6.0, ge=0, le=10, multiple_of=0.1) - """Prompt Guidance""" - # Seed - seed: Optional[int] = Field( - default_factory=lambda: random.randint(0, 4294967295 - 7), - gt=0, - le=4294967295 - 7, - ) - """Seed""" - skip_cfg_above_sigma: Optional[int] = None - """Variety Boost, a new feature to improve the diversity of samples.""" - extra_noise_seed: Optional[int] = Field( - default_factory=lambda: random.randint(0, 4294967295 - 7), - gt=0, - le=4294967295 - 7, - ) - """Extra Noise Seed""" - sm: Optional[bool] = False - # TODO: find out the usage - sm_dyn: Optional[bool] = False - # TODO: find out the usage - steps: Optional[int] = Field(23, ge=1, le=50) - """Steps""" - ucPreset: UCPresetTypeAlias = Field(None, ge=0) - """The Negative Prompt Preset, Bigger or equal to 0""" - uncond_scale: Optional[float] = Field(1.0, ge=0, le=1.5, multiple_of=0.05) - """Undesired Content Strength""" - width: Optional[int] = Field(832, ge=64, le=49152) - """Width For Image""" + @field_validator('reference_information_extracted_multiple') + def v_reference_information_extracted_multiple(cls, v): + # List[Field(..., ge=0, le=1, multiple_of=0.01)] + if v is None: + return v + for i in v: + if not 0 <= i <= 1: + raise ValueError("Invalid reference_information_extracted_multiple, must be in [0, 1].") + if not is_multiple_of_01(i): + raise ValueError("Invalid reference_information_extracted_multiple item, must be multiple of 0.01.") + return v @staticmethod def resize_image(image: Union[str, bytes], width: int, height: int): @@ -213,104 +334,6 @@ def add_image_to_black_background( image_bytes = buffer.tobytes() return base64.b64encode(image_bytes).decode("utf-8") - # Validators - @model_validator(mode="after") - def image_validator(self): - # Noise schedule check - if self.noise_schedule is None: - self.noise_schedule = get_default_noise_schedule(self.sampler) - supported_noise_schedule = get_supported_noise_schedule(self.sampler) - if supported_noise_schedule: - if self.noise_schedule not in supported_noise_schedule: - raise ValueError(f"Invalid noise_schedule, must be one of {supported_noise_schedule}") - else: - logger.warning(f"Inactive sampler {self.sampler} does not support noise_schedule.") - # Check the noise value - if self.sampler: - if self.sampler in [Sampler.DDIM, Sampler.DDIM_V3]: - self.sm = False - self.sm_dyn = False - if self.sm_dyn or self.sm: - logger.warning("sm and sm_dyn is disabled when using ddim sampler.") - if self.sampler in [Sampler.NAI_SMEA_DYN]: - self.sm = True - self.sm_dyn = True - if not self.sm_dyn: - logger.warning("sm and sm_dyn is enabled when using nai_smea_dyn sampler.") - # Make sure the image is base64 encoded - if isinstance(self.image, str) and self.image.startswith("data:"): - raise ValueError("Invalid `image` format, must be base64 encoded directly.") - if isinstance(self.mask, str) and self.mask.startswith("data:"): - raise ValueError("Invalid `mask` format, must be base64 encoded directly.") - if isinstance(self.image, bytes): - self.image = base64.b64encode(self.image).decode("utf-8") - # Resize the image to the specified size - if self.reference_image_multiple is not None: - new_images = [] - for reference_image in self.reference_image_multiple: - if isinstance(reference_image, str): - if reference_image.startswith("data:"): - raise ValueError("Invalid `reference_image` format, must be base64 encoded directly.") - new_images.append(reference_image) - elif isinstance(reference_image, bytes): - new_image = self.add_image_to_black_background(reference_image, - target_size=(448, 448), - transparency=True) - if isinstance(new_image, bytes): - new_image = base64.b64encode(new_image).decode("utf-8") - new_images.append(new_image) - else: - raise ValueError("Invalid `reference_image` format, must be base64 encoded directly.") - self.reference_image_multiple = new_images - # 如果都不是 None 时,比较他们的长度 - if all([self.reference_strength_multiple, - self.reference_image_multiple, - self.reference_information_extracted_multiple]): - if len(self.reference_strength_multiple) != len(self.reference_image_multiple) != len( - self.reference_information_extracted_multiple): - raise ValueError( - f"All three reference_* must be of equal length, " - f"strength:{len(self.reference_strength_multiple)}, " - f"image:{len(self.reference_image_multiple)}, " - f"information:{len(self.reference_information_extracted_multiple)}" - ) - if len(self.reference_image_multiple) > 16: - raise ValueError("The maximum number of reference images is 16") - # 如果有一个存在,其他都必须存在 - ref_items = [self.reference_strength_multiple, - self.reference_image_multiple, - self.reference_information_extracted_multiple] - if any(ref_items) and not all(ref_items): - raise ValueError("All fields must be present together or none should be present") - - if isinstance(self.mask, bytes): - self.mask = base64.b64encode(self.mask).decode("utf-8") - if self.image is not None: - self.image = self.resize_image(self.image, self.width, self.height) - return self - - @field_validator('width') - def width_validator(cls, v: int): - """ - Must be multiple of 64 - :param v: - :return: fixed value - """ - if v % 64 != 0: - raise ValueError("Invalid width, must be multiple of 64.") - return v - - @field_validator('height') - def height_validator(cls, v: int): - """ - Must be multiple of 64 - :param v: - :return: fixed value - """ - if v % 64 != 0: - raise ValueError("Invalid height, must be multiple of 64.") - return v - class GenerateImageInfer(ApiBaseModel): _endpoint: str = PrivateAttr("https://image.novelai.net") @@ -326,7 +349,7 @@ def endpoint(self, value): action: Union[str, Action] = Field(Action.GENERATE, description="Mode for img generate") input: str = "1girl, best quality, amazing quality, very aesthetic, absurdres" model: ModelTypeAlias = "nai-diffusion-3" - parameters: Params = Params() + parameters: Union[Params] model_config = ConfigDict(extra="ignore") @override @@ -349,40 +372,164 @@ def model_post_init(self, *args) -> None: ) # Add quality prompt + modifier = get_modifiers(self.model) if self.parameters.qualityToggle: - self.input += ", best quality, amazing quality, very aesthetic, absurdres" + self.input += modifier.qualityTags + + @model_validator(mode="after") + def _build_nai4_prompt(self): + """ + Build V4Prompt and V4NegativePrompt from character prompts. + :return: self + """ + if get_supported_params(self.model).v4Prompts: + if self.parameters.v4_prompt is None: + self.parameters.v4_prompt = V4Prompt.build_from_character_prompts( + prompt=self.input, + character_prompts=self.parameters.characterPrompts + ) + if self.parameters.v4_negative_prompt is None: + self.parameters.v4_negative_prompt = V4NegativePrompt.build_from_character_prompts( + negative_prompt=self.parameters.negative_prompt, + character_prompts=self.parameters.characterPrompts + ) + if not get_supported_params(self.model).vibetransfer: + if self.parameters.reference_image_multiple: + logger.warning("Vibe transfer is not supported for this model.") + self.parameters.reference_image_multiple = [] + self.parameters.reference_information_extracted_multiple = [] + self.parameters.reference_strength_multiple = [] + + if not get_supported_params(self.model).controlnet: + if self.parameters.controlnet_condition is not None: + logger.warning("ControlNet is not supported for this model.") + self.parameters.controlnet_condition = None + if self.parameters.controlnet_model is not None: + logger.warning("ControlNet is not supported for this model.") + self.parameters.controlnet_model = None + return self @model_validator(mode="after") - def validate_model(self): + def _backend_logic(self): """ - Check the conflict between parameters and simulate website logic. + Backend logic for GenerateImageInfer. :return: self """ - # Text2Img mode if self.action == Action.GENERATE: if self.parameters.image is not None: - raise ValueError("image is not required for non-generate mode.") + raise ValueError("You are using generate action, image is not required for non-generate mode.") if self.parameters.mask is not None: - raise ValueError("mask is not required for non-generate mode.") - # Infill mode + raise ValueError("You are using generate action, mask is not required for non-generate mode.") + if self.action == Action.INFILL: if self.model not in INPAINTING_MODEL_LIST: raise ValueError(f"You must use {INPAINTING_MODEL_LIST}") if not self.parameters.mask: logger.warning("Mask maybe required for infill mode!") - # Sync seed - if self.action != Action.GENERATE: - self.parameters.extra_noise_seed = self.parameters.seed - # Img2Img mode + + if self.action == Action.IMG2IMG: + if self.parameters.extra_noise_seed is None: + self.parameters.extra_noise_seed = self.parameters.seed + if self.action == Action.IMG2IMG: if self.parameters.sm_dyn is True: - logger.warning("sm_dyn is disabled when sm in Img2Img mode.") + logger.warning("sm_dyn be disabled when sm in Img2Img mode.") if self.parameters.sm is True: - logger.warning("sm is disabled when sm_dyn in Img2Img mode.") + logger.warning("sm be disabled when sm_dyn in Img2Img mode.") self.parameters.sm = False self.parameters.sm_dyn = False if self.parameters.image is None: raise ValueError("image is must required for img2img mode.") + + # Check Image + if self.parameters.image is None: + self.parameters.strength = None + self.parameters.noise = None + + # == Sampler == + if self.parameters.sampler in [Sampler.NAI_SMEA]: + self.parameters.sm = True + self.parameters.sampler = Sampler.K_EULER_ANCESTRAL + + if self.parameters.sampler in [Sampler.NAI_SMEA_DYN]: + if not self.parameters.sm_dyn: + logger.warning("sm and sm_dyn is enabled when using nai_smea_dyn sampler.") + self.parameters.sampler = Sampler.K_EULER_ANCESTRAL + self.parameters.sm = True + self.parameters.sm_dyn = True + + if self.parameters.sm_dyn and (not self.parameters.sm): + self.parameters.sm_dyn = False + + if self.parameters.sampler in [ + Sampler.DDIM, + Sampler.DDIM_V3 + ]: + if self.parameters.sm_dyn or self.parameters.sm: + logger.warning("sm and sm_dyn is disabled when using ddim sampler.") + self.parameters.sm = False + self.parameters.sm_dyn = False + + if self.action != Action.INFILL: + self.parameters.mask = None + + if self.parameters.uncond_scale == 0: + self.parameters.uncond_scale = 0.00001 + + if get_model_group(self.model) == ModelGroups.STABLE_DIFFUSION: + self.parameters.uncond_scale = None + + if not get_supported_params(self.model).noiseSchedule: + self.parameters.noise_schedule = None + self.parameters.cfg_rescale = None + + if (self.model in INPAINTING_MODEL_LIST) and (self.parameters.sampler in [Sampler.DDIM, Sampler.DDIM_V3]): + self.parameters.sampler = Sampler.K_EULER_ANCESTRAL + + if self.parameters.sampler in [ + Sampler.DDIM, + Sampler.PLMS, + Sampler.K_LMS, + Sampler.NAI_SMEA, + Sampler.NAI_SMEA_DYN, + Sampler.DDIM_V3, + Sampler.K_DPM_FAST + ]: + self.parameters.noise_schedule = None + + if self.parameters.sampler == Sampler.K_EULER_ANCESTRAL and self.parameters.noise_schedule != NoiseSchedule.NATIVE: + self.parameters.deliberate_euler_ancestral_bug = False + self.parameters.prefer_brownian = True + + if self.parameters.skip_cfg_above_sigma is not None: + scale_divisor, weight = (1, 3) if self.model == Model.DALLE_MINI else (8, 4) + dimensions_scaled = [ + math.floor(self.parameters.width) / scale_divisor, + math.floor(self.parameters.height) / scale_divisor + ] + # 初始化参考值 reference_value,用于标准化计算动态系数 + reference_value = 4 * math.floor(104) * math.floor(152) + # 计算动态系数 dynamic_factor 并用于调整 skip_cfg_above_sigma + dynamic_factor = ((weight * dimensions_scaled[0] * dimensions_scaled[1]) / reference_value) ** 0.5 + self.parameters.skip_cfg_above_sigma *= dynamic_factor + + if not get_supported_params(self.model).cfgDelay: + self.parameters.skip_cfg_above_sigma = None + + if not get_supported_params(self.model).smea: + self.parameters.sm = None + self.parameters.sm_dyn = None + + # == Noise Schedule == + if self.parameters.noise_schedule is None: + self.parameters.noise_schedule = get_default_noise_schedule(self.parameters.sampler) + supported_noise_schedule = get_supported_noise_schedule(self.parameters.sampler) + if supported_noise_schedule: + if self.parameters.noise_schedule not in supported_noise_schedule: + raise ValueError(f"Invalid noise_schedule, must be one of {supported_noise_schedule}") + else: + logger.warning(f"Inactive sampler {self.parameters.sampler} does not support noise_schedule.") + return self @property @@ -402,207 +549,300 @@ def calculate_cost(self, is_opus: bool = False): height=self.parameters.height, steps=self.parameters.steps, model=self.model, - image=self.parameters.image, + image=bool(self.parameters.image), n_samples=self.parameters.n_samples, account_tier=3 if is_opus else 1, strength=self.parameters.strength, sampler=self.parameters.sampler, - is_sm_enabled=self.parameters.sm, - is_sm_dynamic=self.parameters.sm_dyn, + is_sm_enabled=bool(self.parameters.sm), + is_sm_dynamic=bool(self.parameters.sm_dyn), is_account_active=True, ) except Exception as e: raise ValueError(f"Failed to calculate cost") from e - @classmethod - def build(cls, - prompt: str, - *, - model: Union[Model, str] = "nai-diffusion-3", - action: Union[Action, str] = 'generate', - negative_prompt: str = "", - ucPreset: UCPresetTypeAlias = UCPreset.TYPE0, - steps: int = 28, - seed: int = None, - scale: float = 5.0, - cfg_rescale: float = 0, - sampler: Union[Sampler, str] = None, - width: int = 832, - height: int = 1216, - qualityToggle: bool = None, - image: Union[str, bytes] = None, - decrisp_mode: bool = False, - variety_boost: bool = False, - noise: float = 0, - noise_schedule: Union[NoiseSchedule, str] = None, - reference_image_multiple: List[Union[str, bytes]] = None, - reference_strength_multiple: List[float] = None, - reference_information_extracted_multiple: List[float] = None, - reference_image: Union[str, bytes] = None, - reference_strength: float = None, - reference_information_extracted: float = None, - add_original_image: bool = True, - strength: float = None, - mask: Union[str, bytes] = None, - controlnet_model: Union[ControlNetModel, str] = None, - controlnet_condition: str = None, - sm: bool = False, - sm_dyn: bool = False, - uncond_scale: float = None, - **kwargs - ): + @staticmethod + def build_generate( + prompt: str, + *, + model: Union[Model, str], + qualitySuffix: bool = True, + negative_prompt: str = "", + ucPreset: UCPresetTypeAlias = UCPreset.TYPE0, + steps: int = 23, + seed: int = None, + sampler: Union[Sampler, str] = None, + width: int = 832, + height: int = 1216, + add_original_image: bool = True, + character_prompts: List[Character] = None, + reference_image_multiple: List[Union[str, bytes]] = None, + reference_strength_multiple: List[float] = None, + reference_information_extracted_multiple: List[float] = None, + qualityToggle: bool = False, + decrisp_mode: bool = False, + variety_boost: bool = False, + ): """ - The build function, more convenient to create a GenerateImageInfer instance. - 构建函数,更方便地创建一个GenerateImageInfer实例。 + Quickly construct a parameter class that meets the requirements. + + If you need to define more parameters, you should initialize the Param class yourself. + + :param reference_information_extracted_multiple: + :param reference_strength_multiple: + :param reference_image_multiple: + :param prompt: Given prompt. + :param model: Model for generation. + :param negative_prompt: The things you don't want to see in the image. + :param qualitySuffix: Add quality suffix to prompt + :param ucPreset: The negative prompt preset. + :param steps: The steps for generation. + :param seed: The seed for generation. + :param sampler: The sampler for generation. + :param width: The width of the image. + :param height: The height of the image. + :param add_original_image: Overlay Original Image. Prevents the existing image from changing, + but can introduce seams along the edge of the mask. + :param character_prompts: Character Prompts. + :param qualityToggle: Use modifiers to make your images look more hentai. :param decrisp_mode: Reduce artifacts caused by high prompt guidance values. - 减少由高提示引导值引起的伪影。 :param variety_boost: A new feature to improve the diversity of samples. - Variety Boost means your negative prompt will only be used after the body shape has been decided. - 一项新功能,用于提高样本的多样性。但是,这意味着您的负面提示只会在身体形状确定后使用。 - :param reference_information_extracted_multiple: The reference information extracted for Vibe mode. - Vibe模式的提取的参考信息。 - :param reference_image_multiple: The reference image for Vibe mode. - Vibe模式的参考图像。 - :param reference_strength_multiple: The strength of the reference image used in Vibe mode. - 在Vibe模式中使用的参考图像的强度。 - :param ucPreset: 0: Heavy, 1: Light, 2: Character - 0: 重量级, 1: 轻量级, 2: 角色 - :param qualityToggle: add the quality prompt or not. - 是否添加质量提示。 - :param prompt: input prompt for generation. - 生成的输入提示。 - :param model: select a model. - 选择一个模型。 - :param action: mode for image generation [generate, img2img, infill]. - 图像生成模式 [生成, 图像到图像, 填充]。 - :param negative_prompt: the content of negative prompt. - 负面提示的内容。 - :param seed: the seed for generate image. - 生成图像的种子。 - :param steps: the steps for generate image. - 生成图像的步骤。 - :param scale: the scale for generate image. - 生成图像的比例。 - :param cfg_rescale: prompt guidance rescale 0-1 lower is more creative. - 提示引导的重新缩放0-1,越低则越富有创造性。 - :param sampler: the sampler for generate image. - 生成图像的采样器。 - :param width: the width of the image. - 图像的宽度。 - :param height: the height of the image. - 图像的高度。 - :param image: the input image. - 输入图像。 - :param noise: the noise to be added in the image. - 要添加到图像中的噪声。 - :param noise_schedule: the noise schedule for generate image. - 生成图像的噪声计划。 - :param add_original_image: Overlay Original Image. Prevents the existing image from changing, only for IMG2IMG mode. - 叠加原始图像。防止现有图像发生更改,仅适用于IMG2IMG模式。 - :param strength: the strength of IMG2IMG mode. - IMG2IMG模式的强度。 - :param mask: the inpainting mask. - 纹理绘制掩码。 - :param controlnet_model: the model used for the control network. - 用于控制网络的模型。 - :param controlnet_condition: the condition used for the control network. - 用于控制网络的条件。 - :param sm: whether to use sm. - 是否使用sm。 - :param sm_dyn: whether to use dynamic sm. - 是否使用动态sm。 - :param uncond_scale: the strength of the unrelated content. - 无关内容的强度。 - :param kwargs: any additional parameters. - 其他任何参数。 - :return: self - 返回:自身 + :return: """ - assert isinstance(prompt, str) - _negative_prompt = negative_prompt - kwargs.update({ - "negative_prompt": _negative_prompt, - "seed": seed, - "steps": steps, - "scale": scale, - "cfg_rescale": cfg_rescale, - "sampler": sampler, - "width": width, - "height": height, - "qualityToggle": qualityToggle, - "ucPreset": ucPreset, - "add_original_image": add_original_image, - "mask": mask, - "controlnet_model": controlnet_model, - "controlnet_condition": controlnet_condition, - "sm_dyn": sm_dyn, - "sm": sm, - "uncond_scale": uncond_scale, - "noise_schedule": noise_schedule, - }) - - def _merge_param(v1, v2): - _list = [] - if isinstance(v1, list): - _list.extend(v1) - else: - if v1 is not None: - _list.append(v1) - if isinstance(v2, list): - _list.extend(v2) - else: - if v2 is not None: - _list.append(v2) - return _list - - if reference_image: - logger.warning( - "reference_image is deprecated, use reference_image_multiple instead." - ) - reference_image_multiple = _merge_param( - reference_image, reference_image_multiple - ) - if reference_strength: - logger.warning( - "reference_strength is deprecated, use reference_strength_multiple instead." - ) - reference_strength_multiple = _merge_param( - reference_strength, reference_strength_multiple - ) - if reference_information_extracted: - logger.warning( - "reference_information_extracted is deprecated, use reference_information_extracted_multiple instead." - ) - reference_information_extracted_multiple = _merge_param( - reference_information_extracted, reference_information_extracted_multiple - ) - kwargs.update( - { - "reference_image_multiple": reference_image_multiple, - "reference_strength_multiple": reference_strength_multiple, - "reference_information_extracted_multiple": reference_information_extracted_multiple, - } + if character_prompts is None: + character_prompts = [] + if qualitySuffix: + modifier = get_modifiers(model) + prompt += modifier.suffix + if seed is None: + seed = random.randint(0, 4294967295 - 7) + if reference_strength_multiple is None: + reference_image_multiple = [] + if reference_strength_multiple is None: + reference_strength_multiple = [] + if reference_information_extracted_multiple is None: + reference_information_extracted_multiple = [] + if len(reference_image_multiple) != len(reference_strength_multiple) != len( + reference_information_extracted_multiple): + raise ValueError("All three reference_* must be of equal length.") + params = Params( + width=width, + height=height, + sampler=sampler, + characterPrompts=character_prompts, + add_original_image=add_original_image, + steps=steps, + seed=seed, + negative_prompt=negative_prompt, + ucPreset=ucPreset, + qualityToggle=qualityToggle, + dynamic_thresholding=decrisp_mode, + skip_cfg_above_sigma=19 if variety_boost else None, + reference_image_multiple=reference_image_multiple, + reference_information_extracted_multiple=reference_information_extracted_multiple, + reference_strength_multiple=reference_strength_multiple, + ) + return GenerateImageInfer( + input=prompt, + model=model, + action=Action.GENERATE, + parameters=params + ) + + @staticmethod + def build_img2img( + prompt: str, + *, + image: Union[bytes, str], + strength: float = 0.7, + seed: int = None, + extra_noise_seed: int = None, + model: Union[Model, str] = Model.NAI_DIFFUSION_3, + qualitySuffix: bool = True, + negative_prompt: str = "", + ucPreset: UCPresetTypeAlias = UCPreset.TYPE0, + steps: int = 23, + sampler: Union[Sampler, str] = None, + width: int = 832, + height: int = 1216, + add_original_image: bool = True, + character_prompts: List[Character] = None, + reference_image_multiple: List[Union[str, bytes]] = None, + reference_strength_multiple: List[float] = None, + reference_information_extracted_multiple: List[float] = None, + qualityToggle: bool = False, + decrisp_mode: bool = False, + variety_boost: bool = False, + ): + """ + Quickly construct a parameter class that meets the requirements. + + If you need to define more parameters, you should initialize the Param class yourself. + + :param strength: + :param image: + :param extra_noise_seed: Get extra_noise_seed + :param reference_information_extracted_multiple: + :param reference_strength_multiple: + :param reference_image_multiple: + :param prompt: Given prompt. + :param model: Model for generation. + :param negative_prompt: The things you don't want to see in the image. + :param qualitySuffix: Add quality suffix to prompt + :param ucPreset: The negative prompt preset. + :param steps: The steps for generation. + :param seed: The seed for generation. + :param sampler: The sampler for generation. + :param width: The width of the image. + :param height: The height of the image. + :param add_original_image: Overlay Original Image. Prevents the existing image from changing, + but can introduce seams along the edge of the mask. + :param character_prompts: Character Prompts. + :param qualityToggle: Use modifiers to make your images look more hentai. + :param decrisp_mode: Reduce artifacts caused by high prompt guidance values. + :param variety_boost: A new feature to improve the diversity of samples. + :return: + """ + if character_prompts is None: + character_prompts = [] + if qualitySuffix: + modifier = get_modifiers(model) + prompt += modifier.suffix + if seed is None: + seed = random.randint(0, 4294967295 - 7) + if extra_noise_seed is None: + extra_noise_seed = random.randint(0, 4294967295 - 7) + if reference_strength_multiple is None: + reference_image_multiple = [] + if reference_strength_multiple is None: + reference_strength_multiple = [] + if reference_information_extracted_multiple is None: + reference_information_extracted_multiple = [] + if len(reference_image_multiple) != len(reference_strength_multiple) != len( + reference_information_extracted_multiple): + raise ValueError("All three reference_* must be of equal length.") + params = Params( + image=image, + strength=strength, + width=width, + height=height, + sampler=sampler, + characterPrompts=character_prompts, + add_original_image=add_original_image, + steps=steps, + seed=seed, + extra_noise_seed=extra_noise_seed, + negative_prompt=negative_prompt, + ucPreset=ucPreset, + qualityToggle=qualityToggle, + dynamic_thresholding=decrisp_mode, + skip_cfg_above_sigma=19 if variety_boost else None, + reference_image_multiple=reference_image_multiple, + reference_information_extracted_multiple=reference_information_extracted_multiple, + reference_strength_multiple=reference_strength_multiple, + ) + return GenerateImageInfer( + input=prompt, + model=model, + action=Action.IMG2IMG, + parameters=params ) - kwargs.update( - { - "image": image, - "strength": strength, - "noise": noise, - } + + @staticmethod + def build_infill( + prompt: str, + *, + image: Union[bytes, str], + mask: Union[bytes, str], + strength: float = 0.7, + model: Union[Model, str] = Model.NAI_DIFFUSION_3, + qualitySuffix: bool = True, + negative_prompt: str = "", + ucPreset: UCPresetTypeAlias = UCPreset.TYPE0, + steps: int = 23, + seed: int = None, + sampler: Union[Sampler, str] = None, + width: int = 832, + height: int = 1216, + add_original_image: bool = True, + character_prompts: List[Character] = None, + reference_image_multiple: List[Union[str, bytes]] = None, + reference_strength_multiple: List[float] = None, + reference_information_extracted_multiple: List[float] = None, + qualityToggle: bool = False, + decrisp_mode: bool = False, + variety_boost: bool = False, + ): + """ + Quickly construct a parameter class that meets the requirements. + + If you need to define more parameters, you should initialize the Param class yourself. + + :param strength: The strength + :param mask: Given mask + :param image: Given image + :param reference_information_extracted_multiple: + :param reference_strength_multiple: + :param reference_image_multiple: + :param prompt: Given prompt. + :param model: Model for generation. + :param negative_prompt: The things you don't want to see in the image. + :param qualitySuffix: Add quality suffix to prompt + :param ucPreset: The negative prompt preset. + :param steps: The steps for generation. + :param seed: The seed for generation. + :param sampler: The sampler for generation. + :param width: The width of the image. + :param height: The height of the image. + :param add_original_image: Overlay Original Image. Prevents the existing image from changing, + but can introduce seams along the edge of the mask. + :param character_prompts: Character Prompts. + :param qualityToggle: Use modifiers to make your images look more hentai. + :param decrisp_mode: Reduce artifacts caused by high prompt guidance values. + :param variety_boost: A new feature to improve the diversity of samples. + :return: + """ + if character_prompts is None: + character_prompts = [] + if qualitySuffix: + modifier = get_modifiers(model) + prompt += modifier.suffix + if seed is None: + seed = random.randint(0, 4294967295 - 7) + if reference_strength_multiple is None: + reference_image_multiple = [] + if reference_strength_multiple is None: + reference_strength_multiple = [] + if reference_information_extracted_multiple is None: + reference_information_extracted_multiple = [] + if len(reference_image_multiple) != len(reference_strength_multiple) != len( + reference_information_extracted_multiple): + raise ValueError("All three reference_* must be of equal length.") + params = Params( + width=width, + height=height, + sampler=sampler, + image=image, + mask=mask, + strength=strength, + characterPrompts=character_prompts, + add_original_image=add_original_image, + steps=steps, + seed=seed, + negative_prompt=negative_prompt, + ucPreset=ucPreset, + qualityToggle=qualityToggle, + dynamic_thresholding=decrisp_mode, + skip_cfg_above_sigma=19 if variety_boost else None, + reference_image_multiple=reference_image_multiple, + reference_information_extracted_multiple=reference_information_extracted_multiple, + reference_strength_multiple=reference_strength_multiple, ) - if decrisp_mode: - kwargs.update({"dynamic_thresholding": True}) - if variety_boost: - kwargs.update({"skip_cfg_above_sigma": 19}) - # 清理空值 - param = {k: v for k, v in kwargs.items() if v is not None} - _build_prop = Params(**param) - assert _build_prop, "Params validate failed" - return cls( + return GenerateImageInfer( input=prompt, model=model, - action=action, - parameters=_build_prop + action=Action.INFILL, + parameters=params ) async def necessary_headers(self, request_data) -> dict: @@ -654,13 +894,14 @@ async def request(self, sess.headers.update(override_headers) try: _log_data = deepcopy(request_data) - _log_data.get("parameters", {}).update({ - "image": "base64 data" if self.parameters.image else None, - "mask": "base64 data" if self.parameters.mask else None, - "reference_image_multiple": ["base64 data"] * len( - self.parameters.reference_image_multiple) if self.parameters.reference_image_multiple else None, - }) - logger.debug(f"Request Data: {_log_data}") + if self.parameters.image: + _log_data["parameters"]["image"] = "base64 data" + if self.parameters.mask: + _log_data["parameters"]["mask"] = "base64 data" + if self.parameters.reference_image_multiple: + _log_data["parameters"]["reference_image_multiple"] = ["base64 data"] * len( + self.parameters.reference_image_multiple) + logger.debug(f"Request Data: {json.dumps(_log_data, indent=2)}") del _log_data except Exception as e: logger.warning(f"Error when print log data: {e}") diff --git a/src/novelai_python/sdk/ai/generate_image/schema.py b/src/novelai_python/sdk/ai/generate_image/schema.py new file mode 100644 index 0000000..db8a7d6 --- /dev/null +++ b/src/novelai_python/sdk/ai/generate_image/schema.py @@ -0,0 +1,129 @@ +from enum import Enum +from typing import List, Union + +from pydantic import BaseModel, Field + + +class CharacterPosition(BaseModel): + x: Union[float, int] = Field(0, le=0.9, ge=0, description="X") + """ + 0 Auto + 0.1 0.3 0.5 0.7 0.9 + """ + y: Union[float, int] = Field(0, le=0.9, ge=0, description="Y") + """ + 0 Auto + 0.1 0.3 0.5 0.7 0.9 + """ + + +class PositionMap(Enum): + AUTO = CharacterPosition(x=0, y=0) + A1 = CharacterPosition(x=0.1, y=0.1) + A2 = CharacterPosition(x=0.1, y=0.3) + A3 = CharacterPosition(x=0.1, y=0.5) + A4 = CharacterPosition(x=0.1, y=0.7) + A5 = CharacterPosition(x=0.1, y=0.9) + B1 = CharacterPosition(x=0.3, y=0.1) + B2 = CharacterPosition(x=0.3, y=0.3) + B3 = CharacterPosition(x=0.3, y=0.5) + B4 = CharacterPosition(x=0.3, y=0.7) + B5 = CharacterPosition(x=0.3, y=0.9) + C1 = CharacterPosition(x=0.5, y=0.1) + C2 = CharacterPosition(x=0.5, y=0.3) + C3 = CharacterPosition(x=0.5, y=0.5) + C4 = CharacterPosition(x=0.5, y=0.7) + C5 = CharacterPosition(x=0.5, y=0.9) + D1 = CharacterPosition(x=0.7, y=0.1) + D2 = CharacterPosition(x=0.7, y=0.3) + D3 = CharacterPosition(x=0.7, y=0.5) + D4 = CharacterPosition(x=0.7, y=0.7) + D5 = CharacterPosition(x=0.7, y=0.9) + E1 = CharacterPosition(x=0.9, y=0.1) + E2 = CharacterPosition(x=0.9, y=0.3) + E3 = CharacterPosition(x=0.9, y=0.5) + E4 = CharacterPosition(x=0.9, y=0.7) + E5 = CharacterPosition(x=0.9, y=0.9) + + +class Character(BaseModel): + prompt: str = Field(None, description="Prompt") + uc: str = Field("", description="Negative Prompt") + center: Union[PositionMap, CharacterPosition] = Field(PositionMap.AUTO, description="Center") + """Center""" + + @classmethod + def build(cls, + prompt: str, + uc: str = '', + center: Union[PositionMap, CharacterPosition] = PositionMap.AUTO + ) -> "Character": + """ + Build CharacterPrompt from prompt + :param prompt: The main prompt + :param uc: The negative prompt + :param center: The center + :return: + """ + return cls(prompt=prompt, uc=uc, center=center) + + +class CharCaption(BaseModel): + char_caption: str = Field('', description="Character Caption") + centers: List[Union[PositionMap, CharacterPosition]] = Field([PositionMap.AUTO], description="Center") + """Center""" + + +class Caption(BaseModel): + base_caption: str = Field("", description="Main Prompt") + """Main Prompt""" + char_captions: List[CharCaption] = Field([], description="Character Captions") + """Character Captions""" + + +class V4Prompt(BaseModel): + caption: Caption = Field(default_factory=Caption, description="Caption") + use_coords: bool = Field(True, description="Use Coordinates") + use_order: bool = Field(True, description="Use Order") + + @classmethod + def build_from_character_prompts(cls, + prompt: str, + character_prompts: List[Character], + use_coords: bool = True, + use_order: bool = True + ) -> "V4Prompt": + """ + Build V4Prompt from character prompts + :param prompt: The main prompt + :param character_prompts: List of character prompts + :param use_coords: Whether to use coordinates + :param use_order: Whether to use order + :return: + """ + caption = Caption(base_caption=prompt) + for character_prompt in character_prompts: + char_caption = CharCaption(char_caption=character_prompt.prompt, centers=[character_prompt.center]) + caption.char_captions.append(char_caption) + return cls(caption=caption, use_coords=use_coords, use_order=use_order) + + +class V4NegativePrompt(BaseModel): + caption: Caption = Field(default_factory=Caption, description="Caption") + + @classmethod + def build_from_character_prompts(cls, + negative_prompt: str, + character_prompts: List[Character] + ) -> "V4NegativePrompt": + """ + Build V4NegativePrompt from character prompts + :param negative_prompt: The main prompt + :param character_prompts: List of character prompts + :return: + """ + caption = Caption(base_caption=negative_prompt) + for character_prompt in character_prompts: + char_caption = CharCaption(char_caption=character_prompt.uc, centers=[character_prompt.center]) + caption.char_captions.append(char_caption) + return cls(caption=caption) From abc88bb16aeb286fa4603508edcfb89b487db94b Mon Sep 17 00:00:00 2001 From: sudoskys Date: Sat, 21 Dec 2024 23:18:21 +0800 Subject: [PATCH 2/8] update sample --- record/ai/generate_image/image2image.json | 1 - record/ai/generate_image/image2image_v3.json | 22 +++ .../generate_image/image2image_v3/image.png | Bin 0 -> 5058 bytes .../generate_image/image2image_v3/schema.json | 131 ++++++++++++++++++ record/ai/generate_image/inpaint.json | 1 - record/ai/generate_image/inpaint_v3.json | 22 +++ record/ai/generate_image/inpaint_v3/image.png | Bin 0 -> 5058 bytes record/ai/generate_image/inpaint_v3/mask.png | Bin 0 -> 3100 bytes .../ai/generate_image/inpaint_v3/schema.json | 65 +++++++++ record/ai/generate_image/text2image.json | 9 +- .../ai/generate_image/text2image/schema.json | 30 ++-- record/ai/generate_image/text2image_v3.json | 22 +++ .../generate_image/text2image_v3/schema.json | 127 +++++++++++++++++ 13 files changed, 412 insertions(+), 18 deletions(-) create mode 100644 record/ai/generate_image/image2image_v3.json create mode 100644 record/ai/generate_image/image2image_v3/image.png create mode 100644 record/ai/generate_image/image2image_v3/schema.json create mode 100644 record/ai/generate_image/inpaint_v3.json create mode 100644 record/ai/generate_image/inpaint_v3/image.png create mode 100644 record/ai/generate_image/inpaint_v3/mask.png create mode 100644 record/ai/generate_image/inpaint_v3/schema.json create mode 100644 record/ai/generate_image/text2image_v3.json create mode 100644 record/ai/generate_image/text2image_v3/schema.json diff --git a/record/ai/generate_image/image2image.json b/record/ai/generate_image/image2image.json index 3d44461..f6e8028 100644 --- a/record/ai/generate_image/image2image.json +++ b/record/ai/generate_image/image2image.json @@ -3,7 +3,6 @@ "headers": { "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:123.0) Gecko/20100101 Firefox/123.0", "Accept": "*/*", - "Content-Type": "application/json", "Authorization": "Secret", "Sec-Fetch-Dest": "empty", diff --git a/record/ai/generate_image/image2image_v3.json b/record/ai/generate_image/image2image_v3.json new file mode 100644 index 0000000..28e7adb --- /dev/null +++ b/record/ai/generate_image/image2image_v3.json @@ -0,0 +1,22 @@ +{ + "credentials": "include", + "headers": { + "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:133.0) Gecko/20100101 Firefox/133.0", + "Accept": "*/*", + "Accept-Language": "zh-CN,zh;q=0.8,zh-TW;q=0.7,zh-HK;q=0.5,en-US;q=0.3,en;q=0.2", + "Content-Type": "application/json", + "Authorization": "Secret", + "x-correlation-id": "555", + "x-initiated-at": "2024-12-05T05:53:13.778Z", + "Sec-Fetch-Dest": "empty", + "Sec-Fetch-Mode": "cors", + "Sec-Fetch-Site": "same-site", + "Priority": "u=4", + "Pragma": "no-cache", + "Cache-Control": "no-cache" + }, + "referrer": "https://novelai.net/", + "body": "{\"input\":\"2boys, 1girl, photorealistic, full body, rating:general, amazing quality, very aesthetic, absurdres\",\"model\":\"nai-diffusion-4-curated-preview\",\"action\":\"img2img\",\"parameters\":{\"params_version\":3,\"width\":640,\"height\":640,\"scale\":6,\"sampler\":\"k_euler_ancestral\",\"steps\":23,\"n_samples\":1,\"strength\":0.7,\"noise\":0.2,\"ucPreset\":0,\"qualityToggle\":true,\"dynamic_thresholding\":false,\"controlnet_strength\":1,\"legacy\":false,\"add_original_image\":true,\"cfg_rescale\":0,\"noise_schedule\":\"karras\",\"legacy_v3_extend\":false,\"use_coords\":true,\"seed\":3634432471,\"image\":\"iVBORw0KGgoAAAANSUhEUgAAAoAAAAKACAYAAAAMzckjAAAgAElEQVR4Xu3dS4zkZdUG8HcGUAwjSBSJQQXjHVEDJt4FJCaaURNdMbNxowsXmmFhZMuamAgTTDSZlRuHlQvFaDRIuCiKGdQABlAQdQQSUIIXhnD7vn996cmMfML0nKqueur8OqkMxu5T5/097+JJdXf1tuf+92P4IECAAAECBAgQaCOwTQFsk7WDEiBAgAABAgRmAgqgi0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HEJECBAgAABAgqgO0CAAAECBAgQaCagADYL3HGXK3DttdeOb3zjG+NXv/rVOHTo0HjuueeOWuiEE04YO3bsGKeccso4//zzx2c+85lx7rnnzh6veMUrlru8ZydAgACBtRFQANcmSgdZZYFf//rX4/Of//w4cODAca85FcBPfvKT41Of+tTYtWvXcc/xhQQIECBAQAF0BwgsWODKK68cl19++Vyf5fTTTx9f+MIXxjTbBwECBAgQ2KyAArhZMZ9PYBMCiyh/Rz799KrgFVdcMfbs2bOJrXwqAQIECHQXUAC73wDnX5jA9G3f6ef4tuLjxBNPnD3Xt771rS17zq04l+cgQIAAgcUIKICLcTWVwHjPe95T+pm/4yWcXhW85JJLxoUXXjh7bFUJPd59fR0BAgQIbL2AArj15p6xgcD+/fvH7t27V+Kkr3rVqw6XQYVwJSKxBAECBJYuoAAuPQILrKPARz7ykXHzzTev5NGmt5p55StfOT7xiU+Myy67zCuEK5mSpQgQILBYAQVwsb6mNxU47bTTxuOPPx5xet8yjojJkgQIEJirgAI4V07DCPyfwPQq27PPPhvJ4VvGkbFZmgABApsSUAA3xeWTCRybwLZt247tEwM+SyEMCMmKBAgQ2KSAArhJMJ9O4FgEkl8BfLHzbd++fUzf4r744otnv+jy7ne/e7zlLW95sS/z/xMgQIDACgkogCsUhlXWRyDpZwDnof7yl798VgT/8/HSl750HuPNIECAAIE5CyiAcwY1jsAkML3dyk033dQe47zzznteKTzzzDPbuwAgQIDAsgUUwGUn4PnXUuDaa68du3btWsuzVQ81fXv8jDPOGO985zvHzp07Z98+nh5vetObqqN9PQECBAgco4ACeIxQPo3AZgWW9ZdANrvnqnz+SSedNN785jcfLoQbxXD616uGq5KSPQgQWBcBBXBdknSOlRPYyr8FvHKHn/NCp59++lHF8MiieMopp8z52YwjQIDA+gsogOufsRMuUeDKK68cl19++RI3WP+nfvWrXz2mXzaZ/vrKF7/4xfH+979/TK8m+iBAgACB/y6gALodBBYsoAQuGPg/xk9vUzOVwA984AOH/z3rrLO2dgnPRoAAgRUXUABXPCDrrYfA9O3gPXv2jBtvvHE9DhR2iukXTI4shRdccEHYCaxLgACB+QoogPP1NI3ACwrs379/fP/73x+33XbbePDBB2ef+5rXvGa8973vHR/96EfH2972tnHXXXeNr3/96+Puu+8ezzzzDNEFCEzvW3jkK4RTOZz+JrIPAgQIdBFQALsk7ZyRAldfffW44oorxmOPPRa5f9LS05tYH1kK/XWTpPTsSoDAZgUUwM2K+XwCSxD46le/Ovbt2zf+/ve/L+HZez7liSeeOKa/g/yxj31sfOlLXxrve9/7ekI4NQECaymgAK5lrA61rgLTt5D37t07fvnLX/r28BaH/LKXvWz2m8Yf+tCHDj9OPvnkLd7C0xEgQGA+AgrgfBxNIbDlArfffvvsl0o2Ho888siW79D9CT/4wQ8eVQinVwx9ECBAIEFAAUxIyY4EjkHgyEJ4/fXX+7nBYzCb96e8613vmhXCD3/4w7N/zz777Hk/hXkECBCYi4ACOBdGQwisnsBUCK+66qrxwx/+cDz66KO+ZbyEiN74xjce9QrhO97xjiVs4SkJECDwfAEF0K0g0ETAt4yXH/QJJ5wwe1XwoosuGl/5ylfGueeeu/ylbECAQEsBBbBl7A5NYAyFcPm3YHoPyI9//OOz94CcHq973euWv5QNCBBoIaAAtojZIQm8uICfIXxxo0V/xnnnnXe4DE6F0JtTL1rcfAJ9BRTAvtk7OYEXFNj4GcJbbrllHDx4cBw6dIjYFgtMb0y98ergxRdfPKb3JvRBgACBeQgogPNQNINAA4GHH354/OY3vznqcccddzQ4+Woc8aSTTjqqDE5/vs4HAQIEjldAATxeOV9HgMB48sknn1cKp5L4j3/8g86CBaZfKDn11FPHpz/96XHZZZeN888/f8HPaDwBAuskoACuU5rOQmBFBO65555ZMfzOd74z+6sl//73v/0ZuwVnM/284CWXXDIuvPDC2UMhXDC48QTCBRTA8ACtTyBF4F//+teYiuH0uPfeew//9/S//Y3j+ac4/VWSjTKoEM7f10QC6QIKYHqC9iewBgLTzxdulMMj/52K4lNPPbUGJ1z+ERTC5WdgAwKrJKAArlIadiFA4HkCv//97w+Xwx/84Aez9y/829/+Np599llaBQGFsIDnSwmsgYACuAYhOgKBjgLTK4U///nPx6233jr7d/qZQx/HL7B9+/bZL5VMf8P4s5/97Hj7298++0sl3ovw+E19JYFVFlAAVzkduxEgcMwCjz322OEyuFEK/TbyMfP91098/etfPyuC02OjFCqGdVcTCCxbQAFcdgKenwCBhQkcOHDgqFI4fTvZx3wEplcLp8f0foSf+9znxgUXXDDOOuus+Qw3hQCBhQsogAsn9gQECKyKwPQXTY78tvH0SqGfJZxfOq997WtnRfDIh1I4P1+TCMxTQAGcp6ZZBAhECUy/YTyVwG9+85vjxz/+8eyXS5555pmoM6z6stu2bRvTL5y89a1vHRdddNE455xzZo+zzz579u/0F058ECCw9QIK4Nabe0YCBFZY4M477xzT3z/eePzhD39Y4W17rLZRInft2jX27t3b49BOSWDBAgrggoGNJ0AgW+CBBx6YlcGbb7559u9vf/vb7AOFb79jx46xb9++cemll4afxPoEliugAC7X37MTIBAm8Mgjjxz1CuHPfvazsBOsx7o7d+4c11133XocxikILEFAAVwCuqckQGB9BA4dOnRUIbzpppvGE088sT4HXOGTKIErHI7VVl5AAVz5iCxIgECawC9+8YtxzTXXjO9973vjn//8p18sWWCA+/fv9+3gBfoavb4CCuD6ZutkBAisiMD0m8Y33HDD+OlPfzp7+PvG8wvmtNNOG9ObgPsgQGBzAgrg5rx8NgECBEoCTz/99FFlcHpfQh81gT179oyrrrqqNsRXE2gmoAA2C9xxCRBYLYHp1auNVwanf++4447VWjBgmze84Q3jvvvuC9jUigRWR0ABXJ0sbEKAAIHx5z//+XAh/NGPfjQefPBBKi8i8JKXvGQ8+eSTnAgQ2ISAArgJLJ9KgACBrRa46667xte+9rXxk5/8ZPz1r3/1CyX/TwDTG0X7k35bfTM9X7qAApieoP0JEGglcPvtt48bb7zx8GN6X8LuHwpg9xvg/McjoAAej5qvIUCAwIoIKIRj+BbwilxGa0QJKIBRcVmWAAECLyzQsRCec8454/7773c1CBDYhIACuAksn0qAAIE0gSML4fXXX7+W75n35S9/eezduzctGvsSWKqAArhUfk9OgACBrRWYCuH0nnm33HLLePTRR+MLoTeC3tr749nWR0ABXJ8snYQAAQKbFpjeh3D6TePp8bvf/e7wf//pT3/a9KxlfIE/BbcMdc+5DgIK4Dqk6AwECBCYs8BGMZxK4Xe/+90xvXL40EMPrdTbrezcuXNcd911cz65cQR6CCiAPXJ2SgIECMxF4ODBg+PAgQNHPf7yl7/MZfZmhih/m9HyuQSeL6AAuhUECBAgUBLYKIXf/va3x6233jqbtahSuGPHjrFv375x6aWXlnb2xQS6CyiA3W+A8xMgQGABAk8//fT44x//OHs88MADs39vuOGGcffdd4/HH398bN++fTzxxBPH9MzTGz2fccYZY/fu3bNfYPFBgEBdQAGsG5pAgAABAgQIEIgSUACj4rIsAQIECBAgQKAuoADWDU0gQIAAAQIECEQJKIBRcVmWAAECBAgQIFAXUADrhiYQIECAAAECBKIEFMCouCxLgAABAgQIEKgLKIB1QxMIECBAgAABAlECCmBUXJYlQIAAAQIECNQFFMC6oQkECBAgQIAAgSgBBTAqLssSIECAAAECBOoCCmDd0AQCBAgQIECAQJSAAhgVl2UJECBAgAABAnUBBbBuaAIBAgQIECBAIEpAAYyKy7IECBAgQIAAgbqAAlg3NIEAAQIECBAgECWgAEbFZVkCBAgQIECAQF1AAawbmkCAAAECBAgQiBJQAKPisiwBAgQIECBAoC6gANYNTSBAgAABAgQIRAkogFFxWZYAAQIECBAgUBdQAOuGJhAgQIAAAQIEogQUwKi4LEuAAAECBAgQqAsogHVDEwgQIECAAAECUQIKYFRcliVAgAABAgQI1AUUwLqhCQQIECBAgACBKAEFMCouyxIgQIAAAQIE6gIKYN3QBAIECBAgQIBAlIACGBWXZQkQIECAAAECdQEFsG5oAgECBAgQIEAgSkABjIrLsgQIECBAgACBuoACWDc0gQABAgQIECAQJaAARsVlWQIECBAgQIBAXUABrBuaQIAAAQIECBCIElAAo+KyLAECBAgQIECgLqAA1g1NIECAAAECBAhECSiAUXFZlgABAgQIECBQF1AA64YmECBAgAABAgSiBBTAqLgsS4AAAQIECBCoCyiAdUMTCBAgQIAAAQJRAgpgVFyWJUCAAAECBAjUBRTAuqEJBAgQIECAAIEoAQUwKi7LEiBAgAABAgTqAgpg3dAEAgQIECBAgECUgAIYFZdlCRAgQIAAAQJ1AQWwbmgCAQIECBAgQCBKQAGMisuyBAgQIECAAIG6gAJYNzSBAAECBAgQIBAloABGxWVZAgQIECBAgEBdQAGsG5pAgAABAgQIEIgSUACj4rIsAQIECBAgQKAuoADWDU0gQIAAAQIECEQJKIBRcVmWAAECBAgQIFAXUADrhiYQIECAAAECBKIEFMCouCxLgAABAgQIEKgLKIB1QxMIECBAgAABAlECCmBUXJYlQIAAAQIECNQFFMC6oQkECBAgQIAAgSgBBTAqLssSIECAAAECBOoCCmDd0AQCBAgQIECAQJSAAhgVl2UJECBAgAABAnUBBbBuaAIBAgQIECBAIEpAAYyKy7IECBAgQIAAgbqAAlg3NIEAAQIECBAgECWgAEbFZVkCBAgQIECAQF1AAawbmkCAAAECBAgQiBJQAKPisiwBAgQIECBAoC6gANYNTSBAgAABAgQIRAkogFFxWZYAAQIECBAgUBdQAOuGJhAgQIAAAQIEogQUwKi4LEuAAAECBAgQqAsogHVDEwgQIECAAAECUQIKYFRcliVAgAABAgQI1AUUwLqhCQQIECBAgACBKAEFMCouyxIgQIAAAQIE6gIKYN3QBAIECBAgQIBAlIACGBWXZQkQIECAAAECdQEFsG5oAgECBAgQIEAgSkABjIrLsgQIECBAgACBuoACWDc0gQABAgQIECAQJaAARsVlWQIECBAgQIBAXUABrBuaQIAAAQIECBCIElAAo+KyLAECBAgQIECgLqAA1g1NIECAAAECBAhECSiAUXFZlgABAgQIECBQF1AA64YmECBAgAABAgSiBBTAqLgsS4AAAQIECBCoCyiAdUMTCBAgQIAAAQJRAgpgVFyWJUCAAAECBAjUBRTAuqEJBAgQIECAAIEoAQUwKi7LEiBAgAABAgTqAgpg3dAEAgQIECBAgECUgAIYFZdlCRAgQIAAAQJ1AQWwbmgCAQIECBAgQCBKQAGMisuyBAgQIECAAIG6gAJYNzSBAAECBAgQIBAloABGxWVZAgQIECBAgEBdQAGsG5pAgAABAgQIEIgSUACj4rIsAQIECBAgQKAuoADWDU0gQIAAAQIECEQJKIBRcVmWAAECBAgQIFAXUADrhiYQIECAAAECBKIEFMCouCxLgAABAgQIEKgLKIB1QxMIECBAgAABAlECCmBUXJYlQIAAAQIECNQFFMC6oQkECBAgQIAAgSgBBTAqLssSIECAAAECBOoCCmDd0AQCBAgQIECAQJSAAhgVl2UJECBAgAABAnUBBbBuaAIBAgQIECBAIEpAAYyKy7IECBAgQIAAgbqAAlg3NIEAAQIECBAgECWgAEbFZVkCBAgQIECAQF1AAawbmkCAAAECBAgQiBJQAKPisiwBAgQIECBAoC6gANYNTSBAgAABAgQIRAkogFFxWZYAAQIECBAgUBdQAOuGJhAgQIAAAQIEogQUwKi4LEuAAAECBAgQqAsogHVDEwgQIECAAAECUQIKYFRcliVAgAABAgQI1AUUwLqhCQQIECBAgACBKAEFMCouyxIgQIAAAQIE6gIKYN3QBAIECBAgQIBAlIACGBWXZQkQIECAAAECdQEFsG5oAgECBAgQIEAgSkABjIrLsgQIECBAgACBuoACWDc0gQABAgQIECAQJaAARsVlWQIECBAgQIBAXUABrBuaQIAAAQIECBCIElAAo+KyLAECBAgQIECgLqAA1g1NIECAAAECBAhECSiAUXFZlgABAgQIECBQF1AA64YmECBAgAABAgSiBBTAqLgsS4AAAQIECBCoCyiAdUMTCBAgQIAAAQJRAgpgVFyWJUCAAAECBAjUBRTAuqEJBAgQIECAAIEoAQUwKi7LEiBAgAABAgTqAgpg3dAEAgQIECBAgECUgAIYFZdlCRAgQIAAAQJ1AQWwbmgCAQIECBAgQCBKQAGMisuyBAgQIECAAIG6gAJYNzSBAAECBAgQIBAloABGxWVZAgQIECBAgEBdQAGsG5pAgAABAgQIEIgSUACj4rIsAQIECBAgQKAuoADWDU0gQIAAAQIECEQJKIBRcVmWAAECBAgQIFAXUADrhiYQIECAAAECBKIEFMCouCxLgAABAgQIEKgLKIB1QxMIECBAgAABAlECCmBUXJYlQIAAAQIECNQFFMC6oQkECBAgQIAAgSgBBTAqLssSIECAAAECBOoCCmDd0AQCBAgQIECAQJSAAhgVl2UJECBAgAABAnUBBbBuaAIBAgQIECBAIEpAAYyKy7IECBAgQIAAgbqAAlg3NIEAAQIECBAgECWgAEbFZVkCBAgQIECAQF1AAawbmkCAAAECBAgQiBJQAKPisiwBAgQIECBAoC6gANYNTSBAgAABAgQIRAkogFFxWZYAAQIECBAgUBdQAOuGJhAgQIAAAQIEogQUwKi4LEuAAAECBAgQqAsogHVDEwgQIECAAAECUQIKYFRcliVAgAABAgQI1AUUwLqhCQQIECBAgACBKAEFMCouyxIgQIAAAQIE6gIKYN3QBAIECBAgQIBAlIACGBWXZQkQIECAAAECdQEFsG5oAgECBAgQIEAgSkABjIrLsgQIEKIFXp8AAAwhSURBVCBAgACBuoACWDc0gQABAgQIECAQJaAARsVlWQIECBAgQIBAXUABrBuaQIAAAQIECBCIElAAo+KyLAECBAgQIECgLqAA1g1NIECAAAECBAhECSiAUXFZlgABAgQIECBQF1AA64YmECBAgAABAgSiBBTAqLgsS4AAAQIECBCoCyiAdUMTCBAgQIAAAQJRAgpgVFyWJUCAAAECBAjUBRTAuqEJBAgQIECAAIEoAQUwKi7LEiBAgAABAgTqAgpg3dAEAgQIECBAgECUgAIYFZdlCRAgQIAAAQJ1AQWwbmgCAQIECBAgQCBKQAGMisuyBAgQIECAAIG6gAJYNzSBAAECBAgQIBAloABGxWVZAgQIECBAgEBdQAGsG5pAgAABAgQIEIgSUACj4rIsAQIECBAgQKAuoADWDU0gQIAAAQIECEQJKIBRcVmWAAECBAgQIFAXUADrhiYQIECAAAECBKIEFMCouCxLgAABAgQIEKgLKIB1QxMIECBAgAABAlECCmBUXJYlQIAAAQIECNQFFMC6oQkECBAgQIAAgSgBBTAqLssSIECAAAECBOoCCmDd0AQCBAgQIECAQJSAAhgVl2UJECBAgAABAnUBBbBuaAIBAgQIECBAIEpAAYyKy7IECBAgQIAAgbqAAlg3NIEAAQIECBAgECWgAEbFZVkCBAgQIECAQF1AAawbmkCAAAECBAgQiBJQAKPisiwBAgQIECBAoC6gANYNTSBAgAABAgQIRAkogFFxWZYAAQIECBAgUBdQAOuGJhAgQIAAAQIEogQUwKi4LEuAAAECBAgQqAsogHVDEwgQIECAAAECUQIKYFRcliVAgAABAgQI1AUUwLqhCQQIECBAgACBKAEFMCouyxIgQIAAAQIE6gIKYN3QBAIECBAgQIBAlIACGBWXZQkQIECAAAECdQEFsG5oAgECBAgQIEAgSkABjIrLsgQIECBAgACBuoACWDc0gQABAgQIECAQJaAARsVlWQIECBAgQIBAXUABrBuaQIAAAQIECBCIElAAo+KyLAECBAgQIECgLqAA1g1NIECAAAECBAhECSiAUXFZlgABAgQIECBQF1AA64YmECBAgAABAgSiBBTAqLgsS4AAAQIECBCoCyiAdUMTCBAgQIAAAQJRAgpgVFyWJUCAAAECBAjUBRTAuqEJBAgQIECAAIEoAQUwKi7LEiBAgAABAgTqAgpg3dAEAgQIECBAgECUgAIYFZdlCRAgQIAAAQJ1AQWwbmgCAQIECBAgQCBKQAGMisuyBAgQIECAAIG6gAJYNzSBAAECBAgQIBAloABGxWVZAgQIECBAgEBdQAGsG5pAgAABAgQIEIgSUACj4rIsAQIECBAgQKAuoADWDU0gQIAAAQIECEQJKIBRcVmWAAECBAgQIFAXUADrhiYQIECAAAECBKIEFMCouCxLgAABAgQIEKgLKIB1QxMIECBAgAABAlECCmBUXJYlQIAAAQIECNQFFMC6oQkECBAgQIAAgSgBBTAqLssSIECAAAECBOoCCmDd0AQCBAgQIECAQJSAAhgVl2UJECBAgAABAnUBBbBuaAIBAgQIECBAIEpAAYyKy7IECBAgQIAAgbqAAlg3NIEAAQIECBAgECWgAEbFZVkCBAgQIECAQF1AAawbmkCAAAECBAgQiBJQAKPisiwBAgQIECBAoC6gANYNTSBAgAABAgQIRAkogFFxWZYAAQIECBAgUBdQAOuGJhAgQIAAAQIEogQUwKi4LEuAAAECBAgQqAsogHVDEwgQIECAAAECUQIKYFRcliVAgAABAgQI1AUUwLqhCQQIECBAgACBKAEFMCouyxIgQIAAAQIE6gIKYN3QBAIECBAgQIBAlIACGBWXZQkQIECAAAECdQEFsG5oAgECBAgQIEAgSkABjIrLsgQIECBAgACBuoACWDc0gQABAgQIECAQJaAARsVlWQIECBAgQIBAXUABrBuaQIAAAQIECBCIElAAo+KyLAECBAgQIECgLqAA1g1NIECAAAECBAhECSiAUXFZlgABAgQIECBQF1AA64YmECBAgAABAgSiBBTAqLgsS4AAAQIECBCoCyiAdUMTCBAgQIAAAQJRAgpgVFyWJUCAAAECBAjUBRTAuqEJBAgQIECAAIEoAQUwKi7LEiBAgAABAgTqAgpg3dAEAgQIECBAgECUgAIYFZdlCRAgQIAAAQJ1AQWwbmgCAQIECBAgQCBKQAGMisuyBAgQIECAAIG6gAJYNzSBAAECBAgQIBAloABGxWVZAgQIECBAgEBdQAGsG5pAgAABAgQIEIgSUACj4rIsAQIECBAgQKAuoADWDU0gQIAAAQIECEQJKIBRcVmWAAECBAgQIFAXUADrhiYQIECAAAECBKIEFMCouCxLgAABAgQIEKgLKIB1QxMIECBAgAABAlECCmBUXJYlQIAAAQIECNQFFMC6oQkECBAgQIAAgSgBBTAqLssSIECAAAECBOoCCmDd0AQCBAgQIECAQJSAAhgVl2UJECBAgAABAnUBBbBuaAIBAgQIECBAIEpAAYyKy7IECBAgQIAAgbqAAlg3NIEAAQIECBAgECWgAEbFZVkCBAgQIECAQF1AAawbmkCAAAECBAgQiBJQAKPisiwBAgQIECBAoC6gANYNTSBAgAABAgQIRAkogFFxWZYAAQIECBAgUBdQAOuGJhAgQIAAAQIEogQUwKi4LEuAAAECBAgQqAsogHVDEwgQIECAAAECUQIKYFRcliVAgAABAgQI1AUUwLqhCQQIECBAgACBKAEFMCouyxIgQIAAAQIE6gIKYN3QBAIECBAgQIBAlIACGBWXZQkQIECAAAECdQEFsG5oAgECBAgQIEAgSkABjIrLsgQIECBAgACBuoACWDc0gQABAgQIECAQJaAARsVlWQIECBAgQIBAXUABrBuaQIAAAQIECBCIElAAo+KyLAECBAgQIECgLqAA1g1NIECAAAECBAhECSiAUXFZlgABAgQIECBQF1AA64YmECBAgAABAgSiBBTAqLgsS4AAAQIECBCoCyiAdUMTCBAgQIAAAQJRAgpgVFyWJUCAAAECBAjUBRTAuqEJBAgQIECAAIEoAQUwKi7LEiBAgAABAgTqAgpg3dAEAgQIECBAgECUgAIYFZdlCRAgQIAAAQJ1AQWwbmgCAQIECBAgQCBKQAGMisuyBAgQIECAAIG6gAJYNzSBAAECBAgQIBAloABGxWVZAgQIECBAgEBdQAGsG5pAgAABAgQIEIgSUACj4rIsAQIECBAgQKAuoADWDU0gQIAAAQIECEQJKIBRcVmWAAECBAgQIFAXUADrhiYQIECAAAECBKIEFMCouCxLgAABAgQIEKgLKIB1QxMIECBAgAABAlECCmBUXJYlQIAAAQIECNQFFMC6oQkECBAgQIAAgSgBBTAqLssSIECAAAECBOoCCmDd0AQCBAgQIECAQJSAAhgVl2UJECBAgAABAnUBBbBuaAIBAgQIECBAIEpAAYyKy7IECBAgQIAAgbqAAlg3NIEAAQIECBAgECWgAEbFZVkCBAgQIECAQF1AAawbmkCAAAECBAgQiBJQAKPisiwBAgQIECBAoC6gANYNTSBAgAABAgQIRAkogFFxWZYAAQIECBAgUBdQAOuGJhAgQIAAAQIEogQUwKi4LEuAAAECBAgQqAsogHVDEwgQIECAAAECUQIKYFRcliVAgAABAgQI1AUUwLqhCQQIECBAgACBKAEFMCouyxIgQIAAAQIE6gIKYN3QBAIECBAgQIBAlIACGBWXZQkQIECAAAECdQEFsG5oAgECBAgQIEAgSkABjIrLsgQIECBAgACBuoACWDc0gQABAgQIECAQJaAARsVlWQIECBAgQIBAXUABrBuaQIAAAQIECBCIElAAo+KyLAECBAgQIECgLqAA1g1NIECAAAECBAhECSiAUXFZlgABAgQIECBQF1AA64YmECBAgAABAgSiBBTAqLgsS4AAAQIECBCoCyiAdUMTCBAgQIAAAQJRAgpgVFyWJUCAAAECBAjUBRTAuqEJBAgQIECAAIEoAQUwKi7LEiBAgAABAgTqAgpg3dAEAgQIECBAgECUgAIYFZdlCRAgQIAAAQJ1AQWwbmgCAQIECBAgQCBK4H8AgXo4RMRFclgAAAAASUVORK5CYII=\",\"characterPrompts\":[{\"prompt\":\"girl, brown eyes, long hair, asymmetrical hair, light blue hair, flat chest, hooded cloak, hazmat suit, :3, hand to own mouth, corsage\",\"uc\":\"\",\"center\":{\"x\":0,\"y\":0}},{\"prompt\":\"boy, dark skin, black eyes, long hair, single braid, mizu happi, trembling, flower trim\",\"uc\":\"\",\"center\":{\"x\":0,\"y\":0}},{\"prompt\":\"boy, black eyes, half updo, short ponytai, diagonal bangs, hat, bicorne, animal costume, grin, under-rim eyewear\",\"uc\":\"\",\"center\":{\"x\":0,\"y\":0}}],\"extra_noise_seed\":3634432471,\"v4_prompt\":{\"caption\":{\"base_caption\":\"2boys, 1girl, photorealistic, full body, rating:general, amazing quality, very aesthetic, absurdres\",\"char_captions\":[{\"char_caption\":\"girl, brown eyes, long hair, asymmetrical hair, light blue hair, flat chest, hooded cloak, hazmat suit, :3, hand to own mouth, corsage\",\"centers\":[{\"x\":0,\"y\":0}]},{\"char_caption\":\"boy, dark skin, black eyes, long hair, single braid, mizu happi, trembling, flower trim\",\"centers\":[{\"x\":0,\"y\":0}]},{\"char_caption\":\"boy, black eyes, half updo, short ponytai, diagonal bangs, hat, bicorne, animal costume, grin, under-rim eyewear\",\"centers\":[{\"x\":0,\"y\":0}]}]},\"use_coords\":true,\"use_order\":true},\"v4_negative_prompt\":{\"caption\":{\"base_caption\":\"blurry, lowres, error, film grain, scan artifacts, worst quality, bad quality, jpeg artifacts, very displeasing, chromatic aberration, logo, dated, signature, multiple views, gigantic breasts\",\"char_captions\":[{\"char_caption\":\"\",\"centers\":[{\"x\":0,\"y\":0}]},{\"char_caption\":\"\",\"centers\":[{\"x\":0,\"y\":0}]},{\"char_caption\":\"\",\"centers\":[{\"x\":0,\"y\":0}]}]}},\"negative_prompt\":\"blurry, lowres, error, film grain, scan artifacts, worst quality, bad quality, jpeg artifacts, very displeasing, chromatic aberration, logo, dated, signature, multiple views, gigantic breasts\",\"reference_image_multiple\":[],\"reference_information_extracted_multiple\":[],\"reference_strength_multiple\":[],\"deliberate_euler_ancestral_bug\":false,\"prefer_brownian\":true}}", + "method": "POST", + "mode": "cors" +} \ No newline at end of file diff --git a/record/ai/generate_image/image2image_v3/image.png b/record/ai/generate_image/image2image_v3/image.png new file mode 100644 index 0000000000000000000000000000000000000000..c21b952b7c32cbcc27b4d4b8a81fe95580bc4848 GIT binary patch literal 5058 zcmeHL`Bzg}5`GCmf-FXGL0SSdN0@F!KvscB#08KgDuW29=zs!YUxR^|G&Gbtk@tjAFLDbQQEX|{fgsge4#$uFJvM7*(D|lY(t5-ET=PU5y5U~E zZL!I(`{Phb_;-7a6ZrU!Uk5owCsO&l?)7)8_`c7rb)!ag<=)AC`}|}f+%E4yfgZCN zQBsFCaav`nXOZV6RN{E-_yVzRMA%i6{h1osT2nZ>GC$g&08!MQIB$cX%klD9h++sw zL0Wep1ccOqU=SaOSc~bQL+=-(Al*OGM;q>Hh7u7@QT=7X3_JAo{IZZi;=Ak)fxz|K zAi;Z(yuMl*)cex7LYZO$M|lQy(cMZTKEE>-KNb`?Gwd`;oO4Xi=#w_PDT+Y+Z09^7 zmqw!z#~%CP-`w7*FHwec(J-X`%i#X9OdIlAMSM@b!+rdk^!w6#M}xF}0=%7z(Biyp zF&~Qe{3d-u2R~PeSXFc$j|Y5_)rQDA&{NrNrk8uuBZE-lNjJBp<>mDH94$o7Dah9G zfG6kKk(J@Z0zYXUi^Zy($W5IR#?3MHvg6O9;0P5;JKVLRPwN>pX(r_M$_5UsAh|J3RtL}v-&2{wZ)!iu90KSMGRIY zeKG(t0=C(^;@|=9_w{fr2AfMXLE@~lOc53(8@Rkgid9L{U8K4ADJe3d3!aMCac>a0LqyvM3a80Z{wep%YA`?4e1(71CecA zKtJaH$+l7ijc$kxM!lO9mvambdcuC7jZrkbUpCEw;kiD$F=LwO`8)bjGO8Ag6M zABoM-a#7?HhDbf6M5T(!0xEulpA_AoLFfc41p*DuIQWVk9Hsm0>C>m4HN@ze?_<;@ z0nX-??*L^#yE>wI4`0OQaRFRz`ylOP$NCo0)D+#LskcLK^*5A1ykvRCCmmq(#6rNb+<^w;!GNXV+2EHy|h_d84W#CL6R(sKR@!$q?wIGM@PF62n5WRTA8I! z_i^3Q?+a8gdpnpN{`&RnQZSYH`Je7nd3TS{hsf)LKGUAXg@uK)po*vF=Gbd%H;y8u zI5OKID-o-bd*Nb_%Y=gp<0q`bMJu=wA4UNe9pO+tpaB%g#Yf1S3D_+&3w z&_x_YX4yk5ic1z<<1`k+}(}P_En`|z0}cYmcCb6=kW05;NF-2 zDhnMFF6NhY_x5@W4i1)vjqr(I>f}VgCK^bPZBRz9XKE%%4^ z{3ateHPMmh+?ILT($aDxky)?CGCiwf!&_*Ws%veuizU}u=)EO=J)auyQ)$S12(4QA zBa-P7bu~3L3|BnGDA0Q&+5ht+eXnyM5d(q4|*0UKuUApq%Wg z1;IRn!or>d7Ov^52=@sdsOVToYs=Z-(YJ5y1;#luNGv6M5pY5JtvV1g6HL(z^Zbk4 zbL>lli;DjH;i#OWIyyReMit?s_2NYVj!Nr{VO4y*Ef$N|R2nS!1O(4I0ZP8ALoHs! zEXU6YYn*YGqSbMm^&*hJd6RqE&jIH=f;MPpx}>e!YOdPVM*1aD^MN!mJze?kVj>xY zi*pYYY#%2;F!2JQP@re(0`Ylz5DZXhl)Rct5`@UWsw9Sipe}*kX#=A$P6=+AG>33mO2bsJ0#ti3b9bDbtk@tjAFLDbQQEX|{fgsge4#$uFJvM7*(D|lY(t5-ET=PU5y5U~E zZL!I(`{Phb_;-7a6ZrU!Uk5owCsO&l?)7)8_`c7rb)!ag<=)AC`}|}f+%E4yfgZCN zQBsFCaav`nXOZV6RN{E-_yVzRMA%i6{h1osT2nZ>GC$g&08!MQIB$cX%klD9h++sw zL0Wep1ccOqU=SaOSc~bQL+=-(Al*OGM;q>Hh7u7@QT=7X3_JAo{IZZi;=Ak)fxz|K zAi;Z(yuMl*)cex7LYZO$M|lQy(cMZTKEE>-KNb`?Gwd`;oO4Xi=#w_PDT+Y+Z09^7 zmqw!z#~%CP-`w7*FHwec(J-X`%i#X9OdIlAMSM@b!+rdk^!w6#M}xF}0=%7z(Biyp zF&~Qe{3d-u2R~PeSXFc$j|Y5_)rQDA&{NrNrk8uuBZE-lNjJBp<>mDH94$o7Dah9G zfG6kKk(J@Z0zYXUi^Zy($W5IR#?3MHvg6O9;0P5;JKVLRPwN>pX(r_M$_5UsAh|J3RtL}v-&2{wZ)!iu90KSMGRIY zeKG(t0=C(^;@|=9_w{fr2AfMXLE@~lOc53(8@Rkgid9L{U8K4ADJe3d3!aMCac>a0LqyvM3a80Z{wep%YA`?4e1(71CecA zKtJaH$+l7ijc$kxM!lO9mvambdcuC7jZrkbUpCEw;kiD$F=LwO`8)bjGO8Ag6M zABoM-a#7?HhDbf6M5T(!0xEulpA_AoLFfc41p*DuIQWVk9Hsm0>C>m4HN@ze?_<;@ z0nX-??*L^#yE>wI4`0OQaRFRz`ylOP$NCo0)D+#LskcLK^*5A1ykvRCCmmq(#6rNb+<^w;!GNXV+2EHy|h_d84W#CL6R(sKR@!$q?wIGM@PF62n5WRTA8I! z_i^3Q?+a8gdpnpN{`&RnQZSYH`Je7nd3TS{hsf)LKGUAXg@uK)po*vF=Gbd%H;y8u zI5OKID-o-bd*Nb_%Y=gp<0q`bMJu=wA4UNe9pO+tpaB%g#Yf1S3D_+&3w z&_x_YX4yk5ic1z<<1`k+}(}P_En`|z0}cYmcCb6=kW05;NF-2 zDhnMFF6NhY_x5@W4i1)vjqr(I>f}VgCK^bPZBRz9XKE%%4^ z{3ateHPMmh+?ILT($aDxky)?CGCiwf!&_*Ws%veuizU}u=)EO=J)auyQ)$S12(4QA zBa-P7bu~3L3|BnGDA0Q&+5ht+eXnyM5d(q4|*0UKuUApq%Wg z1;IRn!or>d7Ov^52=@sdsOVToYs=Z-(YJ5y1;#luNGv6M5pY5JtvV1g6HL(z^Zbk4 zbL>lli;DjH;i#OWIyyReMit?s_2NYVj!Nr{VO4y*Ef$N|R2nS!1O(4I0ZP8ALoHs! zEXU6YYn*YGqSbMm^&*hJd6RqE&jIH=f;MPpx}>e!YOdPVM*1aD^MN!mJze?kVj>xY zi*pYYY#%2;F!2JQP@re(0`Ylz5DZXhl)Rct5`@UWsw9Sipe}*kX#=A$P6=+AG>33mO2bsJ0#ti3b9bD!1f(f$&u@C zGc){KeYf_voiV>I;}0oux@GZarPT}MpUXO@ GgeCw91kJ1f literal 0 HcmV?d00001 diff --git a/record/ai/generate_image/inpaint_v3/schema.json b/record/ai/generate_image/inpaint_v3/schema.json new file mode 100644 index 0000000..aa33efd --- /dev/null +++ b/record/ai/generate_image/inpaint_v3/schema.json @@ -0,0 +1,65 @@ +{ + "input": "2boys, 1girl, photorealistic, full body, best quality, amazing quality, very aesthetic, absurdres", + "model": "nai-diffusion-3-inpainting", + "action": "infill", + "parameters": { + "params_version": 3, + "width": 640, + "height": 640, + "scale": 6, + "sampler": "k_euler_ancestral", + "steps": 23, + "n_samples": 1, + "strength": 0.7, + "noise": 0.2, + "ucPreset": 0, + "qualityToggle": true, + "sm": false, + "sm_dyn": false, + "dynamic_thresholding": false, + "controlnet_strength": 1, + "legacy": false, + "add_original_image": true, + "cfg_rescale": 0, + "noise_schedule": "karras", + "legacy_v3_extend": false, + "skip_cfg_above_sigma": null, + "use_coords": true, + "seed": 1504970584, + "image": "Base64 Data", + "mask": "Base64 Data", + "characterPrompts": [ + { + "prompt": "girl, brown eyes, long hair, asymmetrical hair, light blue hair, flat chest, hooded cloak, hazmat suit, :3, hand to own mouth, corsage", + "uc": "", + "center": { + "x": 0, + "y": 0 + } + }, + { + "prompt": "boy, dark skin, black eyes, long hair, single braid, mizu happi, trembling, flower trim", + "uc": "", + "center": { + "x": 0, + "y": 0 + } + }, + { + "prompt": "boy, black eyes, half updo, short ponytai, diagonal bangs, hat, bicorne, animal costume, grin, under-rim eyewear", + "uc": "", + "center": { + "x": 0, + "y": 0 + } + } + ], + "extra_noise_seed": 1504970584, + "negative_prompt": "nsfw, lowres, {bad}, error, fewer, extra, missing, worst quality, jpeg artifacts, bad quality, watermark, unfinished, displeasing, chromatic aberration, signature, extra digits, artistic error, username, scan, [abstract]", + "reference_image_multiple": [], + "reference_information_extracted_multiple": [], + "reference_strength_multiple": [], + "deliberate_euler_ancestral_bug": false, + "prefer_brownian": true + } +} \ No newline at end of file diff --git a/record/ai/generate_image/text2image.json b/record/ai/generate_image/text2image.json index f1dbe54..93e1395 100644 --- a/record/ai/generate_image/text2image.json +++ b/record/ai/generate_image/text2image.json @@ -1,19 +1,22 @@ { "credentials": "include", "headers": { - "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:123.0) Gecko/20100101 Firefox/123.0", + "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:133.0) Gecko/20100101 Firefox/133.0", "Accept": "*/*", - + "Accept-Language": "zh-CN,zh;q=0.8,zh-TW;q=0.7,zh-HK;q=0.5,en-US;q=0.3,en;q=0.2", "Content-Type": "application/json", "Authorization": "Secret", + "x-correlation-id": "00000", + "x-initiated-at": "2024-12-21T00:00:00.473Z", "Sec-Fetch-Dest": "empty", "Sec-Fetch-Mode": "cors", "Sec-Fetch-Site": "same-site", + "Priority": "u=0", "Pragma": "no-cache", "Cache-Control": "no-cache" }, "referrer": "https://novelai.net/", - "body": "{\"input\":\"1boy, leaf background, from behind, cowboy shot, purple eyes, big hair, blonde hair, long bangs, tiara, striped shirt, shorts, impossible clothes, prosthetic leg, back focus, best quality, amazing quality, very aesthetic, absurdres\",\"model\":\"nai-diffusion-3\",\"action\":\"generate\",\"parameters\":{\"params_version\":1,\"width\":128,\"height\":128,\"scale\":5,\"sampler\":\"k_euler\",\"steps\":28,\"n_samples\":1,\"ucPreset\":0,\"qualityToggle\":true,\"sm\":false,\"sm_dyn\":false,\"dynamic_thresholding\":false,\"controlnet_strength\":1,\"legacy\":false,\"add_original_image\":false,\"uncond_scale\":1,\"cfg_rescale\":0,\"noise_schedule\":\"native\",\"legacy_v3_extend\":false,\"reference_information_extracted\":0.53,\"reference_strength\":0.53,\"seed\":1476631302,\"negative_prompt\":\"nsfw, lowres, {bad}, error, fewer, extra, missing, worst quality, jpeg artifacts, bad quality, watermark, unfinished, displeasing, chromatic aberration, signature, extra digits, artistic error, username, scan, [abstract], 123123\"}}", + "body": "{\"input\":\"2boys, 1girl, photorealistic, full body, best quality, amazing quality, very aesthetic, absurdres\",\"model\":\"nai-diffusion-3\",\"action\":\"generate\",\"parameters\":{\"params_version\":3,\"width\":832,\"height\":1216,\"scale\":5,\"sampler\":\"k_euler_ancestral\",\"steps\":23,\"seed\":2222664127,\"n_samples\":1,\"ucPreset\":0,\"qualityToggle\":true,\"sm\":false,\"sm_dyn\":false,\"dynamic_thresholding\":false,\"controlnet_strength\":1,\"legacy\":false,\"add_original_image\":true,\"cfg_rescale\":0,\"noise_schedule\":\"karras\",\"legacy_v3_extend\":false,\"skip_cfg_above_sigma\":null,\"characterPrompts\":[],\"negative_prompt\":\"nsfw, lowres, {bad}, error, fewer, extra, missing, worst quality, jpeg artifacts, bad quality, watermark, unfinished, displeasing, chromatic aberration, signature, extra digits, artistic error, username, scan, [abstract]\",\"reference_image_multiple\":[],\"reference_information_extracted_multiple\":[],\"reference_strength_multiple\":[],\"deliberate_euler_ancestral_bug\":false,\"prefer_brownian\":true}}", "method": "POST", "mode": "cors" } \ No newline at end of file diff --git a/record/ai/generate_image/text2image/schema.json b/record/ai/generate_image/text2image/schema.json index e683919..01a9153 100644 --- a/record/ai/generate_image/text2image/schema.json +++ b/record/ai/generate_image/text2image/schema.json @@ -1,14 +1,15 @@ { - "input": "1boy, leaf background, from behind, cowboy shot, purple eyes, big hair, blonde hair, long bangs, tiara, striped shirt, shorts, impossible clothes, prosthetic leg, back focus, best quality, amazing quality, very aesthetic, absurdres", + "input": "2boys, 1girl, photorealistic, full body, best quality, amazing quality, very aesthetic, absurdres", "model": "nai-diffusion-3", "action": "generate", "parameters": { - "params_version": 1, - "width": 128, - "height": 128, + "params_version": 3, + "width": 832, + "height": 1216, "scale": 5, - "sampler": "k_euler", - "steps": 28, + "sampler": "k_euler_ancestral", + "steps": 23, + "seed": 2222664127, "n_samples": 1, "ucPreset": 0, "qualityToggle": true, @@ -17,14 +18,17 @@ "dynamic_thresholding": false, "controlnet_strength": 1, "legacy": false, - "add_original_image": false, - "uncond_scale": 1, + "add_original_image": true, "cfg_rescale": 0, - "noise_schedule": "native", + "noise_schedule": "karras", "legacy_v3_extend": false, - "reference_information_extracted": 0.53, - "reference_strength": 0.53, - "seed": 1476631302, - "negative_prompt": "nsfw, lowres, {bad}, error, fewer, extra, missing, worst quality, jpeg artifacts, bad quality, watermark, unfinished, displeasing, chromatic aberration, signature, extra digits, artistic error, username, scan, [abstract], 123123" + "skip_cfg_above_sigma": null, + "characterPrompts": [], + "negative_prompt": "nsfw, lowres, {bad}, error, fewer, extra, missing, worst quality, jpeg artifacts, bad quality, watermark, unfinished, displeasing, chromatic aberration, signature, extra digits, artistic error, username, scan, [abstract]", + "reference_image_multiple": [], + "reference_information_extracted_multiple": [], + "reference_strength_multiple": [], + "deliberate_euler_ancestral_bug": false, + "prefer_brownian": true } } \ No newline at end of file diff --git a/record/ai/generate_image/text2image_v3.json b/record/ai/generate_image/text2image_v3.json new file mode 100644 index 0000000..3b9d037 --- /dev/null +++ b/record/ai/generate_image/text2image_v3.json @@ -0,0 +1,22 @@ +{ + "credentials": "include", + "headers": { + "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:133.0) Gecko/20100101 Firefox/133.0", + "Accept": "*/*", + "Accept-Language": "zh-CN,zh;q=0.8,zh-TW;q=0.7,zh-HK;q=0.5,en-US;q=0.3,en;q=0.2", + "Content-Type": "application/json", + "Authorization": "Secret", + "x-correlation-id": "555", + "x-initiated-at": "2024-12-05T05:57:04.600Z", + "Sec-Fetch-Dest": "empty", + "Sec-Fetch-Mode": "cors", + "Sec-Fetch-Site": "same-site", + "Priority": "u=0", + "Pragma": "no-cache", + "Cache-Control": "no-cache" + }, + "referrer": "https://novelai.net/", + "body": "{\"input\":\"2boys, 1girl, photorealistic, full body, rating:general, amazing quality, very aesthetic, absurdres\",\"model\":\"nai-diffusion-4-curated-preview\",\"action\":\"generate\",\"parameters\":{\"params_version\":3,\"width\":640,\"height\":640,\"scale\":6,\"sampler\":\"k_euler_ancestral\",\"steps\":23,\"n_samples\":1,\"ucPreset\":0,\"qualityToggle\":true,\"dynamic_thresholding\":false,\"controlnet_strength\":1,\"legacy\":false,\"add_original_image\":true,\"cfg_rescale\":0,\"noise_schedule\":\"karras\",\"legacy_v3_extend\":false,\"use_coords\":true,\"seed\":1407032209,\"characterPrompts\":[{\"prompt\":\"girl, brown eyes, long hair, asymmetrical hair, light blue hair, flat chest, hooded cloak, hazmat suit, :3, hand to own mouth, corsage\",\"uc\":\"\",\"center\":{\"x\":0,\"y\":0}},{\"prompt\":\"boy, dark skin, black eyes, long hair, single braid, mizu happi, trembling, flower trim\",\"uc\":\"\",\"center\":{\"x\":0,\"y\":0}},{\"prompt\":\"boy, black eyes, half updo, short ponytai, diagonal bangs, hat, bicorne, animal costume, grin, under-rim eyewear\",\"uc\":\"\",\"center\":{\"x\":0,\"y\":0}}],\"v4_prompt\":{\"caption\":{\"base_caption\":\"2boys, 1girl, photorealistic, full body, rating:general, amazing quality, very aesthetic, absurdres\",\"char_captions\":[{\"char_caption\":\"girl, brown eyes, long hair, asymmetrical hair, light blue hair, flat chest, hooded cloak, hazmat suit, :3, hand to own mouth, corsage\",\"centers\":[{\"x\":0,\"y\":0}]},{\"char_caption\":\"boy, dark skin, black eyes, long hair, single braid, mizu happi, trembling, flower trim\",\"centers\":[{\"x\":0,\"y\":0}]},{\"char_caption\":\"boy, black eyes, half updo, short ponytai, diagonal bangs, hat, bicorne, animal costume, grin, under-rim eyewear\",\"centers\":[{\"x\":0,\"y\":0}]}]},\"use_coords\":true,\"use_order\":true},\"v4_negative_prompt\":{\"caption\":{\"base_caption\":\"blurry, lowres, error, film grain, scan artifacts, worst quality, bad quality, jpeg artifacts, very displeasing, chromatic aberration, logo, dated, signature, multiple views, gigantic breasts\",\"char_captions\":[{\"char_caption\":\"\",\"centers\":[{\"x\":0,\"y\":0}]},{\"char_caption\":\"\",\"centers\":[{\"x\":0,\"y\":0}]},{\"char_caption\":\"\",\"centers\":[{\"x\":0,\"y\":0}]}]}},\"negative_prompt\":\"blurry, lowres, error, film grain, scan artifacts, worst quality, bad quality, jpeg artifacts, very displeasing, chromatic aberration, logo, dated, signature, multiple views, gigantic breasts\",\"reference_image_multiple\":[],\"reference_information_extracted_multiple\":[],\"reference_strength_multiple\":[],\"deliberate_euler_ancestral_bug\":false,\"prefer_brownian\":true}}", + "method": "POST", + "mode": "cors" +} \ No newline at end of file diff --git a/record/ai/generate_image/text2image_v3/schema.json b/record/ai/generate_image/text2image_v3/schema.json new file mode 100644 index 0000000..2e5be47 --- /dev/null +++ b/record/ai/generate_image/text2image_v3/schema.json @@ -0,0 +1,127 @@ +{ + "input": "2boys, 1girl, photorealistic, full body, rating:general, amazing quality, very aesthetic, absurdres", + "model": "nai-diffusion-4-curated-preview", + "action": "generate", + "parameters": { + "params_version": 3, + "width": 640, + "height": 640, + "scale": 6, + "sampler": "k_euler_ancestral", + "steps": 23, + "n_samples": 1, + "ucPreset": 0, + "qualityToggle": true, + "dynamic_thresholding": false, + "controlnet_strength": 1, + "legacy": false, + "add_original_image": true, + "cfg_rescale": 0, + "noise_schedule": "karras", + "legacy_v3_extend": false, + "use_coords": true, + "seed": 1407032209, + "characterPrompts": [ + { + "prompt": "girl, brown eyes, long hair, asymmetrical hair, light blue hair, flat chest, hooded cloak, hazmat suit, :3, hand to own mouth, corsage", + "uc": "", + "center": { + "x": 0, + "y": 0 + } + }, + { + "prompt": "boy, dark skin, black eyes, long hair, single braid, mizu happi, trembling, flower trim", + "uc": "", + "center": { + "x": 0, + "y": 0 + } + }, + { + "prompt": "boy, black eyes, half updo, short ponytai, diagonal bangs, hat, bicorne, animal costume, grin, under-rim eyewear", + "uc": "", + "center": { + "x": 0, + "y": 0 + } + } + ], + "v4_prompt": { + "caption": { + "base_caption": "2boys, 1girl, photorealistic, full body, rating:general, amazing quality, very aesthetic, absurdres", + "char_captions": [ + { + "char_caption": "girl, brown eyes, long hair, asymmetrical hair, light blue hair, flat chest, hooded cloak, hazmat suit, :3, hand to own mouth, corsage", + "centers": [ + { + "x": 0, + "y": 0 + } + ] + }, + { + "char_caption": "boy, dark skin, black eyes, long hair, single braid, mizu happi, trembling, flower trim", + "centers": [ + { + "x": 0, + "y": 0 + } + ] + }, + { + "char_caption": "boy, black eyes, half updo, short ponytai, diagonal bangs, hat, bicorne, animal costume, grin, under-rim eyewear", + "centers": [ + { + "x": 0, + "y": 0 + } + ] + } + ] + }, + "use_coords": true, + "use_order": true + }, + "v4_negative_prompt": { + "caption": { + "base_caption": "blurry, lowres, error, film grain, scan artifacts, worst quality, bad quality, jpeg artifacts, very displeasing, chromatic aberration, logo, dated, signature, multiple views, gigantic breasts", + "char_captions": [ + { + "char_caption": "", + "centers": [ + { + "x": 0, + "y": 0 + } + ] + }, + { + "char_caption": "", + "centers": [ + { + "x": 0, + "y": 0 + } + ] + }, + { + "char_caption": "", + "centers": [ + { + "x": 0, + "y": 0 + } + ] + } + ] + } + }, + "negative_prompt": "blurry, lowres, error, film grain, scan artifacts, worst quality, bad quality, jpeg artifacts, very displeasing, chromatic aberration, logo, dated, signature, multiple views, gigantic breasts", + "reference_image_multiple": [], + "reference_information_extracted_multiple": [], + "reference_strength_multiple": [], + "deliberate_euler_ancestral_bug": false, + "prefer_brownian": true + } +} \ No newline at end of file From 828db2b68732de5fd6db89e36dffa45bdd380421 Mon Sep 17 00:00:00 2001 From: sudoskys Date: Sat, 21 Dec 2024 23:23:06 +0800 Subject: [PATCH 3/8] format all files --- pdm.lock | 781 ++++++++---------- playground/augment-image.py | 2 +- playground/enhance.py | 2 +- playground/generate_image.py | 2 +- playground/generate_image_img2img.py | 2 +- playground/information.py | 2 +- playground/login.py | 2 +- playground/paint_mask/__init__.py | 2 +- playground/random_prompt.py | 2 +- playground/subscription.py | 2 +- playground/suggest_tag.py | 2 +- playground/upscale.py | 4 +- src/novelai_python/_response/__init__.py | 2 +- src/novelai_python/_response/ai/__init__.py | 2 +- .../_response/ai/generate_image.py | 2 +- src/novelai_python/_response/ai/upscale.py | 2 +- src/novelai_python/_response/schema.py | 2 +- src/novelai_python/_response/user/__init__.py | 2 +- .../_response/user/information.py | 2 +- src/novelai_python/_response/user/login.py | 2 +- .../_response/user/subscription.py | 2 +- src/novelai_python/credential/ApiToken.py | 2 +- src/novelai_python/credential/JwtToken.py | 2 +- src/novelai_python/credential/__init__.py | 2 +- src/novelai_python/credential/_base.py | 2 +- src/novelai_python/sdk/__init__.py | 2 +- src/novelai_python/sdk/ai/__init__.py | 2 +- src/novelai_python/sdk/ai/_enum.py | 1 - .../sdk/ai/augment_image/__init__.py | 2 +- .../sdk/ai/generate_image/suggest_tags.py | 2 +- src/novelai_python/sdk/ai/upscale.py | 1 - src/novelai_python/sdk/schema.py | 2 +- src/novelai_python/sdk/user/__init__.py | 2 +- src/novelai_python/sdk/user/information.py | 2 +- src/novelai_python/sdk/user/login.py | 2 +- src/novelai_python/sdk/user/subscription.py | 2 +- src/novelai_python/tool/random_prompt/tag.py | 2 +- .../tool/random_prompt/tag_character.py | 2 +- .../tool/random_prompt/tag_nsfw.py | 2 +- src/novelai_python/utils/__init__.py | 2 +- src/novelai_python/utils/useful.py | 2 +- tests/test_random_prompt.py | 2 +- tests/test_server.py | 9 +- tests/test_server_run.py | 2 +- tests/test_upscale.py | 4 +- tests/test_user_information.py | 2 +- tests/test_user_login.py | 2 +- tests/test_user_subscription.py | 2 +- 48 files changed, 420 insertions(+), 464 deletions(-) diff --git a/pdm.lock b/pdm.lock index 2ff78ba..4efffbe 100755 --- a/pdm.lock +++ b/pdm.lock @@ -5,7 +5,7 @@ groups = ["default", "dev", "testing"] strategy = ["cross_platform", "inherit_metadata"] lock_version = "4.5.0" -content_hash = "sha256:ebe3086cd1e551d730d245a3b012fafcac9ebf7898424df23e32dc52805ec1df" +content_hash = "sha256:ab8cd395ee85fe76f8f6baf90c8597097b176ae23b182230de866c1c7daa9273" [[metadata.targets]] requires_python = ">=3.9" @@ -415,25 +415,26 @@ files = [ [[package]] name = "curl-cffi" -version = "0.7.1" +version = "0.7.4" requires_python = ">=3.8" summary = "libcurl ffi bindings for Python, with impersonation support." groups = ["default"] dependencies = [ "certifi>=2024.2.2", "cffi>=1.12.0", + "typing-extensions", ] files = [ - {file = "curl_cffi-0.7.1-cp38-abi3-macosx_10_9_x86_64.whl", hash = "sha256:54edae42b25f30048fd6c2de06ed9df37bbe6ffdce14cc8a27c79f8c7d47977a"}, - {file = "curl_cffi-0.7.1-cp38-abi3-macosx_11_0_arm64.whl", hash = "sha256:5c347e221ddbbde2275aa7cde00933402638c2062a3984104f66b1bb20528545"}, - {file = "curl_cffi-0.7.1-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99a5cc1d9ca59692cc5c175da0b397104283a0fea7515045fd22a7296296d82b"}, - {file = "curl_cffi-0.7.1-cp38-abi3-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:0719fec4b5e1c300bf58411b1cea26cb91c44492fcf5a14ef684fe085f4d8b6e"}, - {file = "curl_cffi-0.7.1-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1e53ab76259b575017d3260854456ba6a3fbe31cee9b44edd275d4ea9f0f20e1"}, - {file = "curl_cffi-0.7.1-cp38-abi3-musllinux_1_1_aarch64.whl", hash = "sha256:39d04ee1fc5f668ce53234051153031b3a3714300b772379e276565ad7cd244c"}, - {file = "curl_cffi-0.7.1-cp38-abi3-musllinux_1_1_x86_64.whl", hash = "sha256:e60f0dca3a55298898c62c21f0d8461e61aab96d033a7e9cead6160462728f7f"}, - {file = "curl_cffi-0.7.1-cp38-abi3-win32.whl", hash = "sha256:318a9a21f69e720ca904a0edc80bcbb7bbb75a4bab7b31341a202f07d5378c8e"}, - {file = "curl_cffi-0.7.1-cp38-abi3-win_amd64.whl", hash = "sha256:0eb5b08f562749639529e6990ff1b10a40e53ed45115e15f00b239230eabb927"}, - {file = "curl_cffi-0.7.1.tar.gz", hash = "sha256:8a64b12432146a3f178c4792c91188c18f50cc4b76e908ffc3206442c4610894"}, + {file = "curl_cffi-0.7.4-cp38-abi3-macosx_10_9_x86_64.whl", hash = "sha256:417f5264fa746d2680ebb20fbfbcfe5d77fa11a735548d9db6734e839a238e22"}, + {file = "curl_cffi-0.7.4-cp38-abi3-macosx_11_0_arm64.whl", hash = "sha256:fb76b654fcf9f3e0400cf13be949e4fc525aeb0f9e2e90e61ae48d5bd8557d25"}, + {file = "curl_cffi-0.7.4-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:bb9db59b164f2b6be65be62add5896a6fe125c52572aca3046caffbd7eb38f46"}, + {file = "curl_cffi-0.7.4-cp38-abi3-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:4593b120c8101b327e4e2d2c278652c5ef58c42dd39dc4586c2789e42a8bc8b1"}, + {file = "curl_cffi-0.7.4-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:c4b5685fab3984aae559e6590a6434a7e34f5d615c562c29c1554a90fffbf0bd"}, + {file = "curl_cffi-0.7.4-cp38-abi3-musllinux_1_1_aarch64.whl", hash = "sha256:3f8c19b5ca979e806fcf4de24f606eff745c85b43e9e88956d1db3c07516cc4b"}, + {file = "curl_cffi-0.7.4-cp38-abi3-musllinux_1_1_x86_64.whl", hash = "sha256:9957464013b1f76b0e9259ab846fa60faef7ff08e96e7a1764dd63c83005b836"}, + {file = "curl_cffi-0.7.4-cp38-abi3-win32.whl", hash = "sha256:8e9019cf6996bf508e4a51751d7217f22d5902405878679a3ac4757159251741"}, + {file = "curl_cffi-0.7.4-cp38-abi3-win_amd64.whl", hash = "sha256:31a80d5ab1bc0f9d4bc0f98d91dc1a3ed4aa08566f21b76ecfde23ece08e0fa9"}, + {file = "curl_cffi-0.7.4.tar.gz", hash = "sha256:37a2c8ec77b9914b0c14c74f604991751948d9d5def58fcddcbe73e3b62111c1"}, ] [[package]] @@ -475,32 +476,32 @@ files = [ [[package]] name = "fake-useragent" -version = "1.5.1" +version = "2.0.3" +requires_python = ">=3.9" summary = "Up-to-date simple useragent faker with real world database" groups = ["default"] dependencies = [ - "importlib-metadata~=4.0; python_version < \"3.8\"", - "importlib-resources>=5.0; python_version < \"3.10\"", + "importlib-resources>=6.0; python_version < \"3.10\"", ] files = [ - {file = "fake-useragent-1.5.1.tar.gz", hash = "sha256:6387269f5a2196b5ba7ed8935852f75486845a1c95c50e72460e6a8e762f5c49"}, - {file = "fake_useragent-1.5.1-py3-none-any.whl", hash = "sha256:57415096557c8a4e23b62a375c21c55af5fd4ba30549227f562d2c4f5b60e3b3"}, + {file = "fake_useragent-2.0.3-py3-none-any.whl", hash = "sha256:8bae50abb72c309a5b3ae2f01a0b82426613fd5c4e2a04dca9332399ec44daa1"}, + {file = "fake_useragent-2.0.3.tar.gz", hash = "sha256:af86a26ef8229efece8fed529b4aeb5b73747d889b60f01cd477b6f301df46e6"}, ] [[package]] name = "fastapi" -version = "0.115.0" +version = "0.115.6" requires_python = ">=3.8" summary = "FastAPI framework, high performance, easy to learn, fast to code, ready for production" groups = ["default"] dependencies = [ "pydantic!=1.8,!=1.8.1,!=2.0.0,!=2.0.1,!=2.1.0,<3.0.0,>=1.7.4", - "starlette<0.39.0,>=0.37.2", + "starlette<0.42.0,>=0.40.0", "typing-extensions>=4.8.0", ] files = [ - {file = "fastapi-0.115.0-py3-none-any.whl", hash = "sha256:17ea427674467486e997206a5ab25760f6b09e069f099b96f5b55a32fb6f1631"}, - {file = "fastapi-0.115.0.tar.gz", hash = "sha256:f93b4ca3529a8ebc6fc3fcf710e5efa8de3df9b41570958abf1d97d843138004"}, + {file = "fastapi-0.115.6-py3-none-any.whl", hash = "sha256:e9240b29e36fa8f4bb7290316988e90c381e5092e0cbe84e7818cc3713bcf305"}, + {file = "fastapi-0.115.6.tar.gz", hash = "sha256:9ec46f7addc14ea472958a96aae5b5de65f39721a46aaf5705c480d9a8b76654"}, ] [[package]] @@ -527,16 +528,16 @@ files = [ [[package]] name = "ftfy" -version = "6.2.3" -requires_python = "<4,>=3.8.1" +version = "6.3.1" +requires_python = ">=3.9" summary = "Fixes mojibake and other problems with Unicode, after the fact" groups = ["default"] dependencies = [ - "wcwidth<0.3.0,>=0.2.12", + "wcwidth", ] files = [ - {file = "ftfy-6.2.3-py3-none-any.whl", hash = "sha256:f15761b023f3061a66207d33f0c0149ad40a8319fd16da91796363e2c049fdf8"}, - {file = "ftfy-6.2.3.tar.gz", hash = "sha256:79b505988f29d577a58a9069afe75553a02a46e42de6091c0660cdc67812badc"}, + {file = "ftfy-6.3.1-py3-none-any.whl", hash = "sha256:7c70eb532015cd2f9adb53f101fb6c7945988d023a085d127d1573dc49dd0083"}, + {file = "ftfy-6.3.1.tar.gz", hash = "sha256:9b3c3d90f84fb267fe64d375a07b7f8912d817cf86009ae134aa03e1819506ec"}, ] [[package]] @@ -570,52 +571,52 @@ files = [ [[package]] name = "httptools" -version = "0.6.1" +version = "0.6.4" requires_python = ">=3.8.0" summary = "A collection of framework independent HTTP protocol utils." groups = ["default"] files = [ - {file = "httptools-0.6.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:d2f6c3c4cb1948d912538217838f6e9960bc4a521d7f9b323b3da579cd14532f"}, - {file = "httptools-0.6.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:00d5d4b68a717765b1fabfd9ca755bd12bf44105eeb806c03d1962acd9b8e563"}, - {file = "httptools-0.6.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:639dc4f381a870c9ec860ce5c45921db50205a37cc3334e756269736ff0aac58"}, - {file = "httptools-0.6.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e57997ac7fb7ee43140cc03664de5f268813a481dff6245e0075925adc6aa185"}, - {file = "httptools-0.6.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:0ac5a0ae3d9f4fe004318d64b8a854edd85ab76cffbf7ef5e32920faef62f142"}, - {file = "httptools-0.6.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:3f30d3ce413088a98b9db71c60a6ada2001a08945cb42dd65a9a9fe228627658"}, - {file = "httptools-0.6.1-cp310-cp310-win_amd64.whl", hash = "sha256:1ed99a373e327f0107cb513b61820102ee4f3675656a37a50083eda05dc9541b"}, - {file = "httptools-0.6.1-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:7a7ea483c1a4485c71cb5f38be9db078f8b0e8b4c4dc0210f531cdd2ddac1ef1"}, - {file = "httptools-0.6.1-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:85ed077c995e942b6f1b07583e4eb0a8d324d418954fc6af913d36db7c05a5a0"}, - {file = "httptools-0.6.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8b0bb634338334385351a1600a73e558ce619af390c2b38386206ac6a27fecfc"}, - {file = "httptools-0.6.1-cp311-cp311-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7d9ceb2c957320def533671fc9c715a80c47025139c8d1f3797477decbc6edd2"}, - {file = "httptools-0.6.1-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:4f0f8271c0a4db459f9dc807acd0eadd4839934a4b9b892f6f160e94da309837"}, - {file = "httptools-0.6.1-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:6a4f5ccead6d18ec072ac0b84420e95d27c1cdf5c9f1bc8fbd8daf86bd94f43d"}, - {file = "httptools-0.6.1-cp311-cp311-win_amd64.whl", hash = "sha256:5cceac09f164bcba55c0500a18fe3c47df29b62353198e4f37bbcc5d591172c3"}, - {file = "httptools-0.6.1-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:75c8022dca7935cba14741a42744eee13ba05db00b27a4b940f0d646bd4d56d0"}, - {file = "httptools-0.6.1-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:48ed8129cd9a0d62cf4d1575fcf90fb37e3ff7d5654d3a5814eb3d55f36478c2"}, - {file = "httptools-0.6.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6f58e335a1402fb5a650e271e8c2d03cfa7cea46ae124649346d17bd30d59c90"}, - {file = "httptools-0.6.1-cp312-cp312-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:93ad80d7176aa5788902f207a4e79885f0576134695dfb0fefc15b7a4648d503"}, - {file = "httptools-0.6.1-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:9bb68d3a085c2174c2477eb3ffe84ae9fb4fde8792edb7bcd09a1d8467e30a84"}, - {file = "httptools-0.6.1-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:b512aa728bc02354e5ac086ce76c3ce635b62f5fbc32ab7082b5e582d27867bb"}, - {file = "httptools-0.6.1-cp312-cp312-win_amd64.whl", hash = "sha256:97662ce7fb196c785344d00d638fc9ad69e18ee4bfb4000b35a52efe5adcc949"}, - {file = "httptools-0.6.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:8e216a038d2d52ea13fdd9b9c9c7459fb80d78302b257828285eca1c773b99b3"}, - {file = "httptools-0.6.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:3e802e0b2378ade99cd666b5bffb8b2a7cc8f3d28988685dc300469ea8dd86cb"}, - {file = "httptools-0.6.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4bd3e488b447046e386a30f07af05f9b38d3d368d1f7b4d8f7e10af85393db97"}, - {file = "httptools-0.6.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:fe467eb086d80217b7584e61313ebadc8d187a4d95bb62031b7bab4b205c3ba3"}, - {file = "httptools-0.6.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:3c3b214ce057c54675b00108ac42bacf2ab8f85c58e3f324a4e963bbc46424f4"}, - {file = "httptools-0.6.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8ae5b97f690badd2ca27cbf668494ee1b6d34cf1c464271ef7bfa9ca6b83ffaf"}, - {file = "httptools-0.6.1-cp38-cp38-win_amd64.whl", hash = "sha256:405784577ba6540fa7d6ff49e37daf104e04f4b4ff2d1ac0469eaa6a20fde084"}, - {file = "httptools-0.6.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:95fb92dd3649f9cb139e9c56604cc2d7c7bf0fc2e7c8d7fbd58f96e35eddd2a3"}, - {file = "httptools-0.6.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:dcbab042cc3ef272adc11220517278519adf8f53fd3056d0e68f0a6f891ba94e"}, - {file = "httptools-0.6.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0cf2372e98406efb42e93bfe10f2948e467edfd792b015f1b4ecd897903d3e8d"}, - {file = "httptools-0.6.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:678fcbae74477a17d103b7cae78b74800d795d702083867ce160fc202104d0da"}, - {file = "httptools-0.6.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:e0b281cf5a125c35f7f6722b65d8542d2e57331be573e9e88bc8b0115c4a7a81"}, - {file = "httptools-0.6.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:95658c342529bba4e1d3d2b1a874db16c7cca435e8827422154c9da76ac4e13a"}, - {file = "httptools-0.6.1-cp39-cp39-win_amd64.whl", hash = "sha256:7ebaec1bf683e4bf5e9fbb49b8cc36da482033596a415b3e4ebab5a4c0d7ec5e"}, - {file = "httptools-0.6.1.tar.gz", hash = "sha256:c6e26c30455600b95d94b1b836085138e82f177351454ee841c148f93a9bad5a"}, + {file = "httptools-0.6.4-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:3c73ce323711a6ffb0d247dcd5a550b8babf0f757e86a52558fe5b86d6fefcc0"}, + {file = "httptools-0.6.4-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:345c288418f0944a6fe67be8e6afa9262b18c7626c3ef3c28adc5eabc06a68da"}, + {file = "httptools-0.6.4-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:deee0e3343f98ee8047e9f4c5bc7cedbf69f5734454a94c38ee829fb2d5fa3c1"}, + {file = "httptools-0.6.4-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ca80b7485c76f768a3bc83ea58373f8db7b015551117375e4918e2aa77ea9b50"}, + {file = "httptools-0.6.4-cp310-cp310-musllinux_1_2_aarch64.whl", hash = "sha256:90d96a385fa941283ebd231464045187a31ad932ebfa541be8edf5b3c2328959"}, + {file = "httptools-0.6.4-cp310-cp310-musllinux_1_2_x86_64.whl", hash = "sha256:59e724f8b332319e2875efd360e61ac07f33b492889284a3e05e6d13746876f4"}, + {file = "httptools-0.6.4-cp310-cp310-win_amd64.whl", hash = "sha256:c26f313951f6e26147833fc923f78f95604bbec812a43e5ee37f26dc9e5a686c"}, + {file = "httptools-0.6.4-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:f47f8ed67cc0ff862b84a1189831d1d33c963fb3ce1ee0c65d3b0cbe7b711069"}, + {file = "httptools-0.6.4-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:0614154d5454c21b6410fdf5262b4a3ddb0f53f1e1721cfd59d55f32138c578a"}, + {file = "httptools-0.6.4-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:f8787367fbdfccae38e35abf7641dafc5310310a5987b689f4c32cc8cc3ee975"}, + {file = "httptools-0.6.4-cp311-cp311-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:40b0f7fe4fd38e6a507bdb751db0379df1e99120c65fbdc8ee6c1d044897a636"}, + {file = "httptools-0.6.4-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:40a5ec98d3f49904b9fe36827dcf1aadfef3b89e2bd05b0e35e94f97c2b14721"}, + {file = "httptools-0.6.4-cp311-cp311-musllinux_1_2_x86_64.whl", hash = "sha256:dacdd3d10ea1b4ca9df97a0a303cbacafc04b5cd375fa98732678151643d4988"}, + {file = "httptools-0.6.4-cp311-cp311-win_amd64.whl", hash = "sha256:288cd628406cc53f9a541cfaf06041b4c71d751856bab45e3702191f931ccd17"}, + {file = "httptools-0.6.4-cp312-cp312-macosx_10_13_universal2.whl", hash = "sha256:df017d6c780287d5c80601dafa31f17bddb170232d85c066604d8558683711a2"}, + {file = "httptools-0.6.4-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:85071a1e8c2d051b507161f6c3e26155b5c790e4e28d7f236422dbacc2a9cc44"}, + {file = "httptools-0.6.4-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:69422b7f458c5af875922cdb5bd586cc1f1033295aa9ff63ee196a87519ac8e1"}, + {file = "httptools-0.6.4-cp312-cp312-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:16e603a3bff50db08cd578d54f07032ca1631450ceb972c2f834c2b860c28ea2"}, + {file = "httptools-0.6.4-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:ec4f178901fa1834d4a060320d2f3abc5c9e39766953d038f1458cb885f47e81"}, + {file = "httptools-0.6.4-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:f9eb89ecf8b290f2e293325c646a211ff1c2493222798bb80a530c5e7502494f"}, + {file = "httptools-0.6.4-cp312-cp312-win_amd64.whl", hash = "sha256:db78cb9ca56b59b016e64b6031eda5653be0589dba2b1b43453f6e8b405a0970"}, + {file = "httptools-0.6.4-cp313-cp313-macosx_10_13_universal2.whl", hash = "sha256:ade273d7e767d5fae13fa637f4d53b6e961fb7fd93c7797562663f0171c26660"}, + {file = "httptools-0.6.4-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:856f4bc0478ae143bad54a4242fccb1f3f86a6e1be5548fecfd4102061b3a083"}, + {file = "httptools-0.6.4-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:322d20ea9cdd1fa98bd6a74b77e2ec5b818abdc3d36695ab402a0de8ef2865a3"}, + {file = "httptools-0.6.4-cp313-cp313-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4d87b29bd4486c0093fc64dea80231f7c7f7eb4dc70ae394d70a495ab8436071"}, + {file = "httptools-0.6.4-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:342dd6946aa6bda4b8f18c734576106b8a31f2fe31492881a9a160ec84ff4bd5"}, + {file = "httptools-0.6.4-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:4b36913ba52008249223042dca46e69967985fb4051951f94357ea681e1f5dc0"}, + {file = "httptools-0.6.4-cp313-cp313-win_amd64.whl", hash = "sha256:28908df1b9bb8187393d5b5db91435ccc9c8e891657f9cbb42a2541b44c82fc8"}, + {file = "httptools-0.6.4-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:85797e37e8eeaa5439d33e556662cc370e474445d5fab24dcadc65a8ffb04003"}, + {file = "httptools-0.6.4-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:db353d22843cf1028f43c3651581e4bb49374d85692a85f95f7b9a130e1b2cab"}, + {file = "httptools-0.6.4-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d1ffd262a73d7c28424252381a5b854c19d9de5f56f075445d33919a637e3547"}, + {file = "httptools-0.6.4-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:703c346571fa50d2e9856a37d7cd9435a25e7fd15e236c397bf224afaa355fe9"}, + {file = "httptools-0.6.4-cp39-cp39-musllinux_1_2_aarch64.whl", hash = "sha256:aafe0f1918ed07b67c1e838f950b1c1fabc683030477e60b335649b8020e1076"}, + {file = "httptools-0.6.4-cp39-cp39-musllinux_1_2_x86_64.whl", hash = "sha256:0e563e54979e97b6d13f1bbc05a96109923e76b901f786a5eae36e99c01237bd"}, + {file = "httptools-0.6.4-cp39-cp39-win_amd64.whl", hash = "sha256:b799de31416ecc589ad79dd85a0b2657a8fe39327944998dea368c1d4c9e55e6"}, + {file = "httptools-0.6.4.tar.gz", hash = "sha256:4e93eee4add6493b59a5c514da98c939b244fce4a0d8879cd3f466562f4b7d5c"}, ] [[package]] name = "httpx" -version = "0.27.2" +version = "0.28.1" requires_python = ">=3.8" summary = "The next generation HTTP client." groups = ["default"] @@ -624,11 +625,10 @@ dependencies = [ "certifi", "httpcore==1.*", "idna", - "sniffio", ] files = [ - {file = "httpx-0.27.2-py3-none-any.whl", hash = "sha256:7bb2708e112d8fdd7829cd4243970f0c223274051cb35ee80c03301ee29a3df0"}, - {file = "httpx-0.27.2.tar.gz", hash = "sha256:f7c2be1d2f3c3c3160d441802406b206c2b76f5947b11115e6df10c6c65e66c2"}, + {file = "httpx-0.28.1-py3-none-any.whl", hash = "sha256:d909fcccc110f8c7faf814ca82a9a4d816bc5a6dbfea25d6591d6985b8ba59ad"}, + {file = "httpx-0.28.1.tar.gz", hash = "sha256:75e98c5f16b0f35b567856f597f06ff2270a374470a5c2392242528e3e3e42fc"}, ] [[package]] @@ -701,19 +701,19 @@ files = [ [[package]] name = "json-repair" -version = "0.29.4" -requires_python = ">=3.8" +version = "0.32.0" +requires_python = ">=3.9" summary = "A package to repair broken json strings" groups = ["default"] files = [ - {file = "json_repair-0.29.4-py3-none-any.whl", hash = "sha256:2d7addfa01e3b4c295c4ebabd5f393127adae0d345616d3a2517df8260429dae"}, - {file = "json_repair-0.29.4.tar.gz", hash = "sha256:2921760e707ac0d0b63478402fd6ea3162d4191adf873b396becb31c47a1ac30"}, + {file = "json_repair-0.32.0-py3-none-any.whl", hash = "sha256:a06a83c62e75c69a58cda5902f5631adec567d6584413cf233b412b491cf8580"}, + {file = "json_repair-0.32.0.tar.gz", hash = "sha256:eed776fb24dbcce5bcd200f3c254a7d70fda40405c31c97f52a5ca8cfb7cf3e4"}, ] [[package]] name = "loguru" -version = "0.7.2" -requires_python = ">=3.5" +version = "0.7.3" +requires_python = "<4.0,>=3.5" summary = "Python logging made (stupidly) simple" groups = ["default"] dependencies = [ @@ -722,8 +722,8 @@ dependencies = [ "win32-setctime>=1.0.0; sys_platform == \"win32\"", ] files = [ - {file = "loguru-0.7.2-py3-none-any.whl", hash = "sha256:003d71e3d3ed35f0f8984898359d65b79e5b21943f78af86aa5491210429b8eb"}, - {file = "loguru-0.7.2.tar.gz", hash = "sha256:e671a53522515f34fd406340ee968cb9ecafbc4b36c679da03c18fd8d0bd51ac"}, + {file = "loguru-0.7.3-py3-none-any.whl", hash = "sha256:31a33c10c8e1e10422bfd431aeb5d351c7cf7fa671e3c4df004162264b28220c"}, + {file = "loguru-0.7.3.tar.gz", hash = "sha256:19480589e77d47b8d85b2c827ad95d49bf31b0dcde16593892eb51dd18706eb6"}, ] [[package]] @@ -901,81 +901,86 @@ files = [ [[package]] name = "pillow" -version = "10.4.0" -requires_python = ">=3.8" +version = "11.0.0" +requires_python = ">=3.9" summary = "Python Imaging Library (Fork)" groups = ["default"] files = [ - {file = "pillow-10.4.0-cp310-cp310-macosx_10_10_x86_64.whl", hash = "sha256:4d9667937cfa347525b319ae34375c37b9ee6b525440f3ef48542fcf66f2731e"}, - {file = "pillow-10.4.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:543f3dc61c18dafb755773efc89aae60d06b6596a63914107f75459cf984164d"}, - {file = "pillow-10.4.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7928ecbf1ece13956b95d9cbcfc77137652b02763ba384d9ab508099a2eca856"}, - {file = "pillow-10.4.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e4d49b85c4348ea0b31ea63bc75a9f3857869174e2bf17e7aba02945cd218e6f"}, - {file = "pillow-10.4.0-cp310-cp310-manylinux_2_28_aarch64.whl", hash = "sha256:6c762a5b0997f5659a5ef2266abc1d8851ad7749ad9a6a5506eb23d314e4f46b"}, - {file = "pillow-10.4.0-cp310-cp310-manylinux_2_28_x86_64.whl", hash = "sha256:a985e028fc183bf12a77a8bbf36318db4238a3ded7fa9df1b9a133f1cb79f8fc"}, - {file = "pillow-10.4.0-cp310-cp310-musllinux_1_2_aarch64.whl", hash = "sha256:812f7342b0eee081eaec84d91423d1b4650bb9828eb53d8511bcef8ce5aecf1e"}, - {file = "pillow-10.4.0-cp310-cp310-musllinux_1_2_x86_64.whl", hash = "sha256:ac1452d2fbe4978c2eec89fb5a23b8387aba707ac72810d9490118817d9c0b46"}, - {file = "pillow-10.4.0-cp310-cp310-win32.whl", hash = "sha256:bcd5e41a859bf2e84fdc42f4edb7d9aba0a13d29a2abadccafad99de3feff984"}, - {file = "pillow-10.4.0-cp310-cp310-win_amd64.whl", hash = "sha256:ecd85a8d3e79cd7158dec1c9e5808e821feea088e2f69a974db5edf84dc53141"}, - {file = "pillow-10.4.0-cp310-cp310-win_arm64.whl", hash = "sha256:ff337c552345e95702c5fde3158acb0625111017d0e5f24bf3acdb9cc16b90d1"}, - {file = "pillow-10.4.0-cp311-cp311-macosx_10_10_x86_64.whl", hash = "sha256:0a9ec697746f268507404647e531e92889890a087e03681a3606d9b920fbee3c"}, - {file = "pillow-10.4.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:dfe91cb65544a1321e631e696759491ae04a2ea11d36715eca01ce07284738be"}, - {file = "pillow-10.4.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5dc6761a6efc781e6a1544206f22c80c3af4c8cf461206d46a1e6006e4429ff3"}, - {file = "pillow-10.4.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5e84b6cc6a4a3d76c153a6b19270b3526a5a8ed6b09501d3af891daa2a9de7d6"}, - {file = "pillow-10.4.0-cp311-cp311-manylinux_2_28_aarch64.whl", hash = "sha256:bbc527b519bd3aa9d7f429d152fea69f9ad37c95f0b02aebddff592688998abe"}, - {file = "pillow-10.4.0-cp311-cp311-manylinux_2_28_x86_64.whl", hash = "sha256:76a911dfe51a36041f2e756b00f96ed84677cdeb75d25c767f296c1c1eda1319"}, - {file = "pillow-10.4.0-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:59291fb29317122398786c2d44427bbd1a6d7ff54017075b22be9d21aa59bd8d"}, - {file = "pillow-10.4.0-cp311-cp311-musllinux_1_2_x86_64.whl", hash = "sha256:416d3a5d0e8cfe4f27f574362435bc9bae57f679a7158e0096ad2beb427b8696"}, - {file = "pillow-10.4.0-cp311-cp311-win32.whl", hash = "sha256:7086cc1d5eebb91ad24ded9f58bec6c688e9f0ed7eb3dbbf1e4800280a896496"}, - {file = "pillow-10.4.0-cp311-cp311-win_amd64.whl", hash = "sha256:cbed61494057c0f83b83eb3a310f0bf774b09513307c434d4366ed64f4128a91"}, - {file = "pillow-10.4.0-cp311-cp311-win_arm64.whl", hash = "sha256:f5f0c3e969c8f12dd2bb7e0b15d5c468b51e5017e01e2e867335c81903046a22"}, - {file = "pillow-10.4.0-cp312-cp312-macosx_10_10_x86_64.whl", hash = "sha256:673655af3eadf4df6b5457033f086e90299fdd7a47983a13827acf7459c15d94"}, - {file = "pillow-10.4.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:866b6942a92f56300012f5fbac71f2d610312ee65e22f1aa2609e491284e5597"}, - {file = "pillow-10.4.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:29dbdc4207642ea6aad70fbde1a9338753d33fb23ed6956e706936706f52dd80"}, - {file = "pillow-10.4.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bf2342ac639c4cf38799a44950bbc2dfcb685f052b9e262f446482afaf4bffca"}, - {file = "pillow-10.4.0-cp312-cp312-manylinux_2_28_aarch64.whl", hash = "sha256:f5b92f4d70791b4a67157321c4e8225d60b119c5cc9aee8ecf153aace4aad4ef"}, - {file = "pillow-10.4.0-cp312-cp312-manylinux_2_28_x86_64.whl", hash = "sha256:86dcb5a1eb778d8b25659d5e4341269e8590ad6b4e8b44d9f4b07f8d136c414a"}, - {file = "pillow-10.4.0-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:780c072c2e11c9b2c7ca37f9a2ee8ba66f44367ac3e5c7832afcfe5104fd6d1b"}, - {file = "pillow-10.4.0-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:37fb69d905be665f68f28a8bba3c6d3223c8efe1edf14cc4cfa06c241f8c81d9"}, - {file = "pillow-10.4.0-cp312-cp312-win32.whl", hash = "sha256:7dfecdbad5c301d7b5bde160150b4db4c659cee2b69589705b6f8a0c509d9f42"}, - {file = "pillow-10.4.0-cp312-cp312-win_amd64.whl", hash = "sha256:1d846aea995ad352d4bdcc847535bd56e0fd88d36829d2c90be880ef1ee4668a"}, - {file = "pillow-10.4.0-cp312-cp312-win_arm64.whl", hash = "sha256:e553cad5179a66ba15bb18b353a19020e73a7921296a7979c4a2b7f6a5cd57f9"}, - {file = "pillow-10.4.0-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:8bc1a764ed8c957a2e9cacf97c8b2b053b70307cf2996aafd70e91a082e70df3"}, - {file = "pillow-10.4.0-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:6209bb41dc692ddfee4942517c19ee81b86c864b626dbfca272ec0f7cff5d9fb"}, - {file = "pillow-10.4.0-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:bee197b30783295d2eb680b311af15a20a8b24024a19c3a26431ff83eb8d1f70"}, - {file = "pillow-10.4.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1ef61f5dd14c300786318482456481463b9d6b91ebe5ef12f405afbba77ed0be"}, - {file = "pillow-10.4.0-cp313-cp313-manylinux_2_28_aarch64.whl", hash = "sha256:297e388da6e248c98bc4a02e018966af0c5f92dfacf5a5ca22fa01cb3179bca0"}, - {file = "pillow-10.4.0-cp313-cp313-manylinux_2_28_x86_64.whl", hash = "sha256:e4db64794ccdf6cb83a59d73405f63adbe2a1887012e308828596100a0b2f6cc"}, - {file = "pillow-10.4.0-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:bd2880a07482090a3bcb01f4265f1936a903d70bc740bfcb1fd4e8a2ffe5cf5a"}, - {file = "pillow-10.4.0-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:4b35b21b819ac1dbd1233317adeecd63495f6babf21b7b2512d244ff6c6ce309"}, - {file = "pillow-10.4.0-cp313-cp313-win32.whl", hash = "sha256:551d3fd6e9dc15e4c1eb6fc4ba2b39c0c7933fa113b220057a34f4bb3268a060"}, - {file = "pillow-10.4.0-cp313-cp313-win_amd64.whl", hash = "sha256:030abdbe43ee02e0de642aee345efa443740aa4d828bfe8e2eb11922ea6a21ea"}, - {file = "pillow-10.4.0-cp313-cp313-win_arm64.whl", hash = "sha256:5b001114dd152cfd6b23befeb28d7aee43553e2402c9f159807bf55f33af8a8d"}, - {file = "pillow-10.4.0-cp39-cp39-macosx_10_10_x86_64.whl", hash = "sha256:0ae24a547e8b711ccaaf99c9ae3cd975470e1a30caa80a6aaee9a2f19c05701d"}, - {file = "pillow-10.4.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:298478fe4f77a4408895605f3482b6cc6222c018b2ce565c2b6b9c354ac3229b"}, - {file = "pillow-10.4.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:134ace6dc392116566980ee7436477d844520a26a4b1bd4053f6f47d096997fd"}, - {file = "pillow-10.4.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:930044bb7679ab003b14023138b50181899da3f25de50e9dbee23b61b4de2126"}, - {file = "pillow-10.4.0-cp39-cp39-manylinux_2_28_aarch64.whl", hash = "sha256:c76e5786951e72ed3686e122d14c5d7012f16c8303a674d18cdcd6d89557fc5b"}, - {file = "pillow-10.4.0-cp39-cp39-manylinux_2_28_x86_64.whl", hash = "sha256:b2724fdb354a868ddf9a880cb84d102da914e99119211ef7ecbdc613b8c96b3c"}, - {file = "pillow-10.4.0-cp39-cp39-musllinux_1_2_aarch64.whl", hash = "sha256:dbc6ae66518ab3c5847659e9988c3b60dc94ffb48ef9168656e0019a93dbf8a1"}, - {file = "pillow-10.4.0-cp39-cp39-musllinux_1_2_x86_64.whl", hash = "sha256:06b2f7898047ae93fad74467ec3d28fe84f7831370e3c258afa533f81ef7f3df"}, - {file = "pillow-10.4.0-cp39-cp39-win32.whl", hash = "sha256:7970285ab628a3779aecc35823296a7869f889b8329c16ad5a71e4901a3dc4ef"}, - {file = "pillow-10.4.0-cp39-cp39-win_amd64.whl", hash = "sha256:961a7293b2457b405967af9c77dcaa43cc1a8cd50d23c532e62d48ab6cdd56f5"}, - {file = "pillow-10.4.0-cp39-cp39-win_arm64.whl", hash = "sha256:32cda9e3d601a52baccb2856b8ea1fc213c90b340c542dcef77140dfa3278a9e"}, - {file = "pillow-10.4.0-pp310-pypy310_pp73-macosx_10_15_x86_64.whl", hash = "sha256:5b4815f2e65b30f5fbae9dfffa8636d992d49705723fe86a3661806e069352d4"}, - {file = "pillow-10.4.0-pp310-pypy310_pp73-macosx_11_0_arm64.whl", hash = "sha256:8f0aef4ef59694b12cadee839e2ba6afeab89c0f39a3adc02ed51d109117b8da"}, - {file = "pillow-10.4.0-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9f4727572e2918acaa9077c919cbbeb73bd2b3ebcfe033b72f858fc9fbef0026"}, - {file = "pillow-10.4.0-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ff25afb18123cea58a591ea0244b92eb1e61a1fd497bf6d6384f09bc3262ec3e"}, - {file = "pillow-10.4.0-pp310-pypy310_pp73-manylinux_2_28_aarch64.whl", hash = "sha256:dc3e2db6ba09ffd7d02ae9141cfa0ae23393ee7687248d46a7507b75d610f4f5"}, - {file = "pillow-10.4.0-pp310-pypy310_pp73-manylinux_2_28_x86_64.whl", hash = "sha256:02a2be69f9c9b8c1e97cf2713e789d4e398c751ecfd9967c18d0ce304efbf885"}, - {file = "pillow-10.4.0-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:0755ffd4a0c6f267cccbae2e9903d95477ca2f77c4fcf3a3a09570001856c8a5"}, - {file = "pillow-10.4.0-pp39-pypy39_pp73-macosx_10_15_x86_64.whl", hash = "sha256:a02364621fe369e06200d4a16558e056fe2805d3468350df3aef21e00d26214b"}, - {file = "pillow-10.4.0-pp39-pypy39_pp73-macosx_11_0_arm64.whl", hash = "sha256:1b5dea9831a90e9d0721ec417a80d4cbd7022093ac38a568db2dd78363b00908"}, - {file = "pillow-10.4.0-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9b885f89040bb8c4a1573566bbb2f44f5c505ef6e74cec7ab9068c900047f04b"}, - {file = "pillow-10.4.0-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:87dd88ded2e6d74d31e1e0a99a726a6765cda32d00ba72dc37f0651f306daaa8"}, - {file = "pillow-10.4.0-pp39-pypy39_pp73-manylinux_2_28_aarch64.whl", hash = "sha256:2db98790afc70118bd0255c2eeb465e9767ecf1f3c25f9a1abb8ffc8cfd1fe0a"}, - {file = "pillow-10.4.0-pp39-pypy39_pp73-manylinux_2_28_x86_64.whl", hash = "sha256:f7baece4ce06bade126fb84b8af1c33439a76d8a6fd818970215e0560ca28c27"}, - {file = "pillow-10.4.0-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:cfdd747216947628af7b259d274771d84db2268ca062dd5faf373639d00113a3"}, - {file = "pillow-10.4.0.tar.gz", hash = "sha256:166c1cd4d24309b30d61f79f4a9114b7b2313d7450912277855ff5dfd7cd4a06"}, + {file = "pillow-11.0.0-cp310-cp310-macosx_10_10_x86_64.whl", hash = "sha256:6619654954dc4936fcff82db8eb6401d3159ec6be81e33c6000dfd76ae189947"}, + {file = "pillow-11.0.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:b3c5ac4bed7519088103d9450a1107f76308ecf91d6dabc8a33a2fcfb18d0fba"}, + {file = "pillow-11.0.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a65149d8ada1055029fcb665452b2814fe7d7082fcb0c5bed6db851cb69b2086"}, + {file = "pillow-11.0.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:88a58d8ac0cc0e7f3a014509f0455248a76629ca9b604eca7dc5927cc593c5e9"}, + {file = "pillow-11.0.0-cp310-cp310-manylinux_2_28_aarch64.whl", hash = "sha256:c26845094b1af3c91852745ae78e3ea47abf3dbcd1cf962f16b9a5fbe3ee8488"}, + {file = "pillow-11.0.0-cp310-cp310-manylinux_2_28_x86_64.whl", hash = "sha256:1a61b54f87ab5786b8479f81c4b11f4d61702830354520837f8cc791ebba0f5f"}, + {file = "pillow-11.0.0-cp310-cp310-musllinux_1_2_aarch64.whl", hash = "sha256:674629ff60030d144b7bca2b8330225a9b11c482ed408813924619c6f302fdbb"}, + {file = "pillow-11.0.0-cp310-cp310-musllinux_1_2_x86_64.whl", hash = "sha256:598b4e238f13276e0008299bd2482003f48158e2b11826862b1eb2ad7c768b97"}, + {file = "pillow-11.0.0-cp310-cp310-win32.whl", hash = "sha256:9a0f748eaa434a41fccf8e1ee7a3eed68af1b690e75328fd7a60af123c193b50"}, + {file = "pillow-11.0.0-cp310-cp310-win_amd64.whl", hash = "sha256:a5629742881bcbc1f42e840af185fd4d83a5edeb96475a575f4da50d6ede337c"}, + {file = "pillow-11.0.0-cp310-cp310-win_arm64.whl", hash = "sha256:ee217c198f2e41f184f3869f3e485557296d505b5195c513b2bfe0062dc537f1"}, + {file = "pillow-11.0.0-cp311-cp311-macosx_10_10_x86_64.whl", hash = "sha256:1c1d72714f429a521d8d2d018badc42414c3077eb187a59579f28e4270b4b0fc"}, + {file = "pillow-11.0.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:499c3a1b0d6fc8213519e193796eb1a86a1be4b1877d678b30f83fd979811d1a"}, + {file = "pillow-11.0.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c8b2351c85d855293a299038e1f89db92a2f35e8d2f783489c6f0b2b5f3fe8a3"}, + {file = "pillow-11.0.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6f4dba50cfa56f910241eb7f883c20f1e7b1d8f7d91c750cd0b318bad443f4d5"}, + {file = "pillow-11.0.0-cp311-cp311-manylinux_2_28_aarch64.whl", hash = "sha256:5ddbfd761ee00c12ee1be86c9c0683ecf5bb14c9772ddbd782085779a63dd55b"}, + {file = "pillow-11.0.0-cp311-cp311-manylinux_2_28_x86_64.whl", hash = "sha256:45c566eb10b8967d71bf1ab8e4a525e5a93519e29ea071459ce517f6b903d7fa"}, + {file = "pillow-11.0.0-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:b4fd7bd29610a83a8c9b564d457cf5bd92b4e11e79a4ee4716a63c959699b306"}, + {file = "pillow-11.0.0-cp311-cp311-musllinux_1_2_x86_64.whl", hash = "sha256:cb929ca942d0ec4fac404cbf520ee6cac37bf35be479b970c4ffadf2b6a1cad9"}, + {file = "pillow-11.0.0-cp311-cp311-win32.whl", hash = "sha256:006bcdd307cc47ba43e924099a038cbf9591062e6c50e570819743f5607404f5"}, + {file = "pillow-11.0.0-cp311-cp311-win_amd64.whl", hash = "sha256:52a2d8323a465f84faaba5236567d212c3668f2ab53e1c74c15583cf507a0291"}, + {file = "pillow-11.0.0-cp311-cp311-win_arm64.whl", hash = "sha256:16095692a253047fe3ec028e951fa4221a1f3ed3d80c397e83541a3037ff67c9"}, + {file = "pillow-11.0.0-cp312-cp312-macosx_10_13_x86_64.whl", hash = "sha256:d2c0a187a92a1cb5ef2c8ed5412dd8d4334272617f532d4ad4de31e0495bd923"}, + {file = "pillow-11.0.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:084a07ef0821cfe4858fe86652fffac8e187b6ae677e9906e192aafcc1b69903"}, + {file = "pillow-11.0.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8069c5179902dcdce0be9bfc8235347fdbac249d23bd90514b7a47a72d9fecf4"}, + {file = "pillow-11.0.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f02541ef64077f22bf4924f225c0fd1248c168f86e4b7abdedd87d6ebaceab0f"}, + {file = "pillow-11.0.0-cp312-cp312-manylinux_2_28_aarch64.whl", hash = "sha256:fcb4621042ac4b7865c179bb972ed0da0218a076dc1820ffc48b1d74c1e37fe9"}, + {file = "pillow-11.0.0-cp312-cp312-manylinux_2_28_x86_64.whl", hash = "sha256:00177a63030d612148e659b55ba99527803288cea7c75fb05766ab7981a8c1b7"}, + {file = "pillow-11.0.0-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:8853a3bf12afddfdf15f57c4b02d7ded92c7a75a5d7331d19f4f9572a89c17e6"}, + {file = "pillow-11.0.0-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:3107c66e43bda25359d5ef446f59c497de2b5ed4c7fdba0894f8d6cf3822dafc"}, + {file = "pillow-11.0.0-cp312-cp312-win32.whl", hash = "sha256:86510e3f5eca0ab87429dd77fafc04693195eec7fd6a137c389c3eeb4cfb77c6"}, + {file = "pillow-11.0.0-cp312-cp312-win_amd64.whl", hash = "sha256:8ec4a89295cd6cd4d1058a5e6aec6bf51e0eaaf9714774e1bfac7cfc9051db47"}, + {file = "pillow-11.0.0-cp312-cp312-win_arm64.whl", hash = "sha256:27a7860107500d813fcd203b4ea19b04babe79448268403172782754870dac25"}, + {file = "pillow-11.0.0-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:bcd1fb5bb7b07f64c15618c89efcc2cfa3e95f0e3bcdbaf4642509de1942a699"}, + {file = "pillow-11.0.0-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:0e038b0745997c7dcaae350d35859c9715c71e92ffb7e0f4a8e8a16732150f38"}, + {file = "pillow-11.0.0-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0ae08bd8ffc41aebf578c2af2f9d8749d91f448b3bfd41d7d9ff573d74f2a6b2"}, + {file = "pillow-11.0.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d69bfd8ec3219ae71bcde1f942b728903cad25fafe3100ba2258b973bd2bc1b2"}, + {file = "pillow-11.0.0-cp313-cp313-manylinux_2_28_aarch64.whl", hash = "sha256:61b887f9ddba63ddf62fd02a3ba7add935d053b6dd7d58998c630e6dbade8527"}, + {file = "pillow-11.0.0-cp313-cp313-manylinux_2_28_x86_64.whl", hash = "sha256:c6a660307ca9d4867caa8d9ca2c2658ab685de83792d1876274991adec7b93fa"}, + {file = "pillow-11.0.0-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:73e3a0200cdda995c7e43dd47436c1548f87a30bb27fb871f352a22ab8dcf45f"}, + {file = "pillow-11.0.0-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:fba162b8872d30fea8c52b258a542c5dfd7b235fb5cb352240c8d63b414013eb"}, + {file = "pillow-11.0.0-cp313-cp313-win32.whl", hash = "sha256:f1b82c27e89fffc6da125d5eb0ca6e68017faf5efc078128cfaa42cf5cb38798"}, + {file = "pillow-11.0.0-cp313-cp313-win_amd64.whl", hash = "sha256:8ba470552b48e5835f1d23ecb936bb7f71d206f9dfeee64245f30c3270b994de"}, + {file = "pillow-11.0.0-cp313-cp313-win_arm64.whl", hash = "sha256:846e193e103b41e984ac921b335df59195356ce3f71dcfd155aa79c603873b84"}, + {file = "pillow-11.0.0-cp313-cp313t-macosx_10_13_x86_64.whl", hash = "sha256:4ad70c4214f67d7466bea6a08061eba35c01b1b89eaa098040a35272a8efb22b"}, + {file = "pillow-11.0.0-cp313-cp313t-macosx_11_0_arm64.whl", hash = "sha256:6ec0d5af64f2e3d64a165f490d96368bb5dea8b8f9ad04487f9ab60dc4bb6003"}, + {file = "pillow-11.0.0-cp313-cp313t-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:c809a70e43c7977c4a42aefd62f0131823ebf7dd73556fa5d5950f5b354087e2"}, + {file = "pillow-11.0.0-cp313-cp313t-manylinux_2_28_x86_64.whl", hash = "sha256:4b60c9520f7207aaf2e1d94de026682fc227806c6e1f55bba7606d1c94dd623a"}, + {file = "pillow-11.0.0-cp313-cp313t-musllinux_1_2_x86_64.whl", hash = "sha256:1e2688958a840c822279fda0086fec1fdab2f95bf2b717b66871c4ad9859d7e8"}, + {file = "pillow-11.0.0-cp313-cp313t-win32.whl", hash = "sha256:607bbe123c74e272e381a8d1957083a9463401f7bd01287f50521ecb05a313f8"}, + {file = "pillow-11.0.0-cp313-cp313t-win_amd64.whl", hash = "sha256:5c39ed17edea3bc69c743a8dd3e9853b7509625c2462532e62baa0732163a904"}, + {file = "pillow-11.0.0-cp313-cp313t-win_arm64.whl", hash = "sha256:75acbbeb05b86bc53cbe7b7e6fe00fbcf82ad7c684b3ad82e3d711da9ba287d3"}, + {file = "pillow-11.0.0-cp39-cp39-macosx_10_10_x86_64.whl", hash = "sha256:2e46773dc9f35a1dd28bd6981332fd7f27bec001a918a72a79b4133cf5291dba"}, + {file = "pillow-11.0.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:2679d2258b7f1192b378e2893a8a0a0ca472234d4c2c0e6bdd3380e8dfa21b6a"}, + {file = "pillow-11.0.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:eda2616eb2313cbb3eebbe51f19362eb434b18e3bb599466a1ffa76a033fb916"}, + {file = "pillow-11.0.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:20ec184af98a121fb2da42642dea8a29ec80fc3efbaefb86d8fdd2606619045d"}, + {file = "pillow-11.0.0-cp39-cp39-manylinux_2_28_aarch64.whl", hash = "sha256:8594f42df584e5b4bb9281799698403f7af489fba84c34d53d1c4bfb71b7c4e7"}, + {file = "pillow-11.0.0-cp39-cp39-manylinux_2_28_x86_64.whl", hash = "sha256:c12b5ae868897c7338519c03049a806af85b9b8c237b7d675b8c5e089e4a618e"}, + {file = "pillow-11.0.0-cp39-cp39-musllinux_1_2_aarch64.whl", hash = "sha256:70fbbdacd1d271b77b7721fe3cdd2d537bbbd75d29e6300c672ec6bb38d9672f"}, + {file = "pillow-11.0.0-cp39-cp39-musllinux_1_2_x86_64.whl", hash = "sha256:5178952973e588b3f1360868847334e9e3bf49d19e169bbbdfaf8398002419ae"}, + {file = "pillow-11.0.0-cp39-cp39-win32.whl", hash = "sha256:8c676b587da5673d3c75bd67dd2a8cdfeb282ca38a30f37950511766b26858c4"}, + {file = "pillow-11.0.0-cp39-cp39-win_amd64.whl", hash = "sha256:94f3e1780abb45062287b4614a5bc0874519c86a777d4a7ad34978e86428b8dd"}, + {file = "pillow-11.0.0-cp39-cp39-win_arm64.whl", hash = "sha256:290f2cc809f9da7d6d622550bbf4c1e57518212da51b6a30fe8e0a270a5b78bd"}, + {file = "pillow-11.0.0-pp310-pypy310_pp73-macosx_10_15_x86_64.whl", hash = "sha256:1187739620f2b365de756ce086fdb3604573337cc28a0d3ac4a01ab6b2d2a6d2"}, + {file = "pillow-11.0.0-pp310-pypy310_pp73-macosx_11_0_arm64.whl", hash = "sha256:fbbcb7b57dc9c794843e3d1258c0fbf0f48656d46ffe9e09b63bbd6e8cd5d0a2"}, + {file = "pillow-11.0.0-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5d203af30149ae339ad1b4f710d9844ed8796e97fda23ffbc4cc472968a47d0b"}, + {file = "pillow-11.0.0-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:21a0d3b115009ebb8ac3d2ebec5c2982cc693da935f4ab7bb5c8ebe2f47d36f2"}, + {file = "pillow-11.0.0-pp310-pypy310_pp73-manylinux_2_28_aarch64.whl", hash = "sha256:73853108f56df97baf2bb8b522f3578221e56f646ba345a372c78326710d3830"}, + {file = "pillow-11.0.0-pp310-pypy310_pp73-manylinux_2_28_x86_64.whl", hash = "sha256:e58876c91f97b0952eb766123bfef372792ab3f4e3e1f1a2267834c2ab131734"}, + {file = "pillow-11.0.0-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:224aaa38177597bb179f3ec87eeefcce8e4f85e608025e9cfac60de237ba6316"}, + {file = "pillow-11.0.0-pp39-pypy39_pp73-macosx_11_0_arm64.whl", hash = "sha256:5bd2d3bdb846d757055910f0a59792d33b555800813c3b39ada1829c372ccb06"}, + {file = "pillow-11.0.0-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:375b8dd15a1f5d2feafff536d47e22f69625c1aa92f12b339ec0b2ca40263273"}, + {file = "pillow-11.0.0-pp39-pypy39_pp73-manylinux_2_28_x86_64.whl", hash = "sha256:daffdf51ee5db69a82dd127eabecce20729e21f7a3680cf7cbb23f0829189790"}, + {file = "pillow-11.0.0-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:7326a1787e3c7b0429659e0a944725e1b03eeaa10edd945a86dead1913383944"}, + {file = "pillow-11.0.0.tar.gz", hash = "sha256:72bacbaf24ac003fea9bff9837d1eedb6088758d41e100c1552930151f677739"}, ] [[package]] @@ -1002,7 +1007,7 @@ files = [ [[package]] name = "pre-commit" -version = "3.8.0" +version = "4.0.1" requires_python = ">=3.9" summary = "A framework for managing and maintaining multi-language pre-commit hooks." groups = ["dev"] @@ -1014,8 +1019,8 @@ dependencies = [ "virtualenv>=20.10.0", ] files = [ - {file = "pre_commit-3.8.0-py2.py3-none-any.whl", hash = "sha256:9a90a53bf82fdd8778d58085faf8d83df56e40dfe18f45b19446e26bf1b3a63f"}, - {file = "pre_commit-3.8.0.tar.gz", hash = "sha256:8bb6494d4a20423842e198980c9ecf9f96607a07ea29549e180eef9ae80fe7af"}, + {file = "pre_commit-4.0.1-py2.py3-none-any.whl", hash = "sha256:efde913840816312445dc98787724647c65473daefe420785f885e8ed9a06878"}, + {file = "pre_commit-4.0.1.tar.gz", hash = "sha256:80905ac375958c0444c65e9cebebd948b3cdb518f335a091a670a89d652139d2"}, ] [[package]] @@ -1031,25 +1036,23 @@ files = [ [[package]] name = "pydantic" -version = "2.9.0" +version = "2.10.4" requires_python = ">=3.8" summary = "Data validation using Python type hints" groups = ["default"] dependencies = [ - "annotated-types>=0.4.0", - "pydantic-core==2.23.2", - "typing-extensions>=4.12.2; python_version >= \"3.13\"", - "typing-extensions>=4.6.1; python_version < \"3.13\"", - "tzdata; python_version >= \"3.9\"", + "annotated-types>=0.6.0", + "pydantic-core==2.27.2", + "typing-extensions>=4.12.2", ] files = [ - {file = "pydantic-2.9.0-py3-none-any.whl", hash = "sha256:f66a7073abd93214a20c5f7b32d56843137a7a2e70d02111f3be287035c45370"}, - {file = "pydantic-2.9.0.tar.gz", hash = "sha256:c7a8a9fdf7d100afa49647eae340e2d23efa382466a8d177efcd1381e9be5598"}, + {file = "pydantic-2.10.4-py3-none-any.whl", hash = "sha256:597e135ea68be3a37552fb524bc7d0d66dcf93d395acd93a00682f1efcb8ee3d"}, + {file = "pydantic-2.10.4.tar.gz", hash = "sha256:82f12e9723da6de4fe2ba888b5971157b3be7ad914267dea8f05f82b28254f06"}, ] [[package]] name = "pydantic-core" -version = "2.23.2" +version = "2.27.2" requires_python = ">=3.8" summary = "Core functionality for Pydantic validation and serialization" groups = ["default"] @@ -1057,88 +1060,98 @@ dependencies = [ "typing-extensions!=4.7.0,>=4.6.0", ] files = [ - {file = "pydantic_core-2.23.2-cp310-cp310-macosx_10_12_x86_64.whl", hash = "sha256:7d0324a35ab436c9d768753cbc3c47a865a2cbc0757066cb864747baa61f6ece"}, - {file = "pydantic_core-2.23.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:276ae78153a94b664e700ac362587c73b84399bd1145e135287513442e7dfbc7"}, - {file = "pydantic_core-2.23.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:964c7aa318da542cdcc60d4a648377ffe1a2ef0eb1e996026c7f74507b720a78"}, - {file = "pydantic_core-2.23.2-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:1cf842265a3a820ebc6388b963ead065f5ce8f2068ac4e1c713ef77a67b71f7c"}, - {file = "pydantic_core-2.23.2-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:ae90b9e50fe1bd115b24785e962b51130340408156d34d67b5f8f3fa6540938e"}, - {file = "pydantic_core-2.23.2-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:8ae65fdfb8a841556b52935dfd4c3f79132dc5253b12c0061b96415208f4d622"}, - {file = "pydantic_core-2.23.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5c8aa40f6ca803f95b1c1c5aeaee6237b9e879e4dfb46ad713229a63651a95fb"}, - {file = "pydantic_core-2.23.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:c53100c8ee5a1e102766abde2158077d8c374bee0639201f11d3032e3555dfbc"}, - {file = "pydantic_core-2.23.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:d6b9dd6aa03c812017411734e496c44fef29b43dba1e3dd1fa7361bbacfc1354"}, - {file = "pydantic_core-2.23.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:b18cf68255a476b927910c6873d9ed00da692bb293c5b10b282bd48a0afe3ae2"}, - {file = "pydantic_core-2.23.2-cp310-none-win32.whl", hash = "sha256:e460475719721d59cd54a350c1f71c797c763212c836bf48585478c5514d2854"}, - {file = "pydantic_core-2.23.2-cp310-none-win_amd64.whl", hash = "sha256:5f3cf3721eaf8741cffaf092487f1ca80831202ce91672776b02b875580e174a"}, - {file = "pydantic_core-2.23.2-cp311-cp311-macosx_10_12_x86_64.whl", hash = "sha256:7ce8e26b86a91e305858e018afc7a6e932f17428b1eaa60154bd1f7ee888b5f8"}, - {file = "pydantic_core-2.23.2-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:7e9b24cca4037a561422bf5dc52b38d390fb61f7bfff64053ce1b72f6938e6b2"}, - {file = "pydantic_core-2.23.2-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:753294d42fb072aa1775bfe1a2ba1012427376718fa4c72de52005a3d2a22178"}, - {file = "pydantic_core-2.23.2-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:257d6a410a0d8aeb50b4283dea39bb79b14303e0fab0f2b9d617701331ed1515"}, - {file = "pydantic_core-2.23.2-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c8319e0bd6a7b45ad76166cc3d5d6a36c97d0c82a196f478c3ee5346566eebfd"}, - {file = "pydantic_core-2.23.2-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:7a05c0240f6c711eb381ac392de987ee974fa9336071fb697768dfdb151345ce"}, - {file = "pydantic_core-2.23.2-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8d5b0ff3218858859910295df6953d7bafac3a48d5cd18f4e3ed9999efd2245f"}, - {file = "pydantic_core-2.23.2-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:96ef39add33ff58cd4c112cbac076726b96b98bb8f1e7f7595288dcfb2f10b57"}, - {file = "pydantic_core-2.23.2-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:0102e49ac7d2df3379ef8d658d3bc59d3d769b0bdb17da189b75efa861fc07b4"}, - {file = "pydantic_core-2.23.2-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:a6612c2a844043e4d10a8324c54cdff0042c558eef30bd705770793d70b224aa"}, - {file = "pydantic_core-2.23.2-cp311-none-win32.whl", hash = "sha256:caffda619099cfd4f63d48462f6aadbecee3ad9603b4b88b60cb821c1b258576"}, - {file = "pydantic_core-2.23.2-cp311-none-win_amd64.whl", hash = "sha256:6f80fba4af0cb1d2344869d56430e304a51396b70d46b91a55ed4959993c0589"}, - {file = "pydantic_core-2.23.2-cp312-cp312-macosx_10_12_x86_64.whl", hash = "sha256:4c83c64d05ffbbe12d4e8498ab72bdb05bcc1026340a4a597dc647a13c1605ec"}, - {file = "pydantic_core-2.23.2-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:6294907eaaccf71c076abdd1c7954e272efa39bb043161b4b8aa1cd76a16ce43"}, - {file = "pydantic_core-2.23.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4a801c5e1e13272e0909c520708122496647d1279d252c9e6e07dac216accc41"}, - {file = "pydantic_core-2.23.2-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:cc0c316fba3ce72ac3ab7902a888b9dc4979162d320823679da270c2d9ad0cad"}, - {file = "pydantic_core-2.23.2-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:6b06c5d4e8701ac2ba99a2ef835e4e1b187d41095a9c619c5b185c9068ed2a49"}, - {file = "pydantic_core-2.23.2-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:82764c0bd697159fe9947ad59b6db6d7329e88505c8f98990eb07e84cc0a5d81"}, - {file = "pydantic_core-2.23.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2b1a195efd347ede8bcf723e932300292eb13a9d2a3c1f84eb8f37cbbc905b7f"}, - {file = "pydantic_core-2.23.2-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:b7efb12e5071ad8d5b547487bdad489fbd4a5a35a0fc36a1941517a6ad7f23e0"}, - {file = "pydantic_core-2.23.2-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:5dd0ec5f514ed40e49bf961d49cf1bc2c72e9b50f29a163b2cc9030c6742aa73"}, - {file = "pydantic_core-2.23.2-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:820f6ee5c06bc868335e3b6e42d7ef41f50dfb3ea32fbd523ab679d10d8741c0"}, - {file = "pydantic_core-2.23.2-cp312-none-win32.whl", hash = "sha256:3713dc093d5048bfaedbba7a8dbc53e74c44a140d45ede020dc347dda18daf3f"}, - {file = "pydantic_core-2.23.2-cp312-none-win_amd64.whl", hash = "sha256:e1895e949f8849bc2757c0dbac28422a04be031204df46a56ab34bcf98507342"}, - {file = "pydantic_core-2.23.2-cp313-cp313-macosx_10_12_x86_64.whl", hash = "sha256:da43cbe593e3c87d07108d0ebd73771dc414488f1f91ed2e204b0370b94b37ac"}, - {file = "pydantic_core-2.23.2-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:64d094ea1aa97c6ded4748d40886076a931a8bf6f61b6e43e4a1041769c39dd2"}, - {file = "pydantic_core-2.23.2-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:084414ffe9a85a52940b49631321d636dadf3576c30259607b75516d131fecd0"}, - {file = "pydantic_core-2.23.2-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:043ef8469f72609c4c3a5e06a07a1f713d53df4d53112c6d49207c0bd3c3bd9b"}, - {file = "pydantic_core-2.23.2-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:3649bd3ae6a8ebea7dc381afb7f3c6db237fc7cebd05c8ac36ca8a4187b03b30"}, - {file = "pydantic_core-2.23.2-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:6db09153d8438425e98cdc9a289c5fade04a5d2128faff8f227c459da21b9703"}, - {file = "pydantic_core-2.23.2-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5668b3173bb0b2e65020b60d83f5910a7224027232c9f5dc05a71a1deac9f960"}, - {file = "pydantic_core-2.23.2-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:1c7b81beaf7c7ebde978377dc53679c6cba0e946426fc7ade54251dfe24a7604"}, - {file = "pydantic_core-2.23.2-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:ae579143826c6f05a361d9546446c432a165ecf1c0b720bbfd81152645cb897d"}, - {file = "pydantic_core-2.23.2-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:19f1352fe4b248cae22a89268720fc74e83f008057a652894f08fa931e77dced"}, - {file = "pydantic_core-2.23.2-cp313-none-win32.whl", hash = "sha256:e1a79ad49f346aa1a2921f31e8dbbab4d64484823e813a002679eaa46cba39e1"}, - {file = "pydantic_core-2.23.2-cp313-none-win_amd64.whl", hash = "sha256:582871902e1902b3c8e9b2c347f32a792a07094110c1bca6c2ea89b90150caac"}, - {file = "pydantic_core-2.23.2-cp39-cp39-macosx_10_12_x86_64.whl", hash = "sha256:358331e21a897151e54d58e08d0219acf98ebb14c567267a87e971f3d2a3be59"}, - {file = "pydantic_core-2.23.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:c4d9f15ffe68bcd3898b0ad7233af01b15c57d91cd1667f8d868e0eacbfe3f87"}, - {file = "pydantic_core-2.23.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0123655fedacf035ab10c23450163c2f65a4174f2bb034b188240a6cf06bb123"}, - {file = "pydantic_core-2.23.2-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:e6e3ccebdbd6e53474b0bb7ab8b88e83c0cfe91484b25e058e581348ee5a01a5"}, - {file = "pydantic_core-2.23.2-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:fc535cb898ef88333cf317777ecdfe0faac1c2a3187ef7eb061b6f7ecf7e6bae"}, - {file = "pydantic_core-2.23.2-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:aab9e522efff3993a9e98ab14263d4e20211e62da088298089a03056980a3e69"}, - {file = "pydantic_core-2.23.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:05b366fb8fe3d8683b11ac35fa08947d7b92be78ec64e3277d03bd7f9b7cda79"}, - {file = "pydantic_core-2.23.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:7568f682c06f10f30ef643a1e8eec4afeecdafde5c4af1b574c6df079e96f96c"}, - {file = "pydantic_core-2.23.2-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:cdd02a08205dc90238669f082747612cb3c82bd2c717adc60f9b9ecadb540f80"}, - {file = "pydantic_core-2.23.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:1a2ab4f410f4b886de53b6bddf5dd6f337915a29dd9f22f20f3099659536b2f6"}, - {file = "pydantic_core-2.23.2-cp39-none-win32.whl", hash = "sha256:0448b81c3dfcde439551bb04a9f41d7627f676b12701865c8a2574bcea034437"}, - {file = "pydantic_core-2.23.2-cp39-none-win_amd64.whl", hash = "sha256:4cebb9794f67266d65e7e4cbe5dcf063e29fc7b81c79dc9475bd476d9534150e"}, - {file = "pydantic_core-2.23.2-pp310-pypy310_pp73-macosx_10_12_x86_64.whl", hash = "sha256:e758d271ed0286d146cf7c04c539a5169a888dd0b57026be621547e756af55bc"}, - {file = "pydantic_core-2.23.2-pp310-pypy310_pp73-macosx_11_0_arm64.whl", hash = "sha256:f477d26183e94eaafc60b983ab25af2a809a1b48ce4debb57b343f671b7a90b6"}, - {file = "pydantic_core-2.23.2-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:da3131ef2b940b99106f29dfbc30d9505643f766704e14c5d5e504e6a480c35e"}, - {file = "pydantic_core-2.23.2-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:329a721253c7e4cbd7aad4a377745fbcc0607f9d72a3cc2102dd40519be75ed2"}, - {file = "pydantic_core-2.23.2-pp310-pypy310_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:7706e15cdbf42f8fab1e6425247dfa98f4a6f8c63746c995d6a2017f78e619ae"}, - {file = "pydantic_core-2.23.2-pp310-pypy310_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:e64ffaf8f6e17ca15eb48344d86a7a741454526f3a3fa56bc493ad9d7ec63936"}, - {file = "pydantic_core-2.23.2-pp310-pypy310_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:dd59638025160056687d598b054b64a79183f8065eae0d3f5ca523cde9943940"}, - {file = "pydantic_core-2.23.2-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:12625e69b1199e94b0ae1c9a95d000484ce9f0182f9965a26572f054b1537e44"}, - {file = "pydantic_core-2.23.2-pp39-pypy39_pp73-macosx_10_12_x86_64.whl", hash = "sha256:5d813fd871b3d5c3005157622ee102e8908ad6011ec915a18bd8fde673c4360e"}, - {file = "pydantic_core-2.23.2-pp39-pypy39_pp73-macosx_11_0_arm64.whl", hash = "sha256:1eb37f7d6a8001c0f86dc8ff2ee8d08291a536d76e49e78cda8587bb54d8b329"}, - {file = "pydantic_core-2.23.2-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7ce7eaf9a98680b4312b7cebcdd9352531c43db00fca586115845df388f3c465"}, - {file = "pydantic_core-2.23.2-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f087879f1ffde024dd2788a30d55acd67959dcf6c431e9d3682d1c491a0eb474"}, - {file = "pydantic_core-2.23.2-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:6ce883906810b4c3bd90e0ada1f9e808d9ecf1c5f0b60c6b8831d6100bcc7dd6"}, - {file = "pydantic_core-2.23.2-pp39-pypy39_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:a8031074a397a5925d06b590121f8339d34a5a74cfe6970f8a1124eb8b83f4ac"}, - {file = "pydantic_core-2.23.2-pp39-pypy39_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:23af245b8f2f4ee9e2c99cb3f93d0e22fb5c16df3f2f643f5a8da5caff12a653"}, - {file = "pydantic_core-2.23.2-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:c57e493a0faea1e4c38f860d6862ba6832723396c884fbf938ff5e9b224200e2"}, - {file = "pydantic_core-2.23.2.tar.gz", hash = "sha256:95d6bf449a1ac81de562d65d180af5d8c19672793c81877a2eda8fde5d08f2fd"}, + {file = "pydantic_core-2.27.2-cp310-cp310-macosx_10_12_x86_64.whl", hash = "sha256:2d367ca20b2f14095a8f4fa1210f5a7b78b8a20009ecced6b12818f455b1e9fa"}, + {file = "pydantic_core-2.27.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:491a2b73db93fab69731eaee494f320faa4e093dbed776be1a829c2eb222c34c"}, + {file = "pydantic_core-2.27.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7969e133a6f183be60e9f6f56bfae753585680f3b7307a8e555a948d443cc05a"}, + {file = "pydantic_core-2.27.2-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3de9961f2a346257caf0aa508a4da705467f53778e9ef6fe744c038119737ef5"}, + {file = "pydantic_core-2.27.2-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:e2bb4d3e5873c37bb3dd58714d4cd0b0e6238cebc4177ac8fe878f8b3aa8e74c"}, + {file = "pydantic_core-2.27.2-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:280d219beebb0752699480fe8f1dc61ab6615c2046d76b7ab7ee38858de0a4e7"}, + {file = "pydantic_core-2.27.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:47956ae78b6422cbd46f772f1746799cbb862de838fd8d1fbd34a82e05b0983a"}, + {file = "pydantic_core-2.27.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:14d4a5c49d2f009d62a2a7140d3064f686d17a5d1a268bc641954ba181880236"}, + {file = "pydantic_core-2.27.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:337b443af21d488716f8d0b6164de833e788aa6bd7e3a39c005febc1284f4962"}, + {file = "pydantic_core-2.27.2-cp310-cp310-musllinux_1_1_armv7l.whl", hash = "sha256:03d0f86ea3184a12f41a2d23f7ccb79cdb5a18e06993f8a45baa8dfec746f0e9"}, + {file = "pydantic_core-2.27.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:7041c36f5680c6e0f08d922aed302e98b3745d97fe1589db0a3eebf6624523af"}, + {file = "pydantic_core-2.27.2-cp310-cp310-win32.whl", hash = "sha256:50a68f3e3819077be2c98110c1f9dcb3817e93f267ba80a2c05bb4f8799e2ff4"}, + {file = "pydantic_core-2.27.2-cp310-cp310-win_amd64.whl", hash = "sha256:e0fd26b16394ead34a424eecf8a31a1f5137094cabe84a1bcb10fa6ba39d3d31"}, + {file = "pydantic_core-2.27.2-cp311-cp311-macosx_10_12_x86_64.whl", hash = "sha256:8e10c99ef58cfdf2a66fc15d66b16c4a04f62bca39db589ae8cba08bc55331bc"}, + {file = "pydantic_core-2.27.2-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:26f32e0adf166a84d0cb63be85c562ca8a6fa8de28e5f0d92250c6b7e9e2aff7"}, + {file = "pydantic_core-2.27.2-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8c19d1ea0673cd13cc2f872f6c9ab42acc4e4f492a7ca9d3795ce2b112dd7e15"}, + {file = "pydantic_core-2.27.2-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:5e68c4446fe0810e959cdff46ab0a41ce2f2c86d227d96dc3847af0ba7def306"}, + {file = "pydantic_core-2.27.2-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:d9640b0059ff4f14d1f37321b94061c6db164fbe49b334b31643e0528d100d99"}, + {file = "pydantic_core-2.27.2-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:40d02e7d45c9f8af700f3452f329ead92da4c5f4317ca9b896de7ce7199ea459"}, + {file = "pydantic_core-2.27.2-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1c1fd185014191700554795c99b347d64f2bb637966c4cfc16998a0ca700d048"}, + {file = "pydantic_core-2.27.2-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:d81d2068e1c1228a565af076598f9e7451712700b673de8f502f0334f281387d"}, + {file = "pydantic_core-2.27.2-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:1a4207639fb02ec2dbb76227d7c751a20b1a6b4bc52850568e52260cae64ca3b"}, + {file = "pydantic_core-2.27.2-cp311-cp311-musllinux_1_1_armv7l.whl", hash = "sha256:3de3ce3c9ddc8bbd88f6e0e304dea0e66d843ec9de1b0042b0911c1663ffd474"}, + {file = "pydantic_core-2.27.2-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:30c5f68ded0c36466acede341551106821043e9afaad516adfb6e8fa80a4e6a6"}, + {file = "pydantic_core-2.27.2-cp311-cp311-win32.whl", hash = "sha256:c70c26d2c99f78b125a3459f8afe1aed4d9687c24fd677c6a4436bc042e50d6c"}, + {file = "pydantic_core-2.27.2-cp311-cp311-win_amd64.whl", hash = "sha256:08e125dbdc505fa69ca7d9c499639ab6407cfa909214d500897d02afb816e7cc"}, + {file = "pydantic_core-2.27.2-cp311-cp311-win_arm64.whl", hash = "sha256:26f0d68d4b235a2bae0c3fc585c585b4ecc51382db0e3ba402a22cbc440915e4"}, + {file = "pydantic_core-2.27.2-cp312-cp312-macosx_10_12_x86_64.whl", hash = "sha256:9e0c8cfefa0ef83b4da9588448b6d8d2a2bf1a53c3f1ae5fca39eb3061e2f0b0"}, + {file = "pydantic_core-2.27.2-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:83097677b8e3bd7eaa6775720ec8e0405f1575015a463285a92bfdfe254529ef"}, + {file = "pydantic_core-2.27.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:172fce187655fece0c90d90a678424b013f8fbb0ca8b036ac266749c09438cb7"}, + {file = "pydantic_core-2.27.2-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:519f29f5213271eeeeb3093f662ba2fd512b91c5f188f3bb7b27bc5973816934"}, + {file = "pydantic_core-2.27.2-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:05e3a55d124407fffba0dd6b0c0cd056d10e983ceb4e5dbd10dda135c31071d6"}, + {file = "pydantic_core-2.27.2-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:9c3ed807c7b91de05e63930188f19e921d1fe90de6b4f5cd43ee7fcc3525cb8c"}, + {file = "pydantic_core-2.27.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6fb4aadc0b9a0c063206846d603b92030eb6f03069151a625667f982887153e2"}, + {file = "pydantic_core-2.27.2-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:28ccb213807e037460326424ceb8b5245acb88f32f3d2777427476e1b32c48c4"}, + {file = "pydantic_core-2.27.2-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:de3cd1899e2c279b140adde9357c4495ed9d47131b4a4eaff9052f23398076b3"}, + {file = "pydantic_core-2.27.2-cp312-cp312-musllinux_1_1_armv7l.whl", hash = "sha256:220f892729375e2d736b97d0e51466252ad84c51857d4d15f5e9692f9ef12be4"}, + {file = "pydantic_core-2.27.2-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:a0fcd29cd6b4e74fe8ddd2c90330fd8edf2e30cb52acda47f06dd615ae72da57"}, + {file = "pydantic_core-2.27.2-cp312-cp312-win32.whl", hash = "sha256:1e2cb691ed9834cd6a8be61228471d0a503731abfb42f82458ff27be7b2186fc"}, + {file = "pydantic_core-2.27.2-cp312-cp312-win_amd64.whl", hash = "sha256:cc3f1a99a4f4f9dd1de4fe0312c114e740b5ddead65bb4102884b384c15d8bc9"}, + {file = "pydantic_core-2.27.2-cp312-cp312-win_arm64.whl", hash = "sha256:3911ac9284cd8a1792d3cb26a2da18f3ca26c6908cc434a18f730dc0db7bfa3b"}, + {file = "pydantic_core-2.27.2-cp313-cp313-macosx_10_12_x86_64.whl", hash = "sha256:7d14bd329640e63852364c306f4d23eb744e0f8193148d4044dd3dacdaacbd8b"}, + {file = "pydantic_core-2.27.2-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:82f91663004eb8ed30ff478d77c4d1179b3563df6cdb15c0817cd1cdaf34d154"}, + {file = "pydantic_core-2.27.2-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:71b24c7d61131bb83df10cc7e687433609963a944ccf45190cfc21e0887b08c9"}, + {file = "pydantic_core-2.27.2-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:fa8e459d4954f608fa26116118bb67f56b93b209c39b008277ace29937453dc9"}, + {file = "pydantic_core-2.27.2-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:ce8918cbebc8da707ba805b7fd0b382816858728ae7fe19a942080c24e5b7cd1"}, + {file = "pydantic_core-2.27.2-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:eda3f5c2a021bbc5d976107bb302e0131351c2ba54343f8a496dc8783d3d3a6a"}, + {file = "pydantic_core-2.27.2-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bd8086fa684c4775c27f03f062cbb9eaa6e17f064307e86b21b9e0abc9c0f02e"}, + {file = "pydantic_core-2.27.2-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:8d9b3388db186ba0c099a6d20f0604a44eabdeef1777ddd94786cdae158729e4"}, + {file = "pydantic_core-2.27.2-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:7a66efda2387de898c8f38c0cf7f14fca0b51a8ef0b24bfea5849f1b3c95af27"}, + {file = "pydantic_core-2.27.2-cp313-cp313-musllinux_1_1_armv7l.whl", hash = "sha256:18a101c168e4e092ab40dbc2503bdc0f62010e95d292b27827871dc85450d7ee"}, + {file = "pydantic_core-2.27.2-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:ba5dd002f88b78a4215ed2f8ddbdf85e8513382820ba15ad5ad8955ce0ca19a1"}, + {file = "pydantic_core-2.27.2-cp313-cp313-win32.whl", hash = "sha256:1ebaf1d0481914d004a573394f4be3a7616334be70261007e47c2a6fe7e50130"}, + {file = "pydantic_core-2.27.2-cp313-cp313-win_amd64.whl", hash = "sha256:953101387ecf2f5652883208769a79e48db18c6df442568a0b5ccd8c2723abee"}, + {file = "pydantic_core-2.27.2-cp313-cp313-win_arm64.whl", hash = "sha256:ac4dbfd1691affb8f48c2c13241a2e3b60ff23247cbcf981759c768b6633cf8b"}, + {file = "pydantic_core-2.27.2-cp39-cp39-macosx_10_12_x86_64.whl", hash = "sha256:c10eb4f1659290b523af58fa7cffb452a61ad6ae5613404519aee4bfbf1df993"}, + {file = "pydantic_core-2.27.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ef592d4bad47296fb11f96cd7dc898b92e795032b4894dfb4076cfccd43a9308"}, + {file = "pydantic_core-2.27.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c61709a844acc6bf0b7dce7daae75195a10aac96a596ea1b776996414791ede4"}, + {file = "pydantic_core-2.27.2-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:42c5f762659e47fdb7b16956c71598292f60a03aa92f8b6351504359dbdba6cf"}, + {file = "pydantic_core-2.27.2-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:4c9775e339e42e79ec99c441d9730fccf07414af63eac2f0e48e08fd38a64d76"}, + {file = "pydantic_core-2.27.2-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:57762139821c31847cfb2df63c12f725788bd9f04bc2fb392790959b8f70f118"}, + {file = "pydantic_core-2.27.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:0d1e85068e818c73e048fe28cfc769040bb1f475524f4745a5dc621f75ac7630"}, + {file = "pydantic_core-2.27.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:097830ed52fd9e427942ff3b9bc17fab52913b2f50f2880dc4a5611446606a54"}, + {file = "pydantic_core-2.27.2-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:044a50963a614ecfae59bb1eaf7ea7efc4bc62f49ed594e18fa1e5d953c40e9f"}, + {file = "pydantic_core-2.27.2-cp39-cp39-musllinux_1_1_armv7l.whl", hash = "sha256:4e0b4220ba5b40d727c7f879eac379b822eee5d8fff418e9d3381ee45b3b0362"}, + {file = "pydantic_core-2.27.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:5e4f4bb20d75e9325cc9696c6802657b58bc1dbbe3022f32cc2b2b632c3fbb96"}, + {file = "pydantic_core-2.27.2-cp39-cp39-win32.whl", hash = "sha256:cca63613e90d001b9f2f9a9ceb276c308bfa2a43fafb75c8031c4f66039e8c6e"}, + {file = "pydantic_core-2.27.2-cp39-cp39-win_amd64.whl", hash = "sha256:77d1bca19b0f7021b3a982e6f903dcd5b2b06076def36a652e3907f596e29f67"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-macosx_10_12_x86_64.whl", hash = "sha256:2bf14caea37e91198329b828eae1618c068dfb8ef17bb33287a7ad4b61ac314e"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-macosx_11_0_arm64.whl", hash = "sha256:b0cb791f5b45307caae8810c2023a184c74605ec3bcbb67d13846c28ff731ff8"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:688d3fd9fcb71f41c4c015c023d12a79d1c4c0732ec9eb35d96e3388a120dcf3"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3d591580c34f4d731592f0e9fe40f9cc1b430d297eecc70b962e93c5c668f15f"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:82f986faf4e644ffc189a7f1aafc86e46ef70372bb153e7001e8afccc6e54133"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:bec317a27290e2537f922639cafd54990551725fc844249e64c523301d0822fc"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-musllinux_1_1_armv7l.whl", hash = "sha256:0296abcb83a797db256b773f45773da397da75a08f5fcaef41f2044adec05f50"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:0d75070718e369e452075a6017fbf187f788e17ed67a3abd47fa934d001863d9"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:7e17b560be3c98a8e3aa66ce828bdebb9e9ac6ad5466fba92eb74c4c95cb1151"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-macosx_10_12_x86_64.whl", hash = "sha256:c33939a82924da9ed65dab5a65d427205a73181d8098e79b6b426bdf8ad4e656"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-macosx_11_0_arm64.whl", hash = "sha256:00bad2484fa6bda1e216e7345a798bd37c68fb2d97558edd584942aa41b7d278"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c817e2b40aba42bac6f457498dacabc568c3b7a986fc9ba7c8d9d260b71485fb"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:251136cdad0cb722e93732cb45ca5299fb56e1344a833640bf93b2803f8d1bfd"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:d2088237af596f0a524d3afc39ab3b036e8adb054ee57cbb1dcf8e09da5b29cc"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:d4041c0b966a84b4ae7a09832eb691a35aec90910cd2dbe7a208de59be77965b"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-musllinux_1_1_armv7l.whl", hash = "sha256:8083d4e875ebe0b864ffef72a4304827015cff328a1be6e22cc850753bfb122b"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:f141ee28a0ad2123b6611b6ceff018039df17f32ada8b534e6aa039545a3efb2"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:7d0c8399fcc1848491f00e0314bd59fb34a9c008761bcb422a057670c3f65e35"}, + {file = "pydantic_core-2.27.2.tar.gz", hash = "sha256:eb026e5a4c1fee05726072337ff51d1efb6f59090b7da90d30ea58625b1ffb39"}, ] [[package]] name = "pydantic-settings" -version = "2.5.2" +version = "2.7.0" requires_python = ">=3.8" summary = "Settings management using Pydantic" groups = ["default"] @@ -1147,8 +1160,8 @@ dependencies = [ "python-dotenv>=0.21.0", ] files = [ - {file = "pydantic_settings-2.5.2-py3-none-any.whl", hash = "sha256:2c912e55fd5794a59bf8c832b9de832dcfdf4778d79ff79b708744eed499a907"}, - {file = "pydantic_settings-2.5.2.tar.gz", hash = "sha256:f90b139682bee4d2065273d5185d71d37ea46cfe57e1b5ae184fc6a0b2484ca0"}, + {file = "pydantic_settings-2.7.0-py3-none-any.whl", hash = "sha256:e00c05d5fa6cbbb227c84bd7487c5c1065084119b750df7c8c1a554aed236eb5"}, + {file = "pydantic_settings-2.7.0.tar.gz", hash = "sha256:ac4bfd4a36831a48dbf8b2d9325425b549a0a6f18cea118436d728eb4f1c4d66"}, ] [[package]] @@ -1175,7 +1188,7 @@ files = [ [[package]] name = "pytest" -version = "8.3.3" +version = "8.3.4" requires_python = ">=3.8" summary = "pytest: simple powerful testing with Python" groups = ["testing"] @@ -1188,22 +1201,22 @@ dependencies = [ "tomli>=1; python_version < \"3.11\"", ] files = [ - {file = "pytest-8.3.3-py3-none-any.whl", hash = "sha256:a6853c7375b2663155079443d2e45de913a911a11d669df02a50814944db57b2"}, - {file = "pytest-8.3.3.tar.gz", hash = "sha256:70b98107bd648308a7952b06e6ca9a50bc660be218d53c257cc1fc94fda10181"}, + {file = "pytest-8.3.4-py3-none-any.whl", hash = "sha256:50e16d954148559c9a74109af1eaf0c945ba2d8f30f0a3d3335edde19788b6f6"}, + {file = "pytest-8.3.4.tar.gz", hash = "sha256:965370d062bce11e73868e0335abac31b4d3de0e82f4007408d242b4f8610761"}, ] [[package]] name = "pytest-asyncio" -version = "0.24.0" -requires_python = ">=3.8" +version = "0.25.0" +requires_python = ">=3.9" summary = "Pytest support for asyncio" groups = ["testing"] dependencies = [ "pytest<9,>=8.2", ] files = [ - {file = "pytest_asyncio-0.24.0-py3-none-any.whl", hash = "sha256:a811296ed596b69bf0b6f3dc40f83bcaf341b155a269052d82efa2b25ac7037b"}, - {file = "pytest_asyncio-0.24.0.tar.gz", hash = "sha256:d081d828e576d85f875399194281e92bf8a68d60d72d1a2faf2feddb6c46b276"}, + {file = "pytest_asyncio-0.25.0-py3-none-any.whl", hash = "sha256:db5432d18eac6b7e28b46dcd9b69921b55c3b1086e85febfe04e70b18d9e81b3"}, + {file = "pytest_asyncio-0.25.0.tar.gz", hash = "sha256:8c0610303c9e0442a5db8604505fc0f545456ba1528824842b37b4a626cbf609"}, ] [[package]] @@ -1281,89 +1294,89 @@ files = [ [[package]] name = "regex" -version = "2024.9.11" +version = "2024.11.6" requires_python = ">=3.8" summary = "Alternative regular expression module, to replace re." groups = ["default"] files = [ - {file = "regex-2024.9.11-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1494fa8725c285a81d01dc8c06b55287a1ee5e0e382d8413adc0a9197aac6408"}, - {file = "regex-2024.9.11-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:0e12c481ad92d129c78f13a2a3662317e46ee7ef96c94fd332e1c29131875b7d"}, - {file = "regex-2024.9.11-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:16e13a7929791ac1216afde26f712802e3df7bf0360b32e4914dca3ab8baeea5"}, - {file = "regex-2024.9.11-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:46989629904bad940bbec2106528140a218b4a36bb3042d8406980be1941429c"}, - {file = "regex-2024.9.11-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:a906ed5e47a0ce5f04b2c981af1c9acf9e8696066900bf03b9d7879a6f679fc8"}, - {file = "regex-2024.9.11-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:e9a091b0550b3b0207784a7d6d0f1a00d1d1c8a11699c1a4d93db3fbefc3ad35"}, - {file = "regex-2024.9.11-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5ddcd9a179c0a6fa8add279a4444015acddcd7f232a49071ae57fa6e278f1f71"}, - {file = "regex-2024.9.11-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6b41e1adc61fa347662b09398e31ad446afadff932a24807d3ceb955ed865cc8"}, - {file = "regex-2024.9.11-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ced479f601cd2f8ca1fd7b23925a7e0ad512a56d6e9476f79b8f381d9d37090a"}, - {file = "regex-2024.9.11-cp310-cp310-musllinux_1_2_aarch64.whl", hash = "sha256:635a1d96665f84b292e401c3d62775851aedc31d4f8784117b3c68c4fcd4118d"}, - {file = "regex-2024.9.11-cp310-cp310-musllinux_1_2_i686.whl", hash = "sha256:c0256beda696edcf7d97ef16b2a33a8e5a875affd6fa6567b54f7c577b30a137"}, - {file = "regex-2024.9.11-cp310-cp310-musllinux_1_2_ppc64le.whl", hash = "sha256:3ce4f1185db3fbde8ed8aa223fc9620f276c58de8b0d4f8cc86fd1360829edb6"}, - {file = "regex-2024.9.11-cp310-cp310-musllinux_1_2_s390x.whl", hash = "sha256:09d77559e80dcc9d24570da3745ab859a9cf91953062e4ab126ba9d5993688ca"}, - {file = "regex-2024.9.11-cp310-cp310-musllinux_1_2_x86_64.whl", hash = "sha256:7a22ccefd4db3f12b526eccb129390942fe874a3a9fdbdd24cf55773a1faab1a"}, - {file = "regex-2024.9.11-cp310-cp310-win32.whl", hash = "sha256:f745ec09bc1b0bd15cfc73df6fa4f726dcc26bb16c23a03f9e3367d357eeedd0"}, - {file = "regex-2024.9.11-cp310-cp310-win_amd64.whl", hash = "sha256:01c2acb51f8a7d6494c8c5eafe3d8e06d76563d8a8a4643b37e9b2dd8a2ff623"}, - {file = "regex-2024.9.11-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:2cce2449e5927a0bf084d346da6cd5eb016b2beca10d0013ab50e3c226ffc0df"}, - {file = "regex-2024.9.11-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:3b37fa423beefa44919e009745ccbf353d8c981516e807995b2bd11c2c77d268"}, - {file = "regex-2024.9.11-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:64ce2799bd75039b480cc0360907c4fb2f50022f030bf9e7a8705b636e408fad"}, - {file = "regex-2024.9.11-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a4cc92bb6db56ab0c1cbd17294e14f5e9224f0cc6521167ef388332604e92679"}, - {file = "regex-2024.9.11-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:d05ac6fa06959c4172eccd99a222e1fbf17b5670c4d596cb1e5cde99600674c4"}, - {file = "regex-2024.9.11-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:040562757795eeea356394a7fb13076ad4f99d3c62ab0f8bdfb21f99a1f85664"}, - {file = "regex-2024.9.11-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6113c008a7780792efc80f9dfe10ba0cd043cbf8dc9a76ef757850f51b4edc50"}, - {file = "regex-2024.9.11-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:8e5fb5f77c8745a60105403a774fe2c1759b71d3e7b4ca237a5e67ad066c7199"}, - {file = "regex-2024.9.11-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:54d9ff35d4515debf14bc27f1e3b38bfc453eff3220f5bce159642fa762fe5d4"}, - {file = "regex-2024.9.11-cp311-cp311-musllinux_1_2_i686.whl", hash = "sha256:df5cbb1fbc74a8305b6065d4ade43b993be03dbe0f8b30032cced0d7740994bd"}, - {file = "regex-2024.9.11-cp311-cp311-musllinux_1_2_ppc64le.whl", hash = "sha256:7fb89ee5d106e4a7a51bce305ac4efb981536301895f7bdcf93ec92ae0d91c7f"}, - {file = "regex-2024.9.11-cp311-cp311-musllinux_1_2_s390x.whl", hash = "sha256:a738b937d512b30bf75995c0159c0ddf9eec0775c9d72ac0202076c72f24aa96"}, - {file = "regex-2024.9.11-cp311-cp311-musllinux_1_2_x86_64.whl", hash = "sha256:e28f9faeb14b6f23ac55bfbbfd3643f5c7c18ede093977f1df249f73fd22c7b1"}, - {file = "regex-2024.9.11-cp311-cp311-win32.whl", hash = "sha256:18e707ce6c92d7282dfce370cd205098384b8ee21544e7cb29b8aab955b66fa9"}, - {file = "regex-2024.9.11-cp311-cp311-win_amd64.whl", hash = "sha256:313ea15e5ff2a8cbbad96ccef6be638393041b0a7863183c2d31e0c6116688cf"}, - {file = "regex-2024.9.11-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:b0d0a6c64fcc4ef9c69bd5b3b3626cc3776520a1637d8abaa62b9edc147a58f7"}, - {file = "regex-2024.9.11-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:49b0e06786ea663f933f3710a51e9385ce0cba0ea56b67107fd841a55d56a231"}, - {file = "regex-2024.9.11-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:5b513b6997a0b2f10e4fd3a1313568e373926e8c252bd76c960f96fd039cd28d"}, - {file = "regex-2024.9.11-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:ee439691d8c23e76f9802c42a95cfeebf9d47cf4ffd06f18489122dbb0a7ad64"}, - {file = "regex-2024.9.11-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:a8f877c89719d759e52783f7fe6e1c67121076b87b40542966c02de5503ace42"}, - {file = "regex-2024.9.11-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:23b30c62d0f16827f2ae9f2bb87619bc4fba2044911e2e6c2eb1af0161cdb766"}, - {file = "regex-2024.9.11-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:85ab7824093d8f10d44330fe1e6493f756f252d145323dd17ab6b48733ff6c0a"}, - {file = "regex-2024.9.11-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:8dee5b4810a89447151999428fe096977346cf2f29f4d5e29609d2e19e0199c9"}, - {file = "regex-2024.9.11-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:98eeee2f2e63edae2181c886d7911ce502e1292794f4c5ee71e60e23e8d26b5d"}, - {file = "regex-2024.9.11-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:57fdd2e0b2694ce6fc2e5ccf189789c3e2962916fb38779d3e3521ff8fe7a822"}, - {file = "regex-2024.9.11-cp312-cp312-musllinux_1_2_ppc64le.whl", hash = "sha256:d552c78411f60b1fdaafd117a1fca2f02e562e309223b9d44b7de8be451ec5e0"}, - {file = "regex-2024.9.11-cp312-cp312-musllinux_1_2_s390x.whl", hash = "sha256:a0b2b80321c2ed3fcf0385ec9e51a12253c50f146fddb2abbb10f033fe3d049a"}, - {file = "regex-2024.9.11-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:18406efb2f5a0e57e3a5881cd9354c1512d3bb4f5c45d96d110a66114d84d23a"}, - {file = "regex-2024.9.11-cp312-cp312-win32.whl", hash = "sha256:e464b467f1588e2c42d26814231edecbcfe77f5ac414d92cbf4e7b55b2c2a776"}, - {file = "regex-2024.9.11-cp312-cp312-win_amd64.whl", hash = "sha256:9e8719792ca63c6b8340380352c24dcb8cd7ec49dae36e963742a275dfae6009"}, - {file = "regex-2024.9.11-cp313-cp313-macosx_10_13_universal2.whl", hash = "sha256:c157bb447303070f256e084668b702073db99bbb61d44f85d811025fcf38f784"}, - {file = "regex-2024.9.11-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:4db21ece84dfeefc5d8a3863f101995de646c6cb0536952c321a2650aa202c36"}, - {file = "regex-2024.9.11-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:220e92a30b426daf23bb67a7962900ed4613589bab80382be09b48896d211e92"}, - {file = "regex-2024.9.11-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:eb1ae19e64c14c7ec1995f40bd932448713d3c73509e82d8cd7744dc00e29e86"}, - {file = "regex-2024.9.11-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:f47cd43a5bfa48f86925fe26fbdd0a488ff15b62468abb5d2a1e092a4fb10e85"}, - {file = "regex-2024.9.11-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:9d4a76b96f398697fe01117093613166e6aa8195d63f1b4ec3f21ab637632963"}, - {file = "regex-2024.9.11-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:0ea51dcc0835eea2ea31d66456210a4e01a076d820e9039b04ae8d17ac11dee6"}, - {file = "regex-2024.9.11-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b7aaa315101c6567a9a45d2839322c51c8d6e81f67683d529512f5bcfb99c802"}, - {file = "regex-2024.9.11-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:c57d08ad67aba97af57a7263c2d9006d5c404d721c5f7542f077f109ec2a4a29"}, - {file = "regex-2024.9.11-cp313-cp313-musllinux_1_2_i686.whl", hash = "sha256:f8404bf61298bb6f8224bb9176c1424548ee1181130818fcd2cbffddc768bed8"}, - {file = "regex-2024.9.11-cp313-cp313-musllinux_1_2_ppc64le.whl", hash = "sha256:dd4490a33eb909ef5078ab20f5f000087afa2a4daa27b4c072ccb3cb3050ad84"}, - {file = "regex-2024.9.11-cp313-cp313-musllinux_1_2_s390x.whl", hash = "sha256:eee9130eaad130649fd73e5cd92f60e55708952260ede70da64de420cdcad554"}, - {file = "regex-2024.9.11-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:6a2644a93da36c784e546de579ec1806bfd2763ef47babc1b03d765fe560c9f8"}, - {file = "regex-2024.9.11-cp313-cp313-win32.whl", hash = "sha256:e997fd30430c57138adc06bba4c7c2968fb13d101e57dd5bb9355bf8ce3fa7e8"}, - {file = "regex-2024.9.11-cp313-cp313-win_amd64.whl", hash = "sha256:042c55879cfeb21a8adacc84ea347721d3d83a159da6acdf1116859e2427c43f"}, - {file = "regex-2024.9.11-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:07f45f287469039ffc2c53caf6803cd506eb5f5f637f1d4acb37a738f71dd066"}, - {file = "regex-2024.9.11-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:4838e24ee015101d9f901988001038f7f0d90dc0c3b115541a1365fb439add62"}, - {file = "regex-2024.9.11-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:6edd623bae6a737f10ce853ea076f56f507fd7726bee96a41ee3d68d347e4d16"}, - {file = "regex-2024.9.11-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c69ada171c2d0e97a4b5aa78fbb835e0ffbb6b13fc5da968c09811346564f0d3"}, - {file = "regex-2024.9.11-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:02087ea0a03b4af1ed6ebab2c54d7118127fee8d71b26398e8e4b05b78963199"}, - {file = "regex-2024.9.11-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:69dee6a020693d12a3cf892aba4808fe168d2a4cef368eb9bf74f5398bfd4ee8"}, - {file = "regex-2024.9.11-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:297f54910247508e6e5cae669f2bc308985c60540a4edd1c77203ef19bfa63ca"}, - {file = "regex-2024.9.11-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:ecea58b43a67b1b79805f1a0255730edaf5191ecef84dbc4cc85eb30bc8b63b9"}, - {file = "regex-2024.9.11-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:eab4bb380f15e189d1313195b062a6aa908f5bd687a0ceccd47c8211e9cf0d4a"}, - {file = "regex-2024.9.11-cp39-cp39-musllinux_1_2_aarch64.whl", hash = "sha256:0cbff728659ce4bbf4c30b2a1be040faafaa9eca6ecde40aaff86f7889f4ab39"}, - {file = "regex-2024.9.11-cp39-cp39-musllinux_1_2_i686.whl", hash = "sha256:54c4a097b8bc5bb0dfc83ae498061d53ad7b5762e00f4adaa23bee22b012e6ba"}, - {file = "regex-2024.9.11-cp39-cp39-musllinux_1_2_ppc64le.whl", hash = "sha256:73d6d2f64f4d894c96626a75578b0bf7d9e56dcda8c3d037a2118fdfe9b1c664"}, - {file = "regex-2024.9.11-cp39-cp39-musllinux_1_2_s390x.whl", hash = "sha256:e53b5fbab5d675aec9f0c501274c467c0f9a5d23696cfc94247e1fb56501ed89"}, - {file = "regex-2024.9.11-cp39-cp39-musllinux_1_2_x86_64.whl", hash = "sha256:0ffbcf9221e04502fc35e54d1ce9567541979c3fdfb93d2c554f0ca583a19b35"}, - {file = "regex-2024.9.11-cp39-cp39-win32.whl", hash = "sha256:e4c22e1ac1f1ec1e09f72e6c44d8f2244173db7eb9629cc3a346a8d7ccc31142"}, - {file = "regex-2024.9.11-cp39-cp39-win_amd64.whl", hash = "sha256:faa3c142464efec496967359ca99696c896c591c56c53506bac1ad465f66e919"}, - {file = "regex-2024.9.11.tar.gz", hash = "sha256:6c188c307e8433bcb63dc1915022deb553b4203a70722fc542c363bf120a01fd"}, + {file = "regex-2024.11.6-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:ff590880083d60acc0433f9c3f713c51f7ac6ebb9adf889c79a261ecf541aa91"}, + {file = "regex-2024.11.6-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:658f90550f38270639e83ce492f27d2c8d2cd63805c65a13a14d36ca126753f0"}, + {file = "regex-2024.11.6-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:164d8b7b3b4bcb2068b97428060b2a53be050085ef94eca7f240e7947f1b080e"}, + {file = "regex-2024.11.6-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d3660c82f209655a06b587d55e723f0b813d3a7db2e32e5e7dc64ac2a9e86fde"}, + {file = "regex-2024.11.6-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:d22326fcdef5e08c154280b71163ced384b428343ae16a5ab2b3354aed12436e"}, + {file = "regex-2024.11.6-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:f1ac758ef6aebfc8943560194e9fd0fa18bcb34d89fd8bd2af18183afd8da3a2"}, + {file = "regex-2024.11.6-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:997d6a487ff00807ba810e0f8332c18b4eb8d29463cfb7c820dc4b6e7562d0cf"}, + {file = "regex-2024.11.6-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:02a02d2bb04fec86ad61f3ea7f49c015a0681bf76abb9857f945d26159d2968c"}, + {file = "regex-2024.11.6-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f02f93b92358ee3f78660e43b4b0091229260c5d5c408d17d60bf26b6c900e86"}, + {file = "regex-2024.11.6-cp310-cp310-musllinux_1_2_aarch64.whl", hash = "sha256:06eb1be98df10e81ebaded73fcd51989dcf534e3c753466e4b60c4697a003b67"}, + {file = "regex-2024.11.6-cp310-cp310-musllinux_1_2_i686.whl", hash = "sha256:040df6fe1a5504eb0f04f048e6d09cd7c7110fef851d7c567a6b6e09942feb7d"}, + {file = "regex-2024.11.6-cp310-cp310-musllinux_1_2_ppc64le.whl", hash = "sha256:fdabbfc59f2c6edba2a6622c647b716e34e8e3867e0ab975412c5c2f79b82da2"}, + {file = "regex-2024.11.6-cp310-cp310-musllinux_1_2_s390x.whl", hash = "sha256:8447d2d39b5abe381419319f942de20b7ecd60ce86f16a23b0698f22e1b70008"}, + {file = "regex-2024.11.6-cp310-cp310-musllinux_1_2_x86_64.whl", hash = "sha256:da8f5fc57d1933de22a9e23eec290a0d8a5927a5370d24bda9a6abe50683fe62"}, + {file = "regex-2024.11.6-cp310-cp310-win32.whl", hash = "sha256:b489578720afb782f6ccf2840920f3a32e31ba28a4b162e13900c3e6bd3f930e"}, + {file = "regex-2024.11.6-cp310-cp310-win_amd64.whl", hash = "sha256:5071b2093e793357c9d8b2929dfc13ac5f0a6c650559503bb81189d0a3814519"}, + {file = "regex-2024.11.6-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:5478c6962ad548b54a591778e93cd7c456a7a29f8eca9c49e4f9a806dcc5d638"}, + {file = "regex-2024.11.6-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:2c89a8cc122b25ce6945f0423dc1352cb9593c68abd19223eebbd4e56612c5b7"}, + {file = "regex-2024.11.6-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:94d87b689cdd831934fa3ce16cc15cd65748e6d689f5d2b8f4f4df2065c9fa20"}, + {file = "regex-2024.11.6-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1062b39a0a2b75a9c694f7a08e7183a80c63c0d62b301418ffd9c35f55aaa114"}, + {file = "regex-2024.11.6-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:167ed4852351d8a750da48712c3930b031f6efdaa0f22fa1933716bfcd6bf4a3"}, + {file = "regex-2024.11.6-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:2d548dafee61f06ebdb584080621f3e0c23fff312f0de1afc776e2a2ba99a74f"}, + {file = "regex-2024.11.6-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f2a19f302cd1ce5dd01a9099aaa19cae6173306d1302a43b627f62e21cf18ac0"}, + {file = "regex-2024.11.6-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:bec9931dfb61ddd8ef2ebc05646293812cb6b16b60cf7c9511a832b6f1854b55"}, + {file = "regex-2024.11.6-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:9714398225f299aa85267fd222f7142fcb5c769e73d7733344efc46f2ef5cf89"}, + {file = "regex-2024.11.6-cp311-cp311-musllinux_1_2_i686.whl", hash = "sha256:202eb32e89f60fc147a41e55cb086db2a3f8cb82f9a9a88440dcfc5d37faae8d"}, + {file = "regex-2024.11.6-cp311-cp311-musllinux_1_2_ppc64le.whl", hash = "sha256:4181b814e56078e9b00427ca358ec44333765f5ca1b45597ec7446d3a1ef6e34"}, + {file = "regex-2024.11.6-cp311-cp311-musllinux_1_2_s390x.whl", hash = "sha256:068376da5a7e4da51968ce4c122a7cd31afaaec4fccc7856c92f63876e57b51d"}, + {file = "regex-2024.11.6-cp311-cp311-musllinux_1_2_x86_64.whl", hash = "sha256:ac10f2c4184420d881a3475fb2c6f4d95d53a8d50209a2500723d831036f7c45"}, + {file = "regex-2024.11.6-cp311-cp311-win32.whl", hash = "sha256:c36f9b6f5f8649bb251a5f3f66564438977b7ef8386a52460ae77e6070d309d9"}, + {file = "regex-2024.11.6-cp311-cp311-win_amd64.whl", hash = "sha256:02e28184be537f0e75c1f9b2f8847dc51e08e6e171c6bde130b2687e0c33cf60"}, + {file = "regex-2024.11.6-cp312-cp312-macosx_10_13_universal2.whl", hash = "sha256:52fb28f528778f184f870b7cf8f225f5eef0a8f6e3778529bdd40c7b3920796a"}, + {file = "regex-2024.11.6-cp312-cp312-macosx_10_13_x86_64.whl", hash = "sha256:fdd6028445d2460f33136c55eeb1f601ab06d74cb3347132e1c24250187500d9"}, + {file = "regex-2024.11.6-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:805e6b60c54bf766b251e94526ebad60b7de0c70f70a4e6210ee2891acb70bf2"}, + {file = "regex-2024.11.6-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b85c2530be953a890eaffde05485238f07029600e8f098cdf1848d414a8b45e4"}, + {file = "regex-2024.11.6-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:bb26437975da7dc36b7efad18aa9dd4ea569d2357ae6b783bf1118dabd9ea577"}, + {file = "regex-2024.11.6-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:abfa5080c374a76a251ba60683242bc17eeb2c9818d0d30117b4486be10c59d3"}, + {file = "regex-2024.11.6-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:70b7fa6606c2881c1db9479b0eaa11ed5dfa11c8d60a474ff0e095099f39d98e"}, + {file = "regex-2024.11.6-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:0c32f75920cf99fe6b6c539c399a4a128452eaf1af27f39bce8909c9a3fd8cbe"}, + {file = "regex-2024.11.6-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:982e6d21414e78e1f51cf595d7f321dcd14de1f2881c5dc6a6e23bbbbd68435e"}, + {file = "regex-2024.11.6-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:a7c2155f790e2fb448faed6dd241386719802296ec588a8b9051c1f5c481bc29"}, + {file = "regex-2024.11.6-cp312-cp312-musllinux_1_2_ppc64le.whl", hash = "sha256:149f5008d286636e48cd0b1dd65018548944e495b0265b45e1bffecce1ef7f39"}, + {file = "regex-2024.11.6-cp312-cp312-musllinux_1_2_s390x.whl", hash = "sha256:e5364a4502efca094731680e80009632ad6624084aff9a23ce8c8c6820de3e51"}, + {file = "regex-2024.11.6-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:0a86e7eeca091c09e021db8eb72d54751e527fa47b8d5787caf96d9831bd02ad"}, + {file = "regex-2024.11.6-cp312-cp312-win32.whl", hash = "sha256:32f9a4c643baad4efa81d549c2aadefaeba12249b2adc5af541759237eee1c54"}, + {file = "regex-2024.11.6-cp312-cp312-win_amd64.whl", hash = "sha256:a93c194e2df18f7d264092dc8539b8ffb86b45b899ab976aa15d48214138e81b"}, + {file = "regex-2024.11.6-cp313-cp313-macosx_10_13_universal2.whl", hash = "sha256:a6ba92c0bcdf96cbf43a12c717eae4bc98325ca3730f6b130ffa2e3c3c723d84"}, + {file = "regex-2024.11.6-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:525eab0b789891ac3be914d36893bdf972d483fe66551f79d3e27146191a37d4"}, + {file = "regex-2024.11.6-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:086a27a0b4ca227941700e0b31425e7a28ef1ae8e5e05a33826e17e47fbfdba0"}, + {file = "regex-2024.11.6-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:bde01f35767c4a7899b7eb6e823b125a64de314a8ee9791367c9a34d56af18d0"}, + {file = "regex-2024.11.6-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:b583904576650166b3d920d2bcce13971f6f9e9a396c673187f49811b2769dc7"}, + {file = "regex-2024.11.6-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:1c4de13f06a0d54fa0d5ab1b7138bfa0d883220965a29616e3ea61b35d5f5fc7"}, + {file = "regex-2024.11.6-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3cde6e9f2580eb1665965ce9bf17ff4952f34f5b126beb509fee8f4e994f143c"}, + {file = "regex-2024.11.6-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:0d7f453dca13f40a02b79636a339c5b62b670141e63efd511d3f8f73fba162b3"}, + {file = "regex-2024.11.6-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:59dfe1ed21aea057a65c6b586afd2a945de04fc7db3de0a6e3ed5397ad491b07"}, + {file = "regex-2024.11.6-cp313-cp313-musllinux_1_2_i686.whl", hash = "sha256:b97c1e0bd37c5cd7902e65f410779d39eeda155800b65fc4d04cc432efa9bc6e"}, + {file = "regex-2024.11.6-cp313-cp313-musllinux_1_2_ppc64le.whl", hash = "sha256:f9d1e379028e0fc2ae3654bac3cbbef81bf3fd571272a42d56c24007979bafb6"}, + {file = "regex-2024.11.6-cp313-cp313-musllinux_1_2_s390x.whl", hash = "sha256:13291b39131e2d002a7940fb176e120bec5145f3aeb7621be6534e46251912c4"}, + {file = "regex-2024.11.6-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:4f51f88c126370dcec4908576c5a627220da6c09d0bff31cfa89f2523843316d"}, + {file = "regex-2024.11.6-cp313-cp313-win32.whl", hash = "sha256:63b13cfd72e9601125027202cad74995ab26921d8cd935c25f09c630436348ff"}, + {file = "regex-2024.11.6-cp313-cp313-win_amd64.whl", hash = "sha256:2b3361af3198667e99927da8b84c1b010752fa4b1115ee30beaa332cabc3ef1a"}, + {file = "regex-2024.11.6-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5704e174f8ccab2026bd2f1ab6c510345ae8eac818b613d7d73e785f1310f839"}, + {file = "regex-2024.11.6-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:220902c3c5cc6af55d4fe19ead504de80eb91f786dc102fbd74894b1551f095e"}, + {file = "regex-2024.11.6-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:5e7e351589da0850c125f1600a4c4ba3c722efefe16b297de54300f08d734fbf"}, + {file = "regex-2024.11.6-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5056b185ca113c88e18223183aa1a50e66507769c9640a6ff75859619d73957b"}, + {file = "regex-2024.11.6-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:2e34b51b650b23ed3354b5a07aab37034d9f923db2a40519139af34f485f77d0"}, + {file = "regex-2024.11.6-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:5670bce7b200273eee1840ef307bfa07cda90b38ae56e9a6ebcc9f50da9c469b"}, + {file = "regex-2024.11.6-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:08986dce1339bc932923e7d1232ce9881499a0e02925f7402fb7c982515419ef"}, + {file = "regex-2024.11.6-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:93c0b12d3d3bc25af4ebbf38f9ee780a487e8bf6954c115b9f015822d3bb8e48"}, + {file = "regex-2024.11.6-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:764e71f22ab3b305e7f4c21f1a97e1526a25ebdd22513e251cf376760213da13"}, + {file = "regex-2024.11.6-cp39-cp39-musllinux_1_2_aarch64.whl", hash = "sha256:f056bf21105c2515c32372bbc057f43eb02aae2fda61052e2f7622c801f0b4e2"}, + {file = "regex-2024.11.6-cp39-cp39-musllinux_1_2_i686.whl", hash = "sha256:69ab78f848845569401469da20df3e081e6b5a11cb086de3eed1d48f5ed57c95"}, + {file = "regex-2024.11.6-cp39-cp39-musllinux_1_2_ppc64le.whl", hash = "sha256:86fddba590aad9208e2fa8b43b4c098bb0ec74f15718bb6a704e3c63e2cef3e9"}, + {file = "regex-2024.11.6-cp39-cp39-musllinux_1_2_s390x.whl", hash = "sha256:684d7a212682996d21ca12ef3c17353c021fe9de6049e19ac8481ec35574a70f"}, + {file = "regex-2024.11.6-cp39-cp39-musllinux_1_2_x86_64.whl", hash = "sha256:a03e02f48cd1abbd9f3b7e3586d97c8f7a9721c436f51a5245b3b9483044480b"}, + {file = "regex-2024.11.6-cp39-cp39-win32.whl", hash = "sha256:41758407fc32d5c3c5de163888068cfee69cb4c2be844e7ac517a52770f9af57"}, + {file = "regex-2024.11.6-cp39-cp39-win_amd64.whl", hash = "sha256:b2837718570f95dd41675328e111345f9b7095d821bac435aac173ac80b19983"}, + {file = "regex-2024.11.6.tar.gz", hash = "sha256:7ab159b063c52a0333c884e4679f8d7a85112ee3078fe3d9004b2dd875585519"}, ] [[package]] @@ -1496,7 +1509,7 @@ files = [ [[package]] name = "starlette" -version = "0.37.2" +version = "0.41.3" requires_python = ">=3.8" summary = "The little ASGI library that shines." groups = ["default"] @@ -1505,8 +1518,8 @@ dependencies = [ "typing-extensions>=3.10.0; python_version < \"3.10\"", ] files = [ - {file = "starlette-0.37.2-py3-none-any.whl", hash = "sha256:6fe59f29268538e5d0d182f2791a479a0c64638e6935d1c6989e63fb2699c6ee"}, - {file = "starlette-0.37.2.tar.gz", hash = "sha256:9af890290133b79fc3db55474ade20f6220a364a0402e0b556e7cd5e1e093823"}, + {file = "starlette-0.41.3-py3-none-any.whl", hash = "sha256:44cedb2b7c77a9de33a8b74b2b90e9f50d11fcf25d8270ea525ad71a25374ff7"}, + {file = "starlette-0.41.3.tar.gz", hash = "sha256:0e4ab3d16522a255be6b28260b938eae2482f98ce5cc934cb08dce8dc3ba5835"}, ] [[package]] @@ -1522,7 +1535,7 @@ files = [ [[package]] name = "tokenizers" -version = "0.19.1" +version = "0.21.0" requires_python = ">=3.7" summary = "" groups = ["default"] @@ -1530,69 +1543,21 @@ dependencies = [ "huggingface-hub<1.0,>=0.16.4", ] files = [ - {file = "tokenizers-0.19.1-cp310-cp310-macosx_10_12_x86_64.whl", hash = "sha256:952078130b3d101e05ecfc7fc3640282d74ed26bcf691400f872563fca15ac97"}, - {file = "tokenizers-0.19.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:82c8b8063de6c0468f08e82c4e198763e7b97aabfe573fd4cf7b33930ca4df77"}, - {file = "tokenizers-0.19.1-cp310-cp310-manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:f03727225feaf340ceeb7e00604825addef622d551cbd46b7b775ac834c1e1c4"}, - {file = "tokenizers-0.19.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:453e4422efdfc9c6b6bf2eae00d5e323f263fff62b29a8c9cd526c5003f3f642"}, - {file = "tokenizers-0.19.1-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:02e81bf089ebf0e7f4df34fa0207519f07e66d8491d963618252f2e0729e0b46"}, - {file = "tokenizers-0.19.1-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:b07c538ba956843833fee1190cf769c60dc62e1cf934ed50d77d5502194d63b1"}, - {file = "tokenizers-0.19.1-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:e28cab1582e0eec38b1f38c1c1fb2e56bce5dc180acb1724574fc5f47da2a4fe"}, - {file = "tokenizers-0.19.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8b01afb7193d47439f091cd8f070a1ced347ad0f9144952a30a41836902fe09e"}, - {file = "tokenizers-0.19.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:7fb297edec6c6841ab2e4e8f357209519188e4a59b557ea4fafcf4691d1b4c98"}, - {file = "tokenizers-0.19.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:2e8a3dd055e515df7054378dc9d6fa8c8c34e1f32777fb9a01fea81496b3f9d3"}, - {file = "tokenizers-0.19.1-cp310-none-win32.whl", hash = "sha256:7ff898780a155ea053f5d934925f3902be2ed1f4d916461e1a93019cc7250837"}, - {file = "tokenizers-0.19.1-cp310-none-win_amd64.whl", hash = "sha256:bea6f9947e9419c2fda21ae6c32871e3d398cba549b93f4a65a2d369662d9403"}, - {file = "tokenizers-0.19.1-cp311-cp311-macosx_10_12_x86_64.whl", hash = "sha256:5c88d1481f1882c2e53e6bb06491e474e420d9ac7bdff172610c4f9ad3898059"}, - {file = "tokenizers-0.19.1-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:ddf672ed719b4ed82b51499100f5417d7d9f6fb05a65e232249268f35de5ed14"}, - {file = "tokenizers-0.19.1-cp311-cp311-manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dadc509cc8a9fe460bd274c0e16ac4184d0958117cf026e0ea8b32b438171594"}, - {file = "tokenizers-0.19.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dfedf31824ca4915b511b03441784ff640378191918264268e6923da48104acc"}, - {file = "tokenizers-0.19.1-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ac11016d0a04aa6487b1513a3a36e7bee7eec0e5d30057c9c0408067345c48d2"}, - {file = "tokenizers-0.19.1-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:76951121890fea8330d3a0df9a954b3f2a37e3ec20e5b0530e9a0044ca2e11fe"}, - {file = "tokenizers-0.19.1-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:b342d2ce8fc8d00f376af068e3274e2e8649562e3bc6ae4a67784ded6b99428d"}, - {file = "tokenizers-0.19.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d16ff18907f4909dca9b076b9c2d899114dd6abceeb074eca0c93e2353f943aa"}, - {file = "tokenizers-0.19.1-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:706a37cc5332f85f26efbe2bdc9ef8a9b372b77e4645331a405073e4b3a8c1c6"}, - {file = "tokenizers-0.19.1-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:16baac68651701364b0289979ecec728546133e8e8fe38f66fe48ad07996b88b"}, - {file = "tokenizers-0.19.1-cp311-none-win32.whl", hash = "sha256:9ed240c56b4403e22b9584ee37d87b8bfa14865134e3e1c3fb4b2c42fafd3256"}, - {file = "tokenizers-0.19.1-cp311-none-win_amd64.whl", hash = "sha256:ad57d59341710b94a7d9dbea13f5c1e7d76fd8d9bcd944a7a6ab0b0da6e0cc66"}, - {file = "tokenizers-0.19.1-cp312-cp312-macosx_10_12_x86_64.whl", hash = "sha256:621d670e1b1c281a1c9698ed89451395d318802ff88d1fc1accff0867a06f153"}, - {file = "tokenizers-0.19.1-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:d924204a3dbe50b75630bd16f821ebda6a5f729928df30f582fb5aade90c818a"}, - {file = "tokenizers-0.19.1-cp312-cp312-manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:4f3fefdc0446b1a1e6d81cd4c07088ac015665d2e812f6dbba4a06267d1a2c95"}, - {file = "tokenizers-0.19.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9620b78e0b2d52ef07b0d428323fb34e8ea1219c5eac98c2596311f20f1f9266"}, - {file = "tokenizers-0.19.1-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:04ce49e82d100594715ac1b2ce87d1a36e61891a91de774755f743babcd0dd52"}, - {file = "tokenizers-0.19.1-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c5c2ff13d157afe413bf7e25789879dd463e5a4abfb529a2d8f8473d8042e28f"}, - {file = "tokenizers-0.19.1-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:3174c76efd9d08f836bfccaca7cfec3f4d1c0a4cf3acbc7236ad577cc423c840"}, - {file = "tokenizers-0.19.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7c9d5b6c0e7a1e979bec10ff960fae925e947aab95619a6fdb4c1d8ff3708ce3"}, - {file = "tokenizers-0.19.1-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:a179856d1caee06577220ebcfa332af046d576fb73454b8f4d4b0ba8324423ea"}, - {file = "tokenizers-0.19.1-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:952b80dac1a6492170f8c2429bd11fcaa14377e097d12a1dbe0ef2fb2241e16c"}, - {file = "tokenizers-0.19.1-cp312-none-win32.whl", hash = "sha256:01d62812454c188306755c94755465505836fd616f75067abcae529c35edeb57"}, - {file = "tokenizers-0.19.1-cp312-none-win_amd64.whl", hash = "sha256:b70bfbe3a82d3e3fb2a5e9b22a39f8d1740c96c68b6ace0086b39074f08ab89a"}, - {file = "tokenizers-0.19.1-cp39-cp39-macosx_10_12_x86_64.whl", hash = "sha256:0b9394bd204842a2a1fd37fe29935353742be4a3460b6ccbaefa93f58a8df43d"}, - {file = "tokenizers-0.19.1-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:4692ab92f91b87769d950ca14dbb61f8a9ef36a62f94bad6c82cc84a51f76f6a"}, - {file = "tokenizers-0.19.1-cp39-cp39-manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:6258c2ef6f06259f70a682491c78561d492e885adeaf9f64f5389f78aa49a051"}, - {file = "tokenizers-0.19.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c85cf76561fbd01e0d9ea2d1cbe711a65400092bc52b5242b16cfd22e51f0c58"}, - {file = "tokenizers-0.19.1-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:670b802d4d82bbbb832ddb0d41df7015b3e549714c0e77f9bed3e74d42400fbe"}, - {file = "tokenizers-0.19.1-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:85aa3ab4b03d5e99fdd31660872249df5e855334b6c333e0bc13032ff4469c4a"}, - {file = "tokenizers-0.19.1-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:cbf001afbbed111a79ca47d75941e9e5361297a87d186cbfc11ed45e30b5daba"}, - {file = "tokenizers-0.19.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b4c89aa46c269e4e70c4d4f9d6bc644fcc39bb409cb2a81227923404dd6f5227"}, - {file = "tokenizers-0.19.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:39c1ec76ea1027438fafe16ecb0fb84795e62e9d643444c1090179e63808c69d"}, - {file = "tokenizers-0.19.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:c2a0d47a89b48d7daa241e004e71fb5a50533718897a4cd6235cb846d511a478"}, - {file = "tokenizers-0.19.1-cp39-none-win32.whl", hash = "sha256:61b7fe8886f2e104d4caf9218b157b106207e0f2a4905c9c7ac98890688aabeb"}, - {file = "tokenizers-0.19.1-cp39-none-win_amd64.whl", hash = "sha256:f97660f6c43efd3e0bfd3f2e3e5615bf215680bad6ee3d469df6454b8c6e8256"}, - {file = "tokenizers-0.19.1-pp310-pypy310_pp73-macosx_10_12_x86_64.whl", hash = "sha256:3b11853f17b54c2fe47742c56d8a33bf49ce31caf531e87ac0d7d13d327c9334"}, - {file = "tokenizers-0.19.1-pp310-pypy310_pp73-macosx_11_0_arm64.whl", hash = "sha256:d26194ef6c13302f446d39972aaa36a1dda6450bc8949f5eb4c27f51191375bd"}, - {file = "tokenizers-0.19.1-pp310-pypy310_pp73-manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:e8d1ed93beda54bbd6131a2cb363a576eac746d5c26ba5b7556bc6f964425594"}, - {file = "tokenizers-0.19.1-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:ca407133536f19bdec44b3da117ef0d12e43f6d4b56ac4c765f37eca501c7bda"}, - {file = "tokenizers-0.19.1-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ce05fde79d2bc2e46ac08aacbc142bead21614d937aac950be88dc79f9db9022"}, - {file = "tokenizers-0.19.1-pp310-pypy310_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:35583cd46d16f07c054efd18b5d46af4a2f070a2dd0a47914e66f3ff5efb2b1e"}, - {file = "tokenizers-0.19.1-pp310-pypy310_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:43350270bfc16b06ad3f6f07eab21f089adb835544417afda0f83256a8bf8b75"}, - {file = "tokenizers-0.19.1-pp39-pypy39_pp73-macosx_10_12_x86_64.whl", hash = "sha256:56ae39d4036b753994476a1b935584071093b55c7a72e3b8288e68c313ca26e7"}, - {file = "tokenizers-0.19.1-pp39-pypy39_pp73-macosx_11_0_arm64.whl", hash = "sha256:f9939ca7e58c2758c01b40324a59c034ce0cebad18e0d4563a9b1beab3018243"}, - {file = "tokenizers-0.19.1-pp39-pypy39_pp73-manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:6c330c0eb815d212893c67a032e9dc1b38a803eccb32f3e8172c19cc69fbb439"}, - {file = "tokenizers-0.19.1-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:ec11802450a2487cdf0e634b750a04cbdc1c4d066b97d94ce7dd2cb51ebb325b"}, - {file = "tokenizers-0.19.1-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a2b718f316b596f36e1dae097a7d5b91fc5b85e90bf08b01ff139bd8953b25af"}, - {file = "tokenizers-0.19.1-pp39-pypy39_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:ed69af290c2b65169f0ba9034d1dc39a5db9459b32f1dd8b5f3f32a3fcf06eab"}, - {file = "tokenizers-0.19.1-pp39-pypy39_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:f8a9c828277133af13f3859d1b6bf1c3cb6e9e1637df0e45312e6b7c2e622b1f"}, - {file = "tokenizers-0.19.1.tar.gz", hash = "sha256:ee59e6680ed0fdbe6b724cf38bd70400a0c1dd623b07ac729087270caeac88e3"}, + {file = "tokenizers-0.21.0-cp39-abi3-macosx_10_12_x86_64.whl", hash = "sha256:3c4c93eae637e7d2aaae3d376f06085164e1660f89304c0ab2b1d08a406636b2"}, + {file = "tokenizers-0.21.0-cp39-abi3-macosx_11_0_arm64.whl", hash = "sha256:f53ea537c925422a2e0e92a24cce96f6bc5046bbef24a1652a5edc8ba975f62e"}, + {file = "tokenizers-0.21.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6b177fb54c4702ef611de0c069d9169f0004233890e0c4c5bd5508ae05abf193"}, + {file = "tokenizers-0.21.0-cp39-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:6b43779a269f4629bebb114e19c3fca0223296ae9fea8bb9a7a6c6fb0657ff8e"}, + {file = "tokenizers-0.21.0-cp39-abi3-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:9aeb255802be90acfd363626753fda0064a8df06031012fe7d52fd9a905eb00e"}, + {file = "tokenizers-0.21.0-cp39-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:d8b09dbeb7a8d73ee204a70f94fc06ea0f17dcf0844f16102b9f414f0b7463ba"}, + {file = "tokenizers-0.21.0-cp39-abi3-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:400832c0904f77ce87c40f1a8a27493071282f785724ae62144324f171377273"}, + {file = "tokenizers-0.21.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e84ca973b3a96894d1707e189c14a774b701596d579ffc7e69debfc036a61a04"}, + {file = "tokenizers-0.21.0-cp39-abi3-musllinux_1_2_aarch64.whl", hash = "sha256:eb7202d231b273c34ec67767378cd04c767e967fda12d4a9e36208a34e2f137e"}, + {file = "tokenizers-0.21.0-cp39-abi3-musllinux_1_2_armv7l.whl", hash = "sha256:089d56db6782a73a27fd8abf3ba21779f5b85d4a9f35e3b493c7bbcbbf0d539b"}, + {file = "tokenizers-0.21.0-cp39-abi3-musllinux_1_2_i686.whl", hash = "sha256:c87ca3dc48b9b1222d984b6b7490355a6fdb411a2d810f6f05977258400ddb74"}, + {file = "tokenizers-0.21.0-cp39-abi3-musllinux_1_2_x86_64.whl", hash = "sha256:4145505a973116f91bc3ac45988a92e618a6f83eb458f49ea0790df94ee243ff"}, + {file = "tokenizers-0.21.0-cp39-abi3-win32.whl", hash = "sha256:eb1702c2f27d25d9dd5b389cc1f2f51813e99f8ca30d9e25348db6585a97e24a"}, + {file = "tokenizers-0.21.0-cp39-abi3-win_amd64.whl", hash = "sha256:87841da5a25a3a5f70c102de371db120f41873b854ba65e52bccd57df5a3780c"}, + {file = "tokenizers-0.21.0.tar.gz", hash = "sha256:ee0894bf311b75b0c03079f33859ae4b2334d675d4e93f5a4132e1eae2834fe4"}, ] [[package]] @@ -1643,18 +1608,6 @@ files = [ {file = "typing_extensions-4.12.2.tar.gz", hash = "sha256:1a7ead55c7e559dd4dee8856e3a88b41225abfe1ce8df57b7c13915fe121ffb8"}, ] -[[package]] -name = "tzdata" -version = "2024.2" -requires_python = ">=2" -summary = "Provider of IANA time zone data" -groups = ["default"] -marker = "python_version >= \"3.9\"" -files = [ - {file = "tzdata-2024.2-py2.py3-none-any.whl", hash = "sha256:a48093786cdcde33cad18c2555e8532f34422074448fbc874186f0abd79565cd"}, - {file = "tzdata-2024.2.tar.gz", hash = "sha256:7d85cc416e9382e69095b7bdf4afd9e3880418a2413feec7069d533d6b4e31cc"}, -] - [[package]] name = "urllib3" version = "2.2.1" @@ -1668,8 +1621,8 @@ files = [ [[package]] name = "uvicorn" -version = "0.30.6" -requires_python = ">=3.8" +version = "0.34.0" +requires_python = ">=3.9" summary = "The lightning-fast ASGI server." groups = ["default"] dependencies = [ @@ -1678,30 +1631,30 @@ dependencies = [ "typing-extensions>=4.0; python_version < \"3.11\"", ] files = [ - {file = "uvicorn-0.30.6-py3-none-any.whl", hash = "sha256:65fd46fe3fda5bdc1b03b94eb634923ff18cd35b2f084813ea79d1f103f711b5"}, - {file = "uvicorn-0.30.6.tar.gz", hash = "sha256:4b15decdda1e72be08209e860a1e10e92439ad5b97cf44cc945fcbee66fc5788"}, + {file = "uvicorn-0.34.0-py3-none-any.whl", hash = "sha256:023dc038422502fa28a09c7a30bf2b6991512da7dcdb8fd35fe57cfc154126f4"}, + {file = "uvicorn-0.34.0.tar.gz", hash = "sha256:404051050cd7e905de2c9a7e61790943440b3416f49cb409f965d9dcd0fa73e9"}, ] [[package]] name = "uvicorn" -version = "0.30.6" +version = "0.34.0" extras = ["standard"] -requires_python = ">=3.8" +requires_python = ">=3.9" summary = "The lightning-fast ASGI server." groups = ["default"] dependencies = [ "colorama>=0.4; sys_platform == \"win32\"", - "httptools>=0.5.0", + "httptools>=0.6.3", "python-dotenv>=0.13", "pyyaml>=5.1", - "uvicorn==0.30.6", + "uvicorn==0.34.0", "uvloop!=0.15.0,!=0.15.1,>=0.14.0; (sys_platform != \"cygwin\" and sys_platform != \"win32\") and platform_python_implementation != \"PyPy\"", "watchfiles>=0.13", "websockets>=10.4", ] files = [ - {file = "uvicorn-0.30.6-py3-none-any.whl", hash = "sha256:65fd46fe3fda5bdc1b03b94eb634923ff18cd35b2f084813ea79d1f103f711b5"}, - {file = "uvicorn-0.30.6.tar.gz", hash = "sha256:4b15decdda1e72be08209e860a1e10e92439ad5b97cf44cc945fcbee66fc5788"}, + {file = "uvicorn-0.34.0-py3-none-any.whl", hash = "sha256:023dc038422502fa28a09c7a30bf2b6991512da7dcdb8fd35fe57cfc154126f4"}, + {file = "uvicorn-0.34.0.tar.gz", hash = "sha256:404051050cd7e905de2c9a7e61790943440b3416f49cb409f965d9dcd0fa73e9"}, ] [[package]] diff --git a/playground/augment-image.py b/playground/augment-image.py index aaa51d9..273ef24 100644 --- a/playground/augment-image.py +++ b/playground/augment-image.py @@ -2,7 +2,7 @@ # @Time : 2024/1/26 下午12:23 # @Author : sudoskys # @File : __init__.py.py -# @Software: PyCharm + import asyncio import os import pathlib diff --git a/playground/enhance.py b/playground/enhance.py index 0828e49..da10702 100755 --- a/playground/enhance.py +++ b/playground/enhance.py @@ -2,7 +2,7 @@ # @Time : 2024/2/13 下午1:58 # @Author : sudoskys # @File : enhance.py -# @Software: PyCharm + from loguru import logger # NOTE About Enhance Mode diff --git a/playground/generate_image.py b/playground/generate_image.py index 9fdbb4b..c034a6e 100755 --- a/playground/generate_image.py +++ b/playground/generate_image.py @@ -2,7 +2,7 @@ # @Time : 2024/1/26 下午12:23 # @Author : sudoskys # @File : __init__.py.py -# @Software: PyCharm + import asyncio import os import pathlib diff --git a/playground/generate_image_img2img.py b/playground/generate_image_img2img.py index 07a9543..375f852 100755 --- a/playground/generate_image_img2img.py +++ b/playground/generate_image_img2img.py @@ -2,7 +2,7 @@ # @Time : 2024/2/9 下午10:04 # @Author : sudoskys # @File : generate_image_img2img.py -# @Software: PyCharm + import asyncio import base64 import os diff --git a/playground/information.py b/playground/information.py index f482f4c..0729e89 100755 --- a/playground/information.py +++ b/playground/information.py @@ -2,7 +2,7 @@ # @Time : 2024/2/8 下午4:34 # @Author : sudoskys # @File : information.py -# @Software: PyCharm + import asyncio import os diff --git a/playground/login.py b/playground/login.py index 36281aa..17c9081 100755 --- a/playground/login.py +++ b/playground/login.py @@ -2,7 +2,7 @@ # @Time : 2024/2/7 下午12:07 # @Author : sudoskys # @File : login.py -# @Software: PyCharm + import asyncio import os diff --git a/playground/paint_mask/__init__.py b/playground/paint_mask/__init__.py index 09e3d7c..d9a6f71 100644 --- a/playground/paint_mask/__init__.py +++ b/playground/paint_mask/__init__.py @@ -2,7 +2,7 @@ # @Time : 2024/2/13 下午12:42 # @Author : sudoskys # @File : __init__.py.py -# @Software: PyCharm + from novelai_python.tool.paint_mask import create_mask_from_sketch with open('sk.jpg', 'rb') as f: diff --git a/playground/random_prompt.py b/playground/random_prompt.py index cf0239d..2564281 100755 --- a/playground/random_prompt.py +++ b/playground/random_prompt.py @@ -2,7 +2,7 @@ # @Time : 2024/2/7 下午12:51 # @Author : sudoskys # @File : random_prompt.py -# @Software: PyCharm + from novelai_python.tool.random_prompt import RandomPromptGenerator diff --git a/playground/subscription.py b/playground/subscription.py index 6ecbdc8..68df3f4 100755 --- a/playground/subscription.py +++ b/playground/subscription.py @@ -2,7 +2,7 @@ # @Time : 2024/2/7 上午10:16 # @Author : sudoskys # @File : subscription.py -# @Software: PyCharm + import asyncio import os diff --git a/playground/suggest_tag.py b/playground/suggest_tag.py index 68ace47..3d16ed4 100755 --- a/playground/suggest_tag.py +++ b/playground/suggest_tag.py @@ -2,7 +2,7 @@ # @Time : 2024/2/13 下午8:25 # @Author : sudoskys # @File : suggest_tag.py -# @Software: PyCharm + import asyncio import os diff --git a/playground/upscale.py b/playground/upscale.py index 1a41e09..0e5019e 100755 --- a/playground/upscale.py +++ b/playground/upscale.py @@ -2,12 +2,12 @@ # @Time : 2024/2/13 上午11:58 # @Author : sudoskys # @File : upscale.py -# @Software: PyCharm + # -*- coding: utf-8 -*- # @Time : 2024/2/14 下午5:20 # @Author : sudoskys # @File : upscale_demo.py -# @Software: PyCharm + # To run the demo, you need an event loop, for instance by using asyncio import asyncio import os diff --git a/src/novelai_python/_response/__init__.py b/src/novelai_python/_response/__init__.py index 24b1b3d..22f67b1 100755 --- a/src/novelai_python/_response/__init__.py +++ b/src/novelai_python/_response/__init__.py @@ -2,7 +2,7 @@ # @Time : 2024/1/26 上午10:51 # @Author : sudoskys # @File : __init__.py.py -# @Software: PyCharm + from .ai.generate_image import ImageGenerateResp from .user.information import InformationResp from .user.login import LoginResp diff --git a/src/novelai_python/_response/ai/__init__.py b/src/novelai_python/_response/ai/__init__.py index 1b4f261..8e25ae8 100755 --- a/src/novelai_python/_response/ai/__init__.py +++ b/src/novelai_python/_response/ai/__init__.py @@ -2,4 +2,4 @@ # @Time : 2024/1/26 上午11:20 # @Author : sudoskys # @File : __init__.py -# @Software: PyCharm + diff --git a/src/novelai_python/_response/ai/generate_image.py b/src/novelai_python/_response/ai/generate_image.py index 32a9dfb..20f21b9 100755 --- a/src/novelai_python/_response/ai/generate_image.py +++ b/src/novelai_python/_response/ai/generate_image.py @@ -2,7 +2,7 @@ # @Time : 2024/1/26 上午11:16 # @Author : sudoskys # @File : text2image.py -# @Software: PyCharm + from typing import Tuple, List from pydantic import BaseModel diff --git a/src/novelai_python/_response/ai/upscale.py b/src/novelai_python/_response/ai/upscale.py index fa56421..5a78acf 100755 --- a/src/novelai_python/_response/ai/upscale.py +++ b/src/novelai_python/_response/ai/upscale.py @@ -2,7 +2,7 @@ # @Time : 2024/2/13 上午11:29 # @Author : sudoskys # @File : upscale.py -# @Software: PyCharm + from typing import Tuple from pydantic import BaseModel diff --git a/src/novelai_python/_response/schema.py b/src/novelai_python/_response/schema.py index d978b90..8f00724 100755 --- a/src/novelai_python/_response/schema.py +++ b/src/novelai_python/_response/schema.py @@ -2,7 +2,7 @@ # @Time : 2024/2/13 上午11:30 # @Author : sudoskys # @File : schema.py -# @Software: PyCharm + from pydantic import BaseModel diff --git a/src/novelai_python/_response/user/__init__.py b/src/novelai_python/_response/user/__init__.py index 3cbe0b7..1262a03 100755 --- a/src/novelai_python/_response/user/__init__.py +++ b/src/novelai_python/_response/user/__init__.py @@ -2,4 +2,4 @@ # @Time : 2024/2/7 上午9:57 # @Author : sudoskys # @File : __init__.py.py -# @Software: PyCharm + diff --git a/src/novelai_python/_response/user/information.py b/src/novelai_python/_response/user/information.py index 939a633..a0c10d0 100755 --- a/src/novelai_python/_response/user/information.py +++ b/src/novelai_python/_response/user/information.py @@ -2,7 +2,7 @@ # @Time : 2024/2/8 下午3:10 # @Author : sudoskys # @File : information.py -# @Software: PyCharm + from pydantic import Field diff --git a/src/novelai_python/_response/user/login.py b/src/novelai_python/_response/user/login.py index 745fa5a..76ebfe5 100755 --- a/src/novelai_python/_response/user/login.py +++ b/src/novelai_python/_response/user/login.py @@ -2,7 +2,7 @@ # @Time : 2024/2/7 上午11:57 # @Author : sudoskys # @File : login.py -# @Software: PyCharm + from ..schema import RespBase diff --git a/src/novelai_python/_response/user/subscription.py b/src/novelai_python/_response/user/subscription.py index 4ab9d29..48522a2 100755 --- a/src/novelai_python/_response/user/subscription.py +++ b/src/novelai_python/_response/user/subscription.py @@ -2,7 +2,7 @@ # @Time : 2024/2/7 上午9:57 # @Author : sudoskys # @File : subscription.py -# @Software: PyCharm + from typing import Optional, Dict, Any, List from pydantic import BaseModel, Field diff --git a/src/novelai_python/credential/ApiToken.py b/src/novelai_python/credential/ApiToken.py index 3b44e3a..5b8eff0 100755 --- a/src/novelai_python/credential/ApiToken.py +++ b/src/novelai_python/credential/ApiToken.py @@ -2,7 +2,7 @@ # @Time : 2024/2/8 下午3:05 # @Author : sudoskys # @File : ApiToken.py -# @Software: PyCharm + import arrow import shortuuid diff --git a/src/novelai_python/credential/JwtToken.py b/src/novelai_python/credential/JwtToken.py index d2710f0..6dd2b57 100755 --- a/src/novelai_python/credential/JwtToken.py +++ b/src/novelai_python/credential/JwtToken.py @@ -2,7 +2,7 @@ # @Time : 2024/1/26 上午11:04 # @Author : sudoskys # @File : JwtToken.py -# @Software: PyCharm + import arrow import shortuuid diff --git a/src/novelai_python/credential/__init__.py b/src/novelai_python/credential/__init__.py index b789bfc..455dc93 100755 --- a/src/novelai_python/credential/__init__.py +++ b/src/novelai_python/credential/__init__.py @@ -2,7 +2,7 @@ # @Time : 2024/1/26 上午10:51 # @Author : sudoskys # @File : __init__.py.py -# @Software: PyCharm + from pydantic import SecretStr from .ApiToken import ApiCredential diff --git a/src/novelai_python/credential/_base.py b/src/novelai_python/credential/_base.py index 94ec5d6..658163d 100755 --- a/src/novelai_python/credential/_base.py +++ b/src/novelai_python/credential/_base.py @@ -2,7 +2,7 @@ # @Time : 2024/2/7 下午12:14 # @Author : sudoskys # @File : _shema.py -# @Software: PyCharm + from curl_cffi.requests import AsyncSession from fake_useragent import UserAgent from pydantic import BaseModel diff --git a/src/novelai_python/sdk/__init__.py b/src/novelai_python/sdk/__init__.py index 33da641..2474e9d 100755 --- a/src/novelai_python/sdk/__init__.py +++ b/src/novelai_python/sdk/__init__.py @@ -2,7 +2,7 @@ # @Time : 2024/1/26 上午10:51 # @Author : sudoskys # @File : __init__.py.py -# @Software: PyCharm + from .ai.augment_image import AugmentImageInfer # noqa 401 from .ai.generate import LLM, LLMResp # noqa 401 diff --git a/src/novelai_python/sdk/ai/__init__.py b/src/novelai_python/sdk/ai/__init__.py index b80a14a..909bb94 100755 --- a/src/novelai_python/sdk/ai/__init__.py +++ b/src/novelai_python/sdk/ai/__init__.py @@ -2,4 +2,4 @@ # @Time : 2024/1/26 上午11:20 # @Author : sudoskys # @File : __init__.py.py -# @Software: PyCharm + diff --git a/src/novelai_python/sdk/ai/_enum.py b/src/novelai_python/sdk/ai/_enum.py index 233a285..3de02ac 100644 --- a/src/novelai_python/sdk/ai/_enum.py +++ b/src/novelai_python/sdk/ai/_enum.py @@ -2,7 +2,6 @@ # @Time : 2024/2/13 下午8:10 # @Author : sudoskys # @File : _enum.py -# @Software: PyCharm from enum import Enum, IntEnum from typing import List, Optional, Union diff --git a/src/novelai_python/sdk/ai/augment_image/__init__.py b/src/novelai_python/sdk/ai/augment_image/__init__.py index 11060bd..326c838 100644 --- a/src/novelai_python/sdk/ai/augment_image/__init__.py +++ b/src/novelai_python/sdk/ai/augment_image/__init__.py @@ -2,7 +2,7 @@ # @Time : 2024/2/13 下午8:08 # @Author : sudoskys # @File : __init__.py.py -# @Software: PyCharm + import base64 import io import json diff --git a/src/novelai_python/sdk/ai/generate_image/suggest_tags.py b/src/novelai_python/sdk/ai/generate_image/suggest_tags.py index 20bbc52..f6d4db8 100755 --- a/src/novelai_python/sdk/ai/generate_image/suggest_tags.py +++ b/src/novelai_python/sdk/ai/generate_image/suggest_tags.py @@ -2,7 +2,7 @@ # @Time : 2024/2/13 下午8:09 # @Author : sudoskys # @File : suggest-tags.py -# @Software: PyCharm + from typing import Optional, Union from urllib.parse import urlparse diff --git a/src/novelai_python/sdk/ai/upscale.py b/src/novelai_python/sdk/ai/upscale.py index 00a8dbf..fc37533 100755 --- a/src/novelai_python/sdk/ai/upscale.py +++ b/src/novelai_python/sdk/ai/upscale.py @@ -2,7 +2,6 @@ # @Time : 2024/2/13 上午10:48 # @Author : sudoskys # @File : upscale.py -# @Software: PyCharm import base64 import json from io import BytesIO diff --git a/src/novelai_python/sdk/schema.py b/src/novelai_python/sdk/schema.py index 4de920e..e3afbc4 100755 --- a/src/novelai_python/sdk/schema.py +++ b/src/novelai_python/sdk/schema.py @@ -2,7 +2,7 @@ # @Time : 2024/2/10 上午11:15 # @Author : sudoskys # @File : schema.py -# @Software: PyCharm + from abc import ABC, abstractmethod from typing import Optional, Union diff --git a/src/novelai_python/sdk/user/__init__.py b/src/novelai_python/sdk/user/__init__.py index 83548fc..ee61515 100755 --- a/src/novelai_python/sdk/user/__init__.py +++ b/src/novelai_python/sdk/user/__init__.py @@ -2,5 +2,5 @@ # @Time : 2024/2/7 上午10:03 # @Author : sudoskys # @File : __init__.py.py -# @Software: PyCharm + diff --git a/src/novelai_python/sdk/user/information.py b/src/novelai_python/sdk/user/information.py index db30c0e..ba7511f 100755 --- a/src/novelai_python/sdk/user/information.py +++ b/src/novelai_python/sdk/user/information.py @@ -2,7 +2,7 @@ # @Time : 2024/2/8 下午3:09 # @Author : sudoskys # @File : information.py -# @Software: PyCharm + from typing import Optional, Union from urllib.parse import urlparse diff --git a/src/novelai_python/sdk/user/login.py b/src/novelai_python/sdk/user/login.py index f88f5bf..2168cde 100755 --- a/src/novelai_python/sdk/user/login.py +++ b/src/novelai_python/sdk/user/login.py @@ -2,7 +2,7 @@ # @Time : 2024/2/7 上午11:46 # @Author : sudoskys # @File : login.py -# @Software: PyCharm + import json from typing import Optional, Union diff --git a/src/novelai_python/sdk/user/subscription.py b/src/novelai_python/sdk/user/subscription.py index a149aad..3cc3299 100755 --- a/src/novelai_python/sdk/user/subscription.py +++ b/src/novelai_python/sdk/user/subscription.py @@ -2,7 +2,7 @@ # @Time : 2024/2/7 上午10:04 # @Author : sudoskys # @File : subscription.py.py -# @Software: PyCharm + from typing import Optional, Union from urllib.parse import urlparse diff --git a/src/novelai_python/tool/random_prompt/tag.py b/src/novelai_python/tool/random_prompt/tag.py index f1d93fd..347d569 100644 --- a/src/novelai_python/tool/random_prompt/tag.py +++ b/src/novelai_python/tool/random_prompt/tag.py @@ -2,7 +2,7 @@ # @Time : 2024/1/26 下午2:00 # @Author : sudoskys # @File : tag.py -# @Software: PyCharm + cameraPerspective = [ ['dutch angle', diff --git a/src/novelai_python/tool/random_prompt/tag_character.py b/src/novelai_python/tool/random_prompt/tag_character.py index eee8025..4c15f6d 100644 --- a/src/novelai_python/tool/random_prompt/tag_character.py +++ b/src/novelai_python/tool/random_prompt/tag_character.py @@ -2,7 +2,7 @@ # @Time : 2024/2/7 下午5:56 # @Author : sudoskys # @File : tag_character.py -# @Software: PyCharm + rankCharacter = [ ['futanari-sama_(mdf_an)', 10], diff --git a/src/novelai_python/tool/random_prompt/tag_nsfw.py b/src/novelai_python/tool/random_prompt/tag_nsfw.py index f27fcb6..cd54b1a 100644 --- a/src/novelai_python/tool/random_prompt/tag_nsfw.py +++ b/src/novelai_python/tool/random_prompt/tag_nsfw.py @@ -2,7 +2,7 @@ # @Time : 2024/1/26 下午2:03 # @Author : sudoskys # @File : nsfw.py -# @Software: PyCharm + nsfw = { "pussy": [ [ diff --git a/src/novelai_python/utils/__init__.py b/src/novelai_python/utils/__init__.py index dcebdf2..a71f83c 100755 --- a/src/novelai_python/utils/__init__.py +++ b/src/novelai_python/utils/__init__.py @@ -2,7 +2,7 @@ # @Time : 2024/1/26 上午10:51 # @Author : sudoskys # @File : __init__.py.py -# @Software: PyCharm + import json from typing import Union diff --git a/src/novelai_python/utils/useful.py b/src/novelai_python/utils/useful.py index 5a4a7e2..be5f632 100755 --- a/src/novelai_python/utils/useful.py +++ b/src/novelai_python/utils/useful.py @@ -2,7 +2,7 @@ # @Time : 2024/2/9 下午10:41 # @Author : sudoskys # @File : useful.py -# @Software: PyCharm + import collections import random from typing import List, Union diff --git a/tests/test_random_prompt.py b/tests/test_random_prompt.py index aa8bfb6..d0c6930 100755 --- a/tests/test_random_prompt.py +++ b/tests/test_random_prompt.py @@ -2,7 +2,7 @@ # @Time : 2024/1/27 上午10:41 # @Author : sudoskys # @File : test_random_prompt.py -# @Software: PyCharm + from novelai_python.tool.random_prompt import RandomPromptGenerator diff --git a/tests/test_server.py b/tests/test_server.py index e29a451..09263c4 100755 --- a/tests/test_server.py +++ b/tests/test_server.py @@ -2,14 +2,19 @@ # @Time : 2024/1/22 下午11:50 # @Author : sudoskys # @File : test_server.py -# @Software: PyCharm + from novelai_python import GenerateImageInfer +from novelai_python.sdk.ai.generate_image import Model def test_nai(): try: - gen = GenerateImageInfer.build(prompt="1girl", steps=29) + gen = GenerateImageInfer.build_generate( + prompt="1girl", + steps=29, + model=Model.NAI_DIFFUSION_3, + ) gen.validate_charge() except Exception as e: print(e) diff --git a/tests/test_server_run.py b/tests/test_server_run.py index 3ee7c3b..dfebaef 100755 --- a/tests/test_server_run.py +++ b/tests/test_server_run.py @@ -2,7 +2,7 @@ # @Time : 2024/1/30 下午11:52 # @Author : sudoskys # @File : test_server_run.py -# @Software: PyCharm + from unittest.mock import patch diff --git a/tests/test_upscale.py b/tests/test_upscale.py index 8089263..2e3245b 100755 --- a/tests/test_upscale.py +++ b/tests/test_upscale.py @@ -2,12 +2,12 @@ # @Time : 2024/2/13 下午12:03 # @Author : sudoskys # @File : test_upscale.py -# @Software: PyCharm + # -*- coding: utf-8 -*- # @Time : 2024/2/14 下午4:20 # @Author : sudoskys # @File : test_upscale.py -# @Software: PyCharm + from unittest import mock from unittest.mock import AsyncMock, Mock diff --git a/tests/test_user_information.py b/tests/test_user_information.py index ded8181..96ce480 100755 --- a/tests/test_user_information.py +++ b/tests/test_user_information.py @@ -2,7 +2,7 @@ # @Time : 2024/2/8 下午3:17 # @Author : sudoskys # @File : test_information.py -# @Software: PyCharm + from unittest import mock import pytest diff --git a/tests/test_user_login.py b/tests/test_user_login.py index 8fca9d4..ee1bc89 100755 --- a/tests/test_user_login.py +++ b/tests/test_user_login.py @@ -2,7 +2,7 @@ # @Time : 2024/2/8 下午4:20 # @Author : sudoskys # @File : test_login.py -# @Software: PyCharm + from unittest import mock import pytest diff --git a/tests/test_user_subscription.py b/tests/test_user_subscription.py index 39b5528..a6c2164 100755 --- a/tests/test_user_subscription.py +++ b/tests/test_user_subscription.py @@ -2,7 +2,7 @@ # @Time : 2024/2/8 下午4:31 # @Author : sudoskys # @File : test_subscription.py -# @Software: PyCharm + from unittest import mock import pytest From 54221f99804b53785ac326191aafd2eb907fa0e2 Mon Sep 17 00:00:00 2001 From: sudoskys Date: Sat, 21 Dec 2024 23:36:02 +0800 Subject: [PATCH 4/8] format all files --- src/novelai_python/credential/UserAuth.py | 2 +- .../sdk/ai/generate/__init__.py | 1 + src/novelai_python/sdk/ai/generate/_schema.py | 32 ++++++++++--------- .../sdk/ai/generate_image/schema.py | 2 +- .../tokenizer/clip_simple_tokenizer.py | 5 +-- 5 files changed, 23 insertions(+), 19 deletions(-) diff --git a/src/novelai_python/credential/UserAuth.py b/src/novelai_python/credential/UserAuth.py index bc0ac08..f4e1a78 100755 --- a/src/novelai_python/credential/UserAuth.py +++ b/src/novelai_python/credential/UserAuth.py @@ -19,7 +19,7 @@ class LoginCredential(CredentialBase): """ username: str = Field(None, description="username") password: SecretStr = Field(None, description="password") - _session_headers: dict = {} + _session_headers: dict = Field(default_factory=dict) _update_at: Optional[int] = None _x_correlation_id: str = shortuuid.uuid()[0:6] diff --git a/src/novelai_python/sdk/ai/generate/__init__.py b/src/novelai_python/sdk/ai/generate/__init__.py index e01b172..b497f46 100644 --- a/src/novelai_python/sdk/ai/generate/__init__.py +++ b/src/novelai_python/sdk/ai/generate/__init__.py @@ -306,6 +306,7 @@ def build(cls, ) -> "LLM": """ Generate + :param phrase_rep_pen: Phrase_rep_pen :param prompt: prompt, exp "Hello, World!" :param model: TextLLMModelTypeAlias :param advanced_setting: AdvanceLLMSetting, default None means auto-select diff --git a/src/novelai_python/sdk/ai/generate/_schema.py b/src/novelai_python/sdk/ai/generate/_schema.py index c8e460a..c5ffdae 100644 --- a/src/novelai_python/sdk/ai/generate/_schema.py +++ b/src/novelai_python/sdk/ai/generate/_schema.py @@ -92,7 +92,7 @@ class AdvanceLLMSetting(BaseModel): prefix: Optional[str] = "" logit_bias_exp: Optional[List[LogitBiasGroup]] = None num_logprobs: Optional[int] = None - order: List[int] = [] + order: List[int] = Field(default_factory=list) bracket_ban: Optional[bool] = True model_config = ConfigDict(extra="allow") @@ -116,7 +116,7 @@ class LLMGenerationParams(BaseModel): eos_token_id: int = None bad_words_ids: List[List[int]] = None - logit_bias_groups: Optional[List[LogitBiasGroup]] = [] + logit_bias_groups: Optional[List[LogitBiasGroup]] = Field(default_factory=list) repetition_penalty_frequency: Optional[Union[float, int]] = Field(default=None, allow_inf_nan=False) repetition_penalty_presence: Optional[Union[float, int]] = Field(default=None, allow_inf_nan=False) @@ -133,19 +133,21 @@ class LLMGenerationParams(BaseModel): math1_quad_entropy_scale: Optional[Union[float, int]] = Field(default=None, allow_inf_nan=False) min_p: Optional[Union[float, int]] = Field(default=None, allow_inf_nan=False) - order: Union[List[int], List[KeyOrderEntry]] = [ - KeyOrderEntry(id=Key.Cfg, enabled=False), - KeyOrderEntry(id=Key.Temperature, enabled=True), - KeyOrderEntry(id=Key.TopK, enabled=True), - KeyOrderEntry(id=Key.TopP, enabled=True), - KeyOrderEntry(id=Key.TFS, enabled=True), - KeyOrderEntry(id=Key.TopA, enabled=False), - KeyOrderEntry(id=Key.TypicalP, enabled=False), - KeyOrderEntry(id=Key.TopG, enabled=False), - KeyOrderEntry(id=Key.Mirostat, enabled=False), - KeyOrderEntry(id=Key.Math1, enabled=False), - KeyOrderEntry(id=Key.MinP, enabled=False), - ] + order: Union[List[int], List[KeyOrderEntry]] = Field( + default=[ + KeyOrderEntry(id=Key.Cfg, enabled=False), + KeyOrderEntry(id=Key.Temperature, enabled=True), + KeyOrderEntry(id=Key.TopK, enabled=True), + KeyOrderEntry(id=Key.TopP, enabled=True), + KeyOrderEntry(id=Key.TFS, enabled=True), + KeyOrderEntry(id=Key.TopA, enabled=False), + KeyOrderEntry(id=Key.TypicalP, enabled=False), + KeyOrderEntry(id=Key.TopG, enabled=False), + KeyOrderEntry(id=Key.Mirostat, enabled=False), + KeyOrderEntry(id=Key.Math1, enabled=False), + KeyOrderEntry(id=Key.MinP, enabled=False), + ] + ) def get_base_map(self): parameters = self.model_dump(mode="json", exclude_none=True) diff --git a/src/novelai_python/sdk/ai/generate_image/schema.py b/src/novelai_python/sdk/ai/generate_image/schema.py index db8a7d6..e302343 100644 --- a/src/novelai_python/sdk/ai/generate_image/schema.py +++ b/src/novelai_python/sdk/ai/generate_image/schema.py @@ -77,7 +77,7 @@ class CharCaption(BaseModel): class Caption(BaseModel): base_caption: str = Field("", description="Main Prompt") """Main Prompt""" - char_captions: List[CharCaption] = Field([], description="Character Captions") + char_captions: List[CharCaption] = Field(default_factory=list, description="Character Captions") """Character Captions""" diff --git a/src/novelai_python/tokenizer/clip_simple_tokenizer.py b/src/novelai_python/tokenizer/clip_simple_tokenizer.py index 41197d2..0942ff5 100644 --- a/src/novelai_python/tokenizer/clip_simple_tokenizer.py +++ b/src/novelai_python/tokenizer/clip_simple_tokenizer.py @@ -105,11 +105,12 @@ def bpe(self, token): new_word = [] i = 0 while i < len(word): + # noinspection PyBroadException try: j = word.index(first, i) new_word.extend(word[i:j]) i = j - except: + except Exception: new_word.extend(word[i:]) break @@ -151,4 +152,4 @@ def get_vocab(self): if __name__ == '__main__': tokenizer = SimpleTokenizer() - print(len(tokenizer.get_vocab())) \ No newline at end of file + print(len(tokenizer.get_vocab())) From d43578b739cbdf61b729be4997033a5fe7ba0dd5 Mon Sep 17 00:00:00 2001 From: sudoskys Date: Sat, 21 Dec 2024 23:42:28 +0800 Subject: [PATCH 5/8] =?UTF-8?q?=F0=9F=94=A7=20refactor(credential):=20remo?= =?UTF-8?q?ve=20underscore=20from=20private=20variables?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Refactored variable names in credential classes to remove leading underscores for consistency and clarity. Updated related imports and usages across the project. --- playground/generate_image.py | 3 +-- playground/vibe_inpaint.py | 6 +++--- src/novelai_python/credential/ApiToken.py | 4 ++-- src/novelai_python/credential/JwtToken.py | 4 ++-- src/novelai_python/credential/UserAuth.py | 16 ++++++++-------- 5 files changed, 16 insertions(+), 17 deletions(-) diff --git a/playground/generate_image.py b/playground/generate_image.py index c034a6e..a770c36 100755 --- a/playground/generate_image.py +++ b/playground/generate_image.py @@ -12,8 +12,7 @@ from novelai_python import APIError, LoginCredential from novelai_python import GenerateImageInfer, ImageGenerateResp, JwtCredential -from novelai_python.sdk.ai._enum import UCPreset -from novelai_python.sdk.ai.generate_image import Action, Model, Sampler, Character +from novelai_python.sdk.ai.generate_image import Action, Model, Sampler, Character, UCPreset from novelai_python.sdk.ai.generate_image.schema import PositionMap from novelai_python.utils.useful import enum_to_list diff --git a/playground/vibe_inpaint.py b/playground/vibe_inpaint.py index 394483b..358c740 100644 --- a/playground/vibe_inpaint.py +++ b/playground/vibe_inpaint.py @@ -6,8 +6,8 @@ from dotenv import load_dotenv from pydantic import SecretStr -from novelai_python import APIError, Login -from novelai_python import GenerateImageInfer, ImageGenerateResp, JwtCredential +from novelai_python import APIError, Login, ApiCredential +from novelai_python import GenerateImageInfer, ImageGenerateResp from novelai_python.sdk.ai.generate_image import Action, Sampler, Model from novelai_python.tool.paint_mask import create_mask_from_sketch from novelai_python.utils.useful import enum_to_list @@ -35,7 +35,7 @@ async def generate( jwt = os.getenv("NOVELAI_JWT", None) if jwt is None: raise ValueError("NOVELAI_JWT is not set in `.env` file, please create one and set it") - credential = JwtCredential(jwt_token=SecretStr(jwt)) + credential = ApiCredential(api_token=SecretStr(jwt)) """Or you can use the login credential to get the jwt token""" _login_credential = Login.build( user_name=os.getenv("NOVELAI_USER"), diff --git a/src/novelai_python/credential/ApiToken.py b/src/novelai_python/credential/ApiToken.py index 5b8eff0..af16e8e 100755 --- a/src/novelai_python/credential/ApiToken.py +++ b/src/novelai_python/credential/ApiToken.py @@ -18,7 +18,7 @@ class ApiCredential(CredentialBase): ApiCredential is the base class for all credential. """ api_token: SecretStr = Field(None, description="api token") - _x_correlation_id: str = shortuuid.uuid()[0:6] + x_correlation_id: str = shortuuid.uuid()[0:6] async def get_session(self, timeout: int = 180, update_headers: dict = None): headers = { @@ -29,7 +29,7 @@ async def get_session(self, timeout: int = 180, update_headers: dict = None): "Content-Type": "application/json", "Origin": "https://novelai.net", "Referer": "https://novelai.net/", - "x-correlation-id": self._x_correlation_id, + "x-correlation-id": self.x_correlation_id, "x-initiated-at": f"{arrow.utcnow().isoformat()}Z", } diff --git a/src/novelai_python/credential/JwtToken.py b/src/novelai_python/credential/JwtToken.py index 6dd2b57..6fcfc50 100755 --- a/src/novelai_python/credential/JwtToken.py +++ b/src/novelai_python/credential/JwtToken.py @@ -18,7 +18,7 @@ class JwtCredential(CredentialBase): JwtCredential is the base class for all credential. """ jwt_token: SecretStr = Field(None, description="jwt token") - _x_correlation_id: str = shortuuid.uuid()[0:6] + x_correlation_id: str = shortuuid.uuid()[0:6] async def get_session(self, timeout: int = 180, update_headers: dict = None): headers = { @@ -29,7 +29,7 @@ async def get_session(self, timeout: int = 180, update_headers: dict = None): "Content-Type": "application/json", "Origin": "https://novelai.net", "Referer": "https://novelai.net/", - "x-correlation-id": self._x_correlation_id, + "x-correlation-id": self.x_correlation_id, "x-initiated-at": f"{arrow.utcnow().isoformat()}Z", } diff --git a/src/novelai_python/credential/UserAuth.py b/src/novelai_python/credential/UserAuth.py index f4e1a78..61c7925 100755 --- a/src/novelai_python/credential/UserAuth.py +++ b/src/novelai_python/credential/UserAuth.py @@ -19,9 +19,9 @@ class LoginCredential(CredentialBase): """ username: str = Field(None, description="username") password: SecretStr = Field(None, description="password") - _session_headers: dict = Field(default_factory=dict) - _update_at: Optional[int] = None - _x_correlation_id: str = shortuuid.uuid()[0:6] + session_headers: dict = Field(default_factory=dict) + update_at: Optional[int] = None + x_correlation_id: str = shortuuid.uuid()[0:6] async def get_session(self, timeout: int = 180, update_headers: dict = None): headers = { @@ -32,19 +32,19 @@ async def get_session(self, timeout: int = 180, update_headers: dict = None): "Content-Type": "application/json", "Origin": "https://novelai.net", "Referer": "https://novelai.net/", - "x-correlation-id": self._x_correlation_id, + "x-correlation-id": self.x_correlation_id, "x-initiated-at": f"{arrow.utcnow().isoformat()}Z", } # 30 天有效期 - if not self._session_headers or int(time.time()) - self._update_at > 29 * 24 * 60 * 60: + if not self.session_headers or int(time.time()) - self.update_at > 29 * 24 * 60 * 60: from ..sdk import Login resp = await Login.build(user_name=self.username, password=self.password.get_secret_value()).request() headers["Authorization"] = f"Bearer {resp.accessToken}" - self._session_headers = headers - self._update_at = int(time.time()) + self.session_headers = headers + self.update_at = int(time.time()) else: - headers.update(self._session_headers) + headers.update(self.session_headers) if update_headers: headers.update(update_headers) From 4246b7fbda065d02a7369e0764a257380fd5ecf3 Mon Sep 17 00:00:00 2001 From: sudoskys Date: Sat, 21 Dec 2024 23:45:57 +0800 Subject: [PATCH 6/8] =?UTF-8?q?=F0=9F=94=A7=20refactor(credential):=20remo?= =?UTF-8?q?ve=20underscore=20from=20private=20variables?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Refactored variable names in credential classes to remove leading underscores for consistency and clarity. Updated related imports and usages across the project. --- playground/generate_image.py | 2 +- src/novelai_python/sdk/ai/generate_image/__init__.py | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/playground/generate_image.py b/playground/generate_image.py index a770c36..910bd95 100755 --- a/playground/generate_image.py +++ b/playground/generate_image.py @@ -44,7 +44,7 @@ async def generate( try: agent = GenerateImageInfer.build_generate( prompt=prompt, - model=Model.NAI_DIFFUSION_4_CURATED_PREVIEW, + model=Model.NAI_DIFFUSION_3, character_prompts=[ Character( prompt="1girl", diff --git a/src/novelai_python/sdk/ai/generate_image/__init__.py b/src/novelai_python/sdk/ai/generate_image/__init__.py index b5c6770..4dbabe8 100755 --- a/src/novelai_python/sdk/ai/generate_image/__init__.py +++ b/src/novelai_python/sdk/ai/generate_image/__init__.py @@ -512,6 +512,7 @@ def _backend_logic(self): # 计算动态系数 dynamic_factor 并用于调整 skip_cfg_above_sigma dynamic_factor = ((weight * dimensions_scaled[0] * dimensions_scaled[1]) / reference_value) ** 0.5 self.parameters.skip_cfg_above_sigma *= dynamic_factor + self.parameters.skip_cfg_above_sigma = math.ceil(self.parameters.skip_cfg_above_sigma) if not get_supported_params(self.model).cfgDelay: self.parameters.skip_cfg_above_sigma = None From 7204413f746c617cb3dd4d48263fbd875dba0065 Mon Sep 17 00:00:00 2001 From: sudoskys Date: Sat, 21 Dec 2024 23:52:56 +0800 Subject: [PATCH 7/8] =?UTF-8?q?=E2=9C=A8=20feat(generate=5Fimage):=20add?= =?UTF-8?q?=20'sm'=20and=20'noise'=20parameters?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Added 'sm' parameter to control image generation options. Introduced 'noise' parameter for img2img transformations. --- src/novelai_python/sdk/ai/generate_image/__init__.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/novelai_python/sdk/ai/generate_image/__init__.py b/src/novelai_python/sdk/ai/generate_image/__init__.py index 4dbabe8..b8a5650 100755 --- a/src/novelai_python/sdk/ai/generate_image/__init__.py +++ b/src/novelai_python/sdk/ai/generate_image/__init__.py @@ -570,6 +570,7 @@ def build_generate( qualitySuffix: bool = True, negative_prompt: str = "", ucPreset: UCPresetTypeAlias = UCPreset.TYPE0, + sm: bool = False, steps: int = 23, seed: int = None, sampler: Union[Sampler, str] = None, @@ -589,6 +590,7 @@ def build_generate( If you need to define more parameters, you should initialize the Param class yourself. + :param sm: :param reference_information_extracted_multiple: :param reference_strength_multiple: :param reference_image_multiple: @@ -634,6 +636,7 @@ def build_generate( add_original_image=add_original_image, steps=steps, seed=seed, + sm=sm, negative_prompt=negative_prompt, ucPreset=ucPreset, qualityToggle=qualityToggle, @@ -656,6 +659,7 @@ def build_img2img( *, image: Union[bytes, str], strength: float = 0.7, + noise: float = 0, seed: int = None, extra_noise_seed: int = None, model: Union[Model, str] = Model.NAI_DIFFUSION_3, @@ -673,15 +677,17 @@ def build_img2img( reference_information_extracted_multiple: List[float] = None, qualityToggle: bool = False, decrisp_mode: bool = False, - variety_boost: bool = False, + variety_boost: bool = False ): """ Quickly construct a parameter class that meets the requirements. If you need to define more parameters, you should initialize the Param class yourself. + :param controlnet_strength: :param strength: :param image: + :param noise: For img2img :param extra_noise_seed: Get extra_noise_seed :param reference_information_extracted_multiple: :param reference_strength_multiple: @@ -725,6 +731,7 @@ def build_img2img( params = Params( image=image, strength=strength, + noise=noise, width=width, height=height, sampler=sampler, From a09cfabc073d36a077324872744699bbe6676988 Mon Sep 17 00:00:00 2001 From: sudoskys Date: Sat, 21 Dec 2024 23:56:55 +0800 Subject: [PATCH 8/8] =?UTF-8?q?=F0=9F=94=A7=20refactor(playground):=20upda?= =?UTF-8?q?te=20event=20loop=20creation=20in=20simple.py?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 🔄 docs(README): enhance image generation example with new params --- README.md | 29 +++++++++++++++++++++++++++-- playground/generate_image.py | 2 +- playground/simple.py | 2 +- 3 files changed, 29 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 38a0bba..18edea6 100755 --- a/README.md +++ b/README.md @@ -53,14 +53,39 @@ from dotenv import load_dotenv from pydantic import SecretStr from novelai_python import GenerateImageInfer, ImageGenerateResp, ApiCredential +from novelai_python.sdk.ai.generate_image import Model, Character, Sampler, UCPreset +from novelai_python.sdk.ai.generate_image.schema import PositionMap load_dotenv() -enhance = "year 2023,dynamic angle, best quality, amazing quality, very aesthetic, absurdres" session = ApiCredential(api_token=SecretStr(os.getenv("NOVELAI_JWT"))) # pst-*** +prompt = "1girl, year 2023,dynamic angle, best quality, amazing quality, very aesthetic, absurdres" + async def main(): - gen = await GenerateImageInfer.build(prompt=f"1girl,{enhance}") + gen = GenerateImageInfer.build_generate( + prompt=prompt, + model=Model.NAI_DIFFUSION_4_CURATED_PREVIEW, + character_prompts=[ + Character( + prompt="1girl", + uc="red hair", + center=PositionMap.AUTO + ), + Character( + prompt="1boy", + center=PositionMap.E5 + ) + ], + sampler=Sampler.K_EULER_ANCESTRAL, + ucPreset=UCPreset.TYPE0, + # Recommended, using preset negative_prompt depends on selected model + qualitySuffix=True, + qualityToggle=True, + decrisp_mode=False, + variety_boost=True, + # Checkbox in novelai.net + ) cost = gen.calculate_cost(is_opus=True) print(f"charge: {cost} if you are vip3") resp = gen.request(session=session) diff --git a/playground/generate_image.py b/playground/generate_image.py index 910bd95..a770c36 100755 --- a/playground/generate_image.py +++ b/playground/generate_image.py @@ -44,7 +44,7 @@ async def generate( try: agent = GenerateImageInfer.build_generate( prompt=prompt, - model=Model.NAI_DIFFUSION_3, + model=Model.NAI_DIFFUSION_4_CURATED_PREVIEW, character_prompts=[ Character( prompt="1girl", diff --git a/playground/simple.py b/playground/simple.py index 2bb3903..55fc1dc 100644 --- a/playground/simple.py +++ b/playground/simple.py @@ -20,5 +20,5 @@ async def main(): f.write(resp.files[0][1]) -loop = asyncio.get_event_loop() +loop = asyncio.new_event_loop() loop.run_until_complete(main())