ommlds 0.0.0.dev466__py3-none-any.whl → 0.0.0.dev512__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- ommlds/.omlish-manifests.json +404 -31
- ommlds/README.md +11 -0
- ommlds/__about__.py +21 -12
- ommlds/_hacks/__init__.py +4 -0
- ommlds/_hacks/funcs.py +110 -0
- ommlds/_hacks/names.py +158 -0
- ommlds/_hacks/params.py +73 -0
- ommlds/_hacks/patches.py +0 -3
- ommlds/backends/anthropic/protocol/__init__.py +13 -1
- ommlds/backends/anthropic/protocol/_dataclasses.py +1625 -0
- ommlds/backends/anthropic/protocol/sse/events.py +2 -0
- ommlds/backends/anthropic/protocol/types.py +5 -7
- ommlds/backends/cerebras/__init__.py +7 -0
- ommlds/backends/cerebras/_dataclasses.py +4254 -0
- ommlds/backends/cerebras/_marshal.py +24 -0
- ommlds/backends/cerebras/clients.py +9 -0
- ommlds/backends/cerebras/protocol.py +310 -0
- ommlds/backends/google/protocol/__init__.py +13 -0
- ommlds/backends/google/protocol/_dataclasses.py +5997 -0
- ommlds/backends/google/protocol/types.py +6 -8
- ommlds/backends/groq/__init__.py +7 -0
- ommlds/backends/groq/_dataclasses.py +3901 -0
- ommlds/backends/groq/_marshal.py +23 -0
- ommlds/backends/groq/clients.py +9 -0
- ommlds/backends/groq/protocol.py +247 -0
- ommlds/{huggingface.py → backends/huggingface/cache.py} +1 -6
- ommlds/backends/huggingface/cli.py +208 -0
- ommlds/backends/llamacpp/logging.py +4 -1
- ommlds/backends/mlx/caching.py +7 -3
- ommlds/backends/mlx/cli.py +10 -7
- ommlds/backends/mlx/generation.py +18 -16
- ommlds/backends/mlx/limits.py +10 -6
- ommlds/backends/mlx/loading.py +7 -4
- ommlds/backends/ollama/__init__.py +7 -0
- ommlds/backends/ollama/_dataclasses.py +3940 -0
- ommlds/backends/ollama/cli.py +36 -0
- ommlds/backends/ollama/protocol.py +201 -0
- ommlds/backends/openai/protocol/__init__.py +15 -1
- ommlds/backends/openai/protocol/_common.py +3 -5
- ommlds/backends/openai/protocol/_dataclasses.py +7708 -0
- ommlds/backends/tavily/__init__.py +7 -0
- ommlds/backends/tavily/_dataclasses.py +1734 -0
- ommlds/backends/tavily/protocol.py +299 -0
- ommlds/backends/tinygrad/models/llama3/__init__.py +22 -14
- ommlds/backends/torch/backends.py +1 -1
- ommlds/backends/transformers/__init__.py +14 -0
- ommlds/backends/transformers/filecache.py +109 -0
- ommlds/backends/transformers/streamers.py +73 -0
- ommlds/cli/__init__.py +7 -0
- ommlds/cli/_dataclasses.py +3835 -0
- ommlds/cli/asyncs.py +30 -0
- ommlds/cli/backends/catalog.py +88 -0
- ommlds/cli/backends/configs.py +9 -0
- ommlds/cli/backends/inject.py +100 -42
- ommlds/cli/{sessions/chat/backends → backends}/injection.py +1 -1
- ommlds/cli/backends/meta.py +82 -0
- ommlds/cli/{sessions/chat/backends → backends}/types.py +11 -1
- ommlds/cli/{sessions/chat/content → content}/messages.py +2 -2
- ommlds/cli/{sessions/chat/content → content}/strings.py +1 -1
- ommlds/cli/inject.py +17 -8
- ommlds/cli/inputs/asyncs.py +32 -0
- ommlds/cli/inputs/sync.py +75 -0
- ommlds/cli/main.py +346 -114
- ommlds/cli/rendering/configs.py +9 -0
- ommlds/cli/{sessions/chat/rendering → rendering}/inject.py +4 -5
- ommlds/cli/{sessions/chat/rendering → rendering}/markdown.py +1 -1
- ommlds/cli/{sessions/chat/rendering → rendering}/raw.py +1 -1
- ommlds/cli/{sessions/chat/rendering → rendering}/types.py +7 -1
- ommlds/cli/secrets.py +22 -0
- ommlds/cli/sessions/base.py +1 -10
- ommlds/cli/sessions/chat/configs.py +13 -30
- ommlds/cli/sessions/chat/drivers/ai/configs.py +13 -0
- ommlds/cli/sessions/chat/drivers/ai/events.py +57 -0
- ommlds/cli/sessions/chat/{chat → drivers}/ai/inject.py +15 -12
- ommlds/cli/sessions/chat/{chat → drivers}/ai/rendering.py +8 -8
- ommlds/cli/sessions/chat/{chat → drivers}/ai/services.py +5 -5
- ommlds/cli/sessions/chat/{chat → drivers}/ai/tools.py +4 -8
- ommlds/cli/sessions/chat/{chat → drivers}/ai/types.py +10 -1
- ommlds/cli/sessions/chat/drivers/configs.py +25 -0
- ommlds/cli/sessions/chat/drivers/events/inject.py +27 -0
- ommlds/cli/sessions/chat/drivers/events/injection.py +14 -0
- ommlds/cli/sessions/chat/drivers/events/manager.py +16 -0
- ommlds/cli/sessions/chat/drivers/events/types.py +44 -0
- ommlds/cli/sessions/chat/drivers/impl.py +50 -0
- ommlds/cli/sessions/chat/drivers/inject.py +70 -0
- ommlds/cli/sessions/chat/drivers/state/configs.py +13 -0
- ommlds/cli/sessions/chat/drivers/state/ids.py +25 -0
- ommlds/cli/sessions/chat/drivers/state/inject.py +83 -0
- ommlds/cli/sessions/chat/{chat → drivers}/state/inmemory.py +1 -6
- ommlds/cli/sessions/chat/{chat → drivers}/state/storage.py +18 -12
- ommlds/cli/sessions/chat/{chat → drivers}/state/types.py +11 -6
- ommlds/cli/sessions/chat/drivers/tools/configs.py +22 -0
- ommlds/cli/sessions/chat/drivers/tools/confirmation.py +44 -0
- ommlds/cli/sessions/chat/drivers/tools/errorhandling.py +39 -0
- ommlds/cli/sessions/chat/{tools → drivers/tools}/execution.py +3 -4
- ommlds/cli/sessions/chat/drivers/tools/fs/__init__.py +0 -0
- ommlds/cli/sessions/chat/drivers/tools/fs/configs.py +12 -0
- ommlds/cli/sessions/chat/drivers/tools/fs/inject.py +35 -0
- ommlds/cli/sessions/chat/drivers/tools/inject.py +83 -0
- ommlds/cli/sessions/chat/{tools → drivers/tools}/injection.py +20 -5
- ommlds/cli/sessions/chat/{tools → drivers/tools}/rendering.py +3 -3
- ommlds/cli/sessions/chat/drivers/tools/todo/__init__.py +0 -0
- ommlds/cli/sessions/chat/drivers/tools/todo/configs.py +12 -0
- ommlds/cli/sessions/chat/drivers/tools/todo/inject.py +31 -0
- ommlds/cli/sessions/chat/drivers/tools/weather/__init__.py +0 -0
- ommlds/cli/sessions/chat/drivers/tools/weather/configs.py +12 -0
- ommlds/cli/sessions/chat/drivers/tools/weather/inject.py +22 -0
- ommlds/cli/sessions/chat/{tools/weather.py → drivers/tools/weather/tools.py} +1 -1
- ommlds/cli/sessions/chat/drivers/types.py +31 -0
- ommlds/cli/sessions/chat/drivers/user/__init__.py +0 -0
- ommlds/cli/sessions/chat/drivers/user/configs.py +14 -0
- ommlds/cli/sessions/chat/drivers/user/inject.py +41 -0
- ommlds/cli/sessions/chat/facades/__init__.py +0 -0
- ommlds/cli/sessions/chat/facades/commands/__init__.py +0 -0
- ommlds/cli/sessions/chat/facades/commands/base.py +83 -0
- ommlds/cli/sessions/chat/facades/commands/configs.py +9 -0
- ommlds/cli/sessions/chat/facades/commands/inject.py +41 -0
- ommlds/cli/sessions/chat/facades/commands/injection.py +15 -0
- ommlds/cli/sessions/chat/facades/commands/manager.py +59 -0
- ommlds/cli/sessions/chat/facades/commands/simple.py +34 -0
- ommlds/cli/sessions/chat/facades/commands/types.py +13 -0
- ommlds/cli/sessions/chat/facades/configs.py +11 -0
- ommlds/cli/sessions/chat/facades/facade.py +26 -0
- ommlds/cli/sessions/chat/facades/inject.py +35 -0
- ommlds/cli/sessions/chat/facades/ui.py +34 -0
- ommlds/cli/sessions/chat/inject.py +10 -49
- ommlds/cli/sessions/chat/interfaces/__init__.py +0 -0
- ommlds/cli/sessions/chat/interfaces/bare/__init__.py +0 -0
- ommlds/cli/sessions/chat/interfaces/bare/configs.py +15 -0
- ommlds/cli/sessions/chat/interfaces/bare/inject.py +69 -0
- ommlds/cli/sessions/chat/interfaces/bare/interactive.py +49 -0
- ommlds/cli/sessions/chat/interfaces/bare/oneshot.py +21 -0
- ommlds/cli/sessions/chat/{tools/confirmation.py → interfaces/bare/tools.py} +3 -22
- ommlds/cli/sessions/chat/interfaces/base.py +13 -0
- ommlds/cli/sessions/chat/interfaces/configs.py +11 -0
- ommlds/cli/sessions/chat/interfaces/inject.py +29 -0
- ommlds/cli/sessions/chat/interfaces/textual/__init__.py +0 -0
- ommlds/cli/sessions/chat/interfaces/textual/app.py +429 -0
- ommlds/cli/sessions/chat/interfaces/textual/configs.py +11 -0
- ommlds/cli/sessions/chat/interfaces/textual/facades.py +19 -0
- ommlds/cli/sessions/chat/interfaces/textual/inject.py +111 -0
- ommlds/cli/sessions/chat/interfaces/textual/inputhistory.py +174 -0
- ommlds/cli/sessions/chat/interfaces/textual/interface.py +24 -0
- ommlds/cli/sessions/chat/interfaces/textual/styles/__init__.py +29 -0
- ommlds/cli/sessions/chat/interfaces/textual/styles/input.tcss +53 -0
- ommlds/cli/sessions/chat/interfaces/textual/styles/markdown.tcss +7 -0
- ommlds/cli/sessions/chat/interfaces/textual/styles/messages.tcss +167 -0
- ommlds/cli/sessions/chat/interfaces/textual/tools.py +38 -0
- ommlds/cli/sessions/chat/interfaces/textual/widgets/__init__.py +0 -0
- ommlds/cli/sessions/chat/interfaces/textual/widgets/input.py +70 -0
- ommlds/cli/sessions/chat/interfaces/textual/widgets/messages.py +207 -0
- ommlds/cli/sessions/chat/session.py +8 -13
- ommlds/cli/sessions/completion/configs.py +5 -6
- ommlds/cli/sessions/completion/inject.py +15 -2
- ommlds/cli/sessions/completion/session.py +10 -18
- ommlds/cli/sessions/configs.py +10 -0
- ommlds/cli/sessions/embedding/configs.py +5 -6
- ommlds/cli/sessions/embedding/inject.py +15 -2
- ommlds/cli/sessions/embedding/session.py +10 -18
- ommlds/cli/sessions/inject.py +15 -15
- ommlds/cli/state/storage.py +8 -2
- ommlds/minichain/__init__.py +217 -60
- ommlds/minichain/_dataclasses.py +20640 -0
- ommlds/minichain/_typedvalues.py +15 -8
- ommlds/minichain/backends/catalogs/base.py +20 -1
- ommlds/minichain/backends/catalogs/simple.py +2 -2
- ommlds/minichain/backends/catalogs/strings.py +13 -10
- ommlds/minichain/backends/impls/anthropic/chat.py +28 -5
- ommlds/minichain/backends/impls/anthropic/names.py +3 -3
- ommlds/minichain/backends/impls/anthropic/protocol.py +2 -2
- ommlds/minichain/backends/impls/anthropic/stream.py +23 -18
- ommlds/minichain/backends/impls/cerebras/__init__.py +0 -0
- ommlds/minichain/backends/impls/cerebras/chat.py +82 -0
- ommlds/minichain/backends/impls/cerebras/names.py +45 -0
- ommlds/minichain/backends/impls/cerebras/protocol.py +143 -0
- ommlds/minichain/backends/impls/cerebras/stream.py +114 -0
- ommlds/minichain/backends/impls/duckduckgo/search.py +5 -1
- ommlds/minichain/backends/impls/dummy/__init__.py +0 -0
- ommlds/minichain/backends/impls/dummy/chat.py +69 -0
- ommlds/minichain/backends/impls/google/chat.py +20 -84
- ommlds/minichain/backends/impls/google/names.py +6 -0
- ommlds/minichain/backends/impls/google/protocol.py +105 -0
- ommlds/minichain/backends/impls/google/search.py +10 -5
- ommlds/minichain/backends/impls/google/stream.py +64 -142
- ommlds/minichain/backends/impls/google/tools.py +2 -2
- ommlds/minichain/backends/impls/groq/__init__.py +0 -0
- ommlds/minichain/backends/impls/groq/chat.py +77 -0
- ommlds/minichain/backends/impls/groq/names.py +48 -0
- ommlds/minichain/backends/impls/groq/protocol.py +143 -0
- ommlds/minichain/backends/impls/groq/stream.py +114 -0
- ommlds/minichain/backends/impls/huggingface/repos.py +1 -5
- ommlds/minichain/backends/impls/llamacpp/chat.py +15 -3
- ommlds/minichain/backends/impls/llamacpp/completion.py +7 -3
- ommlds/minichain/backends/impls/llamacpp/stream.py +38 -19
- ommlds/minichain/backends/impls/mistral.py +9 -2
- ommlds/minichain/backends/impls/mlx/chat.py +100 -23
- ommlds/minichain/backends/impls/ollama/__init__.py +0 -0
- ommlds/minichain/backends/impls/ollama/chat.py +193 -0
- ommlds/minichain/backends/impls/ollama/protocol.py +144 -0
- ommlds/minichain/backends/impls/openai/chat.py +14 -7
- ommlds/minichain/backends/impls/openai/completion.py +9 -2
- ommlds/minichain/backends/impls/openai/embedding.py +9 -2
- ommlds/minichain/backends/impls/openai/format.py +117 -115
- ommlds/minichain/backends/impls/openai/names.py +33 -5
- ommlds/minichain/backends/impls/openai/stream.py +61 -70
- ommlds/minichain/backends/impls/sentencepiece/tokens.py +9 -6
- ommlds/minichain/backends/impls/tavily.py +66 -0
- ommlds/minichain/backends/impls/tinygrad/chat.py +17 -14
- ommlds/minichain/backends/impls/tokenizers/tokens.py +9 -6
- ommlds/minichain/backends/impls/transformers/sentence.py +5 -2
- ommlds/minichain/backends/impls/transformers/tokens.py +9 -6
- ommlds/minichain/backends/impls/transformers/transformers.py +139 -20
- ommlds/minichain/backends/strings/parsing.py +2 -2
- ommlds/minichain/backends/strings/resolving.py +7 -2
- ommlds/minichain/chat/choices/stream/__init__.py +0 -0
- ommlds/minichain/chat/{stream → choices/stream}/adapters.py +7 -7
- ommlds/minichain/chat/choices/stream/joining.py +31 -0
- ommlds/minichain/chat/choices/stream/services.py +45 -0
- ommlds/minichain/chat/choices/stream/types.py +43 -0
- ommlds/minichain/chat/content.py +42 -0
- ommlds/minichain/chat/messages.py +46 -42
- ommlds/minichain/chat/stream/_marshal.py +4 -4
- ommlds/minichain/chat/stream/joining.py +56 -43
- ommlds/minichain/chat/stream/services.py +15 -15
- ommlds/minichain/chat/stream/types.py +17 -24
- ommlds/minichain/chat/templating.py +3 -3
- ommlds/minichain/content/__init__.py +20 -3
- ommlds/minichain/content/_marshal.py +181 -55
- ommlds/minichain/content/code.py +26 -0
- ommlds/minichain/content/composite.py +28 -0
- ommlds/minichain/content/content.py +27 -0
- ommlds/minichain/content/dynamic.py +12 -0
- ommlds/minichain/content/emphasis.py +27 -0
- ommlds/minichain/content/images.py +2 -2
- ommlds/minichain/content/json.py +2 -2
- ommlds/minichain/content/link.py +13 -0
- ommlds/minichain/content/markdown.py +12 -0
- ommlds/minichain/content/metadata.py +10 -0
- ommlds/minichain/content/namespaces.py +8 -0
- ommlds/minichain/content/placeholders.py +10 -9
- ommlds/minichain/content/quote.py +26 -0
- ommlds/minichain/content/raw.py +49 -0
- ommlds/minichain/content/recursive.py +12 -0
- ommlds/minichain/content/resources.py +22 -0
- ommlds/minichain/content/section.py +26 -0
- ommlds/minichain/content/sequence.py +17 -3
- ommlds/minichain/content/standard.py +32 -0
- ommlds/minichain/content/tag.py +28 -0
- ommlds/minichain/content/templates.py +13 -0
- ommlds/minichain/content/text.py +2 -2
- ommlds/minichain/content/transform/__init__.py +0 -0
- ommlds/minichain/content/transform/json.py +55 -0
- ommlds/minichain/content/transform/markdown.py +8 -0
- ommlds/minichain/content/transform/materialize.py +59 -0
- ommlds/minichain/content/transform/metadata.py +16 -0
- ommlds/minichain/content/transform/namespaces.py +20 -0
- ommlds/minichain/content/transform/placeholders.py +60 -0
- ommlds/minichain/content/{prepare.py → transform/prepare.py} +10 -15
- ommlds/minichain/content/transform/recursive.py +54 -0
- ommlds/minichain/content/transform/resources.py +58 -0
- ommlds/minichain/content/transform/standard.py +43 -0
- ommlds/minichain/content/{transforms → transform}/stringify.py +1 -7
- ommlds/minichain/content/transform/strings.py +33 -0
- ommlds/minichain/content/transform/templates.py +25 -0
- ommlds/minichain/content/transform/types.py +18 -0
- ommlds/minichain/content/transform/visitors.py +38 -0
- ommlds/minichain/content/visitors.py +218 -0
- ommlds/minichain/http/__init__.py +0 -0
- ommlds/minichain/http/stream.py +195 -0
- ommlds/minichain/lib/fs/tools/read.py +1 -1
- ommlds/minichain/lib/fs/tools/recursivels/rendering.py +1 -1
- ommlds/minichain/lib/fs/tools/recursivels/running.py +1 -1
- ommlds/minichain/lib/todo/tools/write.py +2 -1
- ommlds/minichain/lib/todo/types.py +1 -1
- ommlds/minichain/llms/types.py +4 -0
- ommlds/minichain/metadata.py +56 -2
- ommlds/minichain/models/configs.py +2 -2
- ommlds/minichain/models/names.py +2 -0
- ommlds/minichain/registries/globals.py +18 -4
- ommlds/minichain/resources.py +49 -3
- ommlds/minichain/search.py +1 -1
- ommlds/minichain/services/README.md +154 -0
- ommlds/minichain/services/__init__.py +6 -2
- ommlds/minichain/services/_marshal.py +46 -10
- ommlds/minichain/services/_origclasses.py +11 -0
- ommlds/minichain/services/_typedvalues.py +8 -3
- ommlds/minichain/services/requests.py +73 -3
- ommlds/minichain/services/responses.py +73 -3
- ommlds/minichain/services/services.py +9 -0
- ommlds/minichain/standard.py +8 -0
- ommlds/minichain/stream/services.py +43 -17
- ommlds/minichain/text/applypatch.py +2 -1
- ommlds/minichain/text/toolparsing/llamacpp/types.py +1 -1
- ommlds/minichain/tokens/specials.py +1 -1
- ommlds/minichain/tools/execution/catalog.py +2 -2
- ommlds/minichain/tools/execution/errorhandling.py +36 -0
- ommlds/minichain/tools/execution/errors.py +2 -2
- ommlds/minichain/tools/execution/executors.py +1 -1
- ommlds/minichain/tools/fns.py +1 -1
- ommlds/minichain/tools/jsonschema.py +2 -2
- ommlds/minichain/tools/reflect.py +11 -7
- ommlds/minichain/tools/types.py +16 -19
- ommlds/minichain/vectors/_marshal.py +1 -1
- ommlds/minichain/vectors/embeddings.py +1 -1
- ommlds/minichain/wrappers/__init__.py +7 -0
- ommlds/minichain/wrappers/firstinwins.py +144 -0
- ommlds/minichain/wrappers/instrument.py +146 -0
- ommlds/minichain/wrappers/retry.py +168 -0
- ommlds/minichain/wrappers/services.py +98 -0
- ommlds/minichain/wrappers/stream.py +57 -0
- ommlds/nanochat/LICENSE +21 -0
- ommlds/nanochat/__init__.py +0 -0
- ommlds/nanochat/rustbpe/LICENSE +21 -0
- ommlds/nanochat/rustbpe/README.md +10 -0
- ommlds/nanochat/tokenizers.py +440 -0
- ommlds/specs/__init__.py +0 -0
- ommlds/specs/mcp/__init__.py +0 -0
- ommlds/specs/mcp/_marshal.py +23 -0
- ommlds/specs/mcp/clients.py +146 -0
- ommlds/specs/mcp/protocol.py +369 -0
- ommlds/tools/git.py +84 -64
- ommlds/tools/ocr.py +1 -1
- ommlds/wiki/analyze.py +2 -2
- ommlds/wiki/models.py +4 -4
- ommlds/wiki/text/mfh.py +9 -9
- ommlds/wiki/utils/xml.py +5 -5
- {ommlds-0.0.0.dev466.dist-info → ommlds-0.0.0.dev512.dist-info}/METADATA +28 -21
- ommlds-0.0.0.dev512.dist-info/RECORD +534 -0
- {ommlds-0.0.0.dev466.dist-info → ommlds-0.0.0.dev512.dist-info}/WHEEL +1 -1
- ommlds/cli/backends/standard.py +0 -20
- ommlds/cli/sessions/chat/backends/catalog.py +0 -56
- ommlds/cli/sessions/chat/backends/inject.py +0 -37
- ommlds/cli/sessions/chat/chat/state/inject.py +0 -40
- ommlds/cli/sessions/chat/chat/user/inject.py +0 -61
- ommlds/cli/sessions/chat/chat/user/interactive.py +0 -29
- ommlds/cli/sessions/chat/chat/user/oneshot.py +0 -25
- ommlds/cli/sessions/chat/chat/user/types.py +0 -15
- ommlds/cli/sessions/chat/driver.py +0 -43
- ommlds/cli/sessions/chat/tools/inject.py +0 -145
- ommlds/minichain/backends/impls/openai/format2.py +0 -210
- ommlds/minichain/content/materialize.py +0 -196
- ommlds/minichain/content/simple.py +0 -47
- ommlds/minichain/content/transforms/base.py +0 -46
- ommlds/minichain/content/transforms/interleave.py +0 -70
- ommlds/minichain/content/transforms/squeeze.py +0 -72
- ommlds/minichain/content/transforms/strings.py +0 -24
- ommlds/minichain/content/types.py +0 -43
- ommlds/minichain/stream/wrap.py +0 -62
- ommlds-0.0.0.dev466.dist-info/RECORD +0 -376
- /ommlds/{cli/sessions/chat/backends → backends/huggingface}/__init__.py +0 -0
- /ommlds/cli/{sessions/chat/chat → content}/__init__.py +0 -0
- /ommlds/cli/{sessions/chat/chat/ai → inputs}/__init__.py +0 -0
- /ommlds/cli/{sessions/chat/chat/state → rendering}/__init__.py +0 -0
- /ommlds/cli/sessions/chat/{chat/user → drivers}/__init__.py +0 -0
- /ommlds/cli/sessions/chat/{content → drivers/ai}/__init__.py +0 -0
- /ommlds/cli/sessions/chat/{chat → drivers}/ai/injection.py +0 -0
- /ommlds/cli/sessions/chat/{phases → drivers/events}/__init__.py +0 -0
- /ommlds/cli/sessions/chat/{rendering → drivers/phases}/__init__.py +0 -0
- /ommlds/cli/sessions/chat/{phases → drivers/phases}/inject.py +0 -0
- /ommlds/cli/sessions/chat/{phases → drivers/phases}/injection.py +0 -0
- /ommlds/cli/sessions/chat/{phases → drivers/phases}/manager.py +0 -0
- /ommlds/cli/sessions/chat/{phases → drivers/phases}/types.py +0 -0
- /ommlds/cli/sessions/chat/{tools → drivers/state}/__init__.py +0 -0
- /ommlds/{minichain/content/transforms → cli/sessions/chat/drivers/tools}/__init__.py +0 -0
- {ommlds-0.0.0.dev466.dist-info → ommlds-0.0.0.dev512.dist-info}/entry_points.txt +0 -0
- {ommlds-0.0.0.dev466.dist-info → ommlds-0.0.0.dev512.dist-info}/licenses/LICENSE +0 -0
- {ommlds-0.0.0.dev466.dist-info → ommlds-0.0.0.dev512.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,3940 @@
|
|
|
1
|
+
# @omlish-generated
|
|
2
|
+
# type: ignore
|
|
3
|
+
# ruff: noqa
|
|
4
|
+
# flake8: noqa
|
|
5
|
+
import dataclasses
|
|
6
|
+
import reprlib
|
|
7
|
+
import types
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
##
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
REGISTRY = {}
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
def _register(**kwargs):
|
|
17
|
+
def inner(fn):
|
|
18
|
+
REGISTRY[kwargs['plan_repr']] = (kwargs, fn)
|
|
19
|
+
return fn
|
|
20
|
+
return inner
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
##
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
@_register(
|
|
27
|
+
plan_repr=(
|
|
28
|
+
"Plans(tup=(CopyPlan(fields=('model', 'stream', 'options', 'format', 'keep_alive')), EqPlan(fields=('model', 's"
|
|
29
|
+
"tream', 'options', 'format', 'keep_alive')), FrozenPlan(fields=('model', 'stream', 'options', 'format', 'keep_"
|
|
30
|
+
"alive'), allow_dynamic_dunder_attrs=False), HashPlan(action='add', fields=('model', 'stream', 'options', 'form"
|
|
31
|
+
"at', 'keep_alive'), cache=False), InitPlan(fields=(InitPlan.Field(name='model', annotation=OpRef(name='init.fi"
|
|
32
|
+
"elds.0.annotation'), default=None, default_factory=None, init=True, override=False, field_type=FieldType.INSTA"
|
|
33
|
+
"NCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='stream', annotation=OpRef(name='init.f"
|
|
34
|
+
"ields.1.annotation'), default=OpRef(name='init.fields.1.default'), default_factory=None, init=True, override=F"
|
|
35
|
+
"alse, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='option"
|
|
36
|
+
"s', annotation=OpRef(name='init.fields.2.annotation'), default=OpRef(name='init.fields.2.default'), default_fa"
|
|
37
|
+
"ctory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=N"
|
|
38
|
+
"one), InitPlan.Field(name='format', annotation=OpRef(name='init.fields.3.annotation'), default=OpRef(name='ini"
|
|
39
|
+
"t.fields.3.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=N"
|
|
40
|
+
"one, validate=None, check_type=None), InitPlan.Field(name='keep_alive', annotation=OpRef(name='init.fields.4.a"
|
|
41
|
+
"nnotation'), default=OpRef(name='init.fields.4.default'), default_factory=None, init=True, override=False, fie"
|
|
42
|
+
"ld_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None)), self_param='self', std_params=(), k"
|
|
43
|
+
"w_only_params=('model', 'stream', 'options', 'format', 'keep_alive'), frozen=True, slots=False, post_init_para"
|
|
44
|
+
"ms=None, init_fns=(), validate_fns=()), ReprPlan(fields=(ReprPlan.Field(name='model', kw_only=True, fn=None), "
|
|
45
|
+
"ReprPlan.Field(name='stream', kw_only=True, fn=None), ReprPlan.Field(name='options', kw_only=True, fn=None), R"
|
|
46
|
+
"eprPlan.Field(name='format', kw_only=True, fn=None), ReprPlan.Field(name='keep_alive', kw_only=True, fn=None))"
|
|
47
|
+
", id=False, terse=False, default_fn=None)))"
|
|
48
|
+
),
|
|
49
|
+
plan_repr_sha1='845e863b03ee92ab7c5b27be3dfabfb54b948c5d',
|
|
50
|
+
op_ref_idents=(
|
|
51
|
+
'__dataclass__init__fields__0__annotation',
|
|
52
|
+
'__dataclass__init__fields__1__annotation',
|
|
53
|
+
'__dataclass__init__fields__1__default',
|
|
54
|
+
'__dataclass__init__fields__2__annotation',
|
|
55
|
+
'__dataclass__init__fields__2__default',
|
|
56
|
+
'__dataclass__init__fields__3__annotation',
|
|
57
|
+
'__dataclass__init__fields__3__default',
|
|
58
|
+
'__dataclass__init__fields__4__annotation',
|
|
59
|
+
'__dataclass__init__fields__4__default',
|
|
60
|
+
),
|
|
61
|
+
cls_names=(
|
|
62
|
+
('ommlds.backends.ollama.protocol', 'BaseGenerateRequest'),
|
|
63
|
+
),
|
|
64
|
+
)
|
|
65
|
+
def _process_dataclass__845e863b03ee92ab7c5b27be3dfabfb54b948c5d():
|
|
66
|
+
def _process_dataclass(
|
|
67
|
+
*,
|
|
68
|
+
__dataclass__cls,
|
|
69
|
+
__dataclass__init__fields__0__annotation,
|
|
70
|
+
__dataclass__init__fields__1__annotation,
|
|
71
|
+
__dataclass__init__fields__1__default,
|
|
72
|
+
__dataclass__init__fields__2__annotation,
|
|
73
|
+
__dataclass__init__fields__2__default,
|
|
74
|
+
__dataclass__init__fields__3__annotation,
|
|
75
|
+
__dataclass__init__fields__3__default,
|
|
76
|
+
__dataclass__init__fields__4__annotation,
|
|
77
|
+
__dataclass__init__fields__4__default,
|
|
78
|
+
__dataclass__FieldFnValidationError, # noqa
|
|
79
|
+
__dataclass__FieldTypeValidationError, # noqa
|
|
80
|
+
__dataclass__FnValidationError, # noqa
|
|
81
|
+
__dataclass__FrozenInstanceError=dataclasses.FrozenInstanceError, # noqa
|
|
82
|
+
__dataclass__FunctionType=types.FunctionType, # noqa
|
|
83
|
+
__dataclass__HAS_DEFAULT_FACTORY=dataclasses._HAS_DEFAULT_FACTORY, # noqa
|
|
84
|
+
__dataclass__MISSING=dataclasses.MISSING, # noqa
|
|
85
|
+
__dataclass__None=None, # noqa
|
|
86
|
+
__dataclass__TypeError=TypeError, # noqa
|
|
87
|
+
__dataclass___recursive_repr=reprlib.recursive_repr, # noqa
|
|
88
|
+
__dataclass__isinstance=isinstance, # noqa
|
|
89
|
+
__dataclass__object_setattr=object.__setattr__, # noqa
|
|
90
|
+
__dataclass__property=property, # noqa
|
|
91
|
+
):
|
|
92
|
+
def __copy__(self):
|
|
93
|
+
if self.__class__ is not __dataclass__cls:
|
|
94
|
+
raise TypeError(self)
|
|
95
|
+
return __dataclass__cls( # noqa
|
|
96
|
+
model=self.model,
|
|
97
|
+
stream=self.stream,
|
|
98
|
+
options=self.options,
|
|
99
|
+
format=self.format,
|
|
100
|
+
keep_alive=self.keep_alive,
|
|
101
|
+
)
|
|
102
|
+
|
|
103
|
+
__copy__.__qualname__ = f"{__dataclass__cls.__qualname__}.__copy__"
|
|
104
|
+
if '__copy__' in __dataclass__cls.__dict__:
|
|
105
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __copy__ in class {__dataclass__cls.__name__}")
|
|
106
|
+
setattr(__dataclass__cls, '__copy__', __copy__)
|
|
107
|
+
|
|
108
|
+
def __eq__(self, other):
|
|
109
|
+
if self is other:
|
|
110
|
+
return True
|
|
111
|
+
if self.__class__ is not other.__class__:
|
|
112
|
+
return NotImplemented
|
|
113
|
+
return (
|
|
114
|
+
self.model == other.model and
|
|
115
|
+
self.stream == other.stream and
|
|
116
|
+
self.options == other.options and
|
|
117
|
+
self.format == other.format and
|
|
118
|
+
self.keep_alive == other.keep_alive
|
|
119
|
+
)
|
|
120
|
+
|
|
121
|
+
__eq__.__qualname__ = f"{__dataclass__cls.__qualname__}.__eq__"
|
|
122
|
+
if '__eq__' in __dataclass__cls.__dict__:
|
|
123
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __eq__ in class {__dataclass__cls.__name__}")
|
|
124
|
+
setattr(__dataclass__cls, '__eq__', __eq__)
|
|
125
|
+
|
|
126
|
+
__dataclass___setattr_frozen_fields = {
|
|
127
|
+
'model',
|
|
128
|
+
'stream',
|
|
129
|
+
'options',
|
|
130
|
+
'format',
|
|
131
|
+
'keep_alive',
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
def __setattr__(self, name, value):
|
|
135
|
+
if (
|
|
136
|
+
type(self) is __dataclass__cls
|
|
137
|
+
or name in __dataclass___setattr_frozen_fields
|
|
138
|
+
):
|
|
139
|
+
raise __dataclass__FrozenInstanceError(f"cannot assign to field {name!r}")
|
|
140
|
+
super(__dataclass__cls, self).__setattr__(name, value)
|
|
141
|
+
|
|
142
|
+
__setattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__setattr__"
|
|
143
|
+
if '__setattr__' in __dataclass__cls.__dict__:
|
|
144
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __setattr__ in class {__dataclass__cls.__name__}")
|
|
145
|
+
setattr(__dataclass__cls, '__setattr__', __setattr__)
|
|
146
|
+
|
|
147
|
+
__dataclass___delattr_frozen_fields = {
|
|
148
|
+
'model',
|
|
149
|
+
'stream',
|
|
150
|
+
'options',
|
|
151
|
+
'format',
|
|
152
|
+
'keep_alive',
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
def __delattr__(self, name):
|
|
156
|
+
if (
|
|
157
|
+
type(self) is __dataclass__cls
|
|
158
|
+
or name in __dataclass___delattr_frozen_fields
|
|
159
|
+
):
|
|
160
|
+
raise __dataclass__FrozenInstanceError(f"cannot delete field {name!r}")
|
|
161
|
+
super(__dataclass__cls, self).__delattr__(name)
|
|
162
|
+
|
|
163
|
+
__delattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__delattr__"
|
|
164
|
+
if '__delattr__' in __dataclass__cls.__dict__:
|
|
165
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __delattr__ in class {__dataclass__cls.__name__}")
|
|
166
|
+
setattr(__dataclass__cls, '__delattr__', __delattr__)
|
|
167
|
+
|
|
168
|
+
def __hash__(self):
|
|
169
|
+
return hash((
|
|
170
|
+
self.model,
|
|
171
|
+
self.stream,
|
|
172
|
+
self.options,
|
|
173
|
+
self.format,
|
|
174
|
+
self.keep_alive,
|
|
175
|
+
))
|
|
176
|
+
|
|
177
|
+
__hash__.__qualname__ = f"{__dataclass__cls.__qualname__}.__hash__"
|
|
178
|
+
setattr(__dataclass__cls, '__hash__', __hash__)
|
|
179
|
+
|
|
180
|
+
def __init__(
|
|
181
|
+
self,
|
|
182
|
+
*,
|
|
183
|
+
model: __dataclass__init__fields__0__annotation,
|
|
184
|
+
stream: __dataclass__init__fields__1__annotation = __dataclass__init__fields__1__default,
|
|
185
|
+
options: __dataclass__init__fields__2__annotation = __dataclass__init__fields__2__default,
|
|
186
|
+
format: __dataclass__init__fields__3__annotation = __dataclass__init__fields__3__default,
|
|
187
|
+
keep_alive: __dataclass__init__fields__4__annotation = __dataclass__init__fields__4__default,
|
|
188
|
+
) -> __dataclass__None:
|
|
189
|
+
__dataclass__object_setattr(self, 'model', model)
|
|
190
|
+
__dataclass__object_setattr(self, 'stream', stream)
|
|
191
|
+
__dataclass__object_setattr(self, 'options', options)
|
|
192
|
+
__dataclass__object_setattr(self, 'format', format)
|
|
193
|
+
__dataclass__object_setattr(self, 'keep_alive', keep_alive)
|
|
194
|
+
|
|
195
|
+
__init__.__qualname__ = f"{__dataclass__cls.__qualname__}.__init__"
|
|
196
|
+
if '__init__' in __dataclass__cls.__dict__:
|
|
197
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __init__ in class {__dataclass__cls.__name__}")
|
|
198
|
+
setattr(__dataclass__cls, '__init__', __init__)
|
|
199
|
+
|
|
200
|
+
@__dataclass___recursive_repr()
|
|
201
|
+
def __repr__(self):
|
|
202
|
+
parts = []
|
|
203
|
+
parts.append(f"model={self.model!r}")
|
|
204
|
+
parts.append(f"stream={self.stream!r}")
|
|
205
|
+
parts.append(f"options={self.options!r}")
|
|
206
|
+
parts.append(f"format={self.format!r}")
|
|
207
|
+
parts.append(f"keep_alive={self.keep_alive!r}")
|
|
208
|
+
return (
|
|
209
|
+
f"{self.__class__.__qualname__}("
|
|
210
|
+
f"{', '.join(parts)}"
|
|
211
|
+
f")"
|
|
212
|
+
)
|
|
213
|
+
|
|
214
|
+
__repr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__repr__"
|
|
215
|
+
if '__repr__' in __dataclass__cls.__dict__:
|
|
216
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __repr__ in class {__dataclass__cls.__name__}")
|
|
217
|
+
setattr(__dataclass__cls, '__repr__', __repr__)
|
|
218
|
+
|
|
219
|
+
return _process_dataclass
|
|
220
|
+
|
|
221
|
+
|
|
222
|
+
@_register(
|
|
223
|
+
plan_repr=(
|
|
224
|
+
"Plans(tup=(CopyPlan(fields=('model', 'created_at', 'done', 'done_reason', 'total_duration', 'load_duration', '"
|
|
225
|
+
"prompt_eval_count', 'prompt_eval_duration', 'eval_count', 'eval_duration')), EqPlan(fields=('model', 'created_"
|
|
226
|
+
"at', 'done', 'done_reason', 'total_duration', 'load_duration', 'prompt_eval_count', 'prompt_eval_duration', 'e"
|
|
227
|
+
"val_count', 'eval_duration')), FrozenPlan(fields=('model', 'created_at', 'done', 'done_reason', 'total_duratio"
|
|
228
|
+
"n', 'load_duration', 'prompt_eval_count', 'prompt_eval_duration', 'eval_count', 'eval_duration'), allow_dynami"
|
|
229
|
+
"c_dunder_attrs=False), HashPlan(action='add', fields=('model', 'created_at', 'done', 'done_reason', 'total_dur"
|
|
230
|
+
"ation', 'load_duration', 'prompt_eval_count', 'prompt_eval_duration', 'eval_count', 'eval_duration'), cache=Fa"
|
|
231
|
+
"lse), InitPlan(fields=(InitPlan.Field(name='model', annotation=OpRef(name='init.fields.0.annotation'), default"
|
|
232
|
+
"=OpRef(name='init.fields.0.default'), default_factory=None, init=True, override=False, field_type=FieldType.IN"
|
|
233
|
+
"STANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='created_at', annotation=OpRef(name="
|
|
234
|
+
"'init.fields.1.annotation'), default=OpRef(name='init.fields.1.default'), default_factory=None, init=True, ove"
|
|
235
|
+
"rride=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name="
|
|
236
|
+
"'done', annotation=OpRef(name='init.fields.2.annotation'), default=OpRef(name='init.fields.2.default'), defaul"
|
|
237
|
+
"t_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_ty"
|
|
238
|
+
"pe=None), InitPlan.Field(name='done_reason', annotation=OpRef(name='init.fields.3.annotation'), default=OpRef("
|
|
239
|
+
"name='init.fields.3.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE,"
|
|
240
|
+
" coerce=None, validate=None, check_type=None), InitPlan.Field(name='total_duration', annotation=OpRef(name='in"
|
|
241
|
+
"it.fields.4.annotation'), default=OpRef(name='init.fields.4.default'), default_factory=None, init=True, overri"
|
|
242
|
+
"de=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='lo"
|
|
243
|
+
"ad_duration', annotation=OpRef(name='init.fields.5.annotation'), default=OpRef(name='init.fields.5.default'), "
|
|
244
|
+
"default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, ch"
|
|
245
|
+
"eck_type=None), InitPlan.Field(name='prompt_eval_count', annotation=OpRef(name='init.fields.6.annotation'), de"
|
|
246
|
+
"fault=OpRef(name='init.fields.6.default'), default_factory=None, init=True, override=False, field_type=FieldTy"
|
|
247
|
+
"pe.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='prompt_eval_duration', annotat"
|
|
248
|
+
"ion=OpRef(name='init.fields.7.annotation'), default=OpRef(name='init.fields.7.default'), default_factory=None,"
|
|
249
|
+
" init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitP"
|
|
250
|
+
"lan.Field(name='eval_count', annotation=OpRef(name='init.fields.8.annotation'), default=OpRef(name='init.field"
|
|
251
|
+
"s.8.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, va"
|
|
252
|
+
"lidate=None, check_type=None), InitPlan.Field(name='eval_duration', annotation=OpRef(name='init.fields.9.annot"
|
|
253
|
+
"ation'), default=OpRef(name='init.fields.9.default'), default_factory=None, init=True, override=False, field_t"
|
|
254
|
+
"ype=FieldType.INSTANCE, coerce=None, validate=None, check_type=None)), self_param='self', std_params=(), kw_on"
|
|
255
|
+
"ly_params=('model', 'created_at', 'done', 'done_reason', 'total_duration', 'load_duration', 'prompt_eval_count"
|
|
256
|
+
"', 'prompt_eval_duration', 'eval_count', 'eval_duration'), frozen=True, slots=False, post_init_params=None, in"
|
|
257
|
+
"it_fns=(), validate_fns=()), ReprPlan(fields=(ReprPlan.Field(name='model', kw_only=True, fn=None), ReprPlan.Fi"
|
|
258
|
+
"eld(name='created_at', kw_only=True, fn=None), ReprPlan.Field(name='done', kw_only=True, fn=None), ReprPlan.Fi"
|
|
259
|
+
"eld(name='done_reason', kw_only=True, fn=None), ReprPlan.Field(name='total_duration', kw_only=True, fn=None), "
|
|
260
|
+
"ReprPlan.Field(name='load_duration', kw_only=True, fn=None), ReprPlan.Field(name='prompt_eval_count', kw_only="
|
|
261
|
+
"True, fn=None), ReprPlan.Field(name='prompt_eval_duration', kw_only=True, fn=None), ReprPlan.Field(name='eval_"
|
|
262
|
+
"count', kw_only=True, fn=None), ReprPlan.Field(name='eval_duration', kw_only=True, fn=None)), id=False, terse="
|
|
263
|
+
"False, default_fn=None)))"
|
|
264
|
+
),
|
|
265
|
+
plan_repr_sha1='205d41e5f20db210da1989c24f7b9e3bf1ebccd3',
|
|
266
|
+
op_ref_idents=(
|
|
267
|
+
'__dataclass__init__fields__0__annotation',
|
|
268
|
+
'__dataclass__init__fields__0__default',
|
|
269
|
+
'__dataclass__init__fields__1__annotation',
|
|
270
|
+
'__dataclass__init__fields__1__default',
|
|
271
|
+
'__dataclass__init__fields__2__annotation',
|
|
272
|
+
'__dataclass__init__fields__2__default',
|
|
273
|
+
'__dataclass__init__fields__3__annotation',
|
|
274
|
+
'__dataclass__init__fields__3__default',
|
|
275
|
+
'__dataclass__init__fields__4__annotation',
|
|
276
|
+
'__dataclass__init__fields__4__default',
|
|
277
|
+
'__dataclass__init__fields__5__annotation',
|
|
278
|
+
'__dataclass__init__fields__5__default',
|
|
279
|
+
'__dataclass__init__fields__6__annotation',
|
|
280
|
+
'__dataclass__init__fields__6__default',
|
|
281
|
+
'__dataclass__init__fields__7__annotation',
|
|
282
|
+
'__dataclass__init__fields__7__default',
|
|
283
|
+
'__dataclass__init__fields__8__annotation',
|
|
284
|
+
'__dataclass__init__fields__8__default',
|
|
285
|
+
'__dataclass__init__fields__9__annotation',
|
|
286
|
+
'__dataclass__init__fields__9__default',
|
|
287
|
+
),
|
|
288
|
+
cls_names=(
|
|
289
|
+
('ommlds.backends.ollama.protocol', 'BaseGenerateResponse'),
|
|
290
|
+
),
|
|
291
|
+
)
|
|
292
|
+
def _process_dataclass__205d41e5f20db210da1989c24f7b9e3bf1ebccd3():
|
|
293
|
+
def _process_dataclass(
|
|
294
|
+
*,
|
|
295
|
+
__dataclass__cls,
|
|
296
|
+
__dataclass__init__fields__0__annotation,
|
|
297
|
+
__dataclass__init__fields__0__default,
|
|
298
|
+
__dataclass__init__fields__1__annotation,
|
|
299
|
+
__dataclass__init__fields__1__default,
|
|
300
|
+
__dataclass__init__fields__2__annotation,
|
|
301
|
+
__dataclass__init__fields__2__default,
|
|
302
|
+
__dataclass__init__fields__3__annotation,
|
|
303
|
+
__dataclass__init__fields__3__default,
|
|
304
|
+
__dataclass__init__fields__4__annotation,
|
|
305
|
+
__dataclass__init__fields__4__default,
|
|
306
|
+
__dataclass__init__fields__5__annotation,
|
|
307
|
+
__dataclass__init__fields__5__default,
|
|
308
|
+
__dataclass__init__fields__6__annotation,
|
|
309
|
+
__dataclass__init__fields__6__default,
|
|
310
|
+
__dataclass__init__fields__7__annotation,
|
|
311
|
+
__dataclass__init__fields__7__default,
|
|
312
|
+
__dataclass__init__fields__8__annotation,
|
|
313
|
+
__dataclass__init__fields__8__default,
|
|
314
|
+
__dataclass__init__fields__9__annotation,
|
|
315
|
+
__dataclass__init__fields__9__default,
|
|
316
|
+
__dataclass__FieldFnValidationError, # noqa
|
|
317
|
+
__dataclass__FieldTypeValidationError, # noqa
|
|
318
|
+
__dataclass__FnValidationError, # noqa
|
|
319
|
+
__dataclass__FrozenInstanceError=dataclasses.FrozenInstanceError, # noqa
|
|
320
|
+
__dataclass__FunctionType=types.FunctionType, # noqa
|
|
321
|
+
__dataclass__HAS_DEFAULT_FACTORY=dataclasses._HAS_DEFAULT_FACTORY, # noqa
|
|
322
|
+
__dataclass__MISSING=dataclasses.MISSING, # noqa
|
|
323
|
+
__dataclass__None=None, # noqa
|
|
324
|
+
__dataclass__TypeError=TypeError, # noqa
|
|
325
|
+
__dataclass___recursive_repr=reprlib.recursive_repr, # noqa
|
|
326
|
+
__dataclass__isinstance=isinstance, # noqa
|
|
327
|
+
__dataclass__object_setattr=object.__setattr__, # noqa
|
|
328
|
+
__dataclass__property=property, # noqa
|
|
329
|
+
):
|
|
330
|
+
def __copy__(self):
|
|
331
|
+
if self.__class__ is not __dataclass__cls:
|
|
332
|
+
raise TypeError(self)
|
|
333
|
+
return __dataclass__cls( # noqa
|
|
334
|
+
model=self.model,
|
|
335
|
+
created_at=self.created_at,
|
|
336
|
+
done=self.done,
|
|
337
|
+
done_reason=self.done_reason,
|
|
338
|
+
total_duration=self.total_duration,
|
|
339
|
+
load_duration=self.load_duration,
|
|
340
|
+
prompt_eval_count=self.prompt_eval_count,
|
|
341
|
+
prompt_eval_duration=self.prompt_eval_duration,
|
|
342
|
+
eval_count=self.eval_count,
|
|
343
|
+
eval_duration=self.eval_duration,
|
|
344
|
+
)
|
|
345
|
+
|
|
346
|
+
__copy__.__qualname__ = f"{__dataclass__cls.__qualname__}.__copy__"
|
|
347
|
+
if '__copy__' in __dataclass__cls.__dict__:
|
|
348
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __copy__ in class {__dataclass__cls.__name__}")
|
|
349
|
+
setattr(__dataclass__cls, '__copy__', __copy__)
|
|
350
|
+
|
|
351
|
+
def __eq__(self, other):
|
|
352
|
+
if self is other:
|
|
353
|
+
return True
|
|
354
|
+
if self.__class__ is not other.__class__:
|
|
355
|
+
return NotImplemented
|
|
356
|
+
return (
|
|
357
|
+
self.model == other.model and
|
|
358
|
+
self.created_at == other.created_at and
|
|
359
|
+
self.done == other.done and
|
|
360
|
+
self.done_reason == other.done_reason and
|
|
361
|
+
self.total_duration == other.total_duration and
|
|
362
|
+
self.load_duration == other.load_duration and
|
|
363
|
+
self.prompt_eval_count == other.prompt_eval_count and
|
|
364
|
+
self.prompt_eval_duration == other.prompt_eval_duration and
|
|
365
|
+
self.eval_count == other.eval_count and
|
|
366
|
+
self.eval_duration == other.eval_duration
|
|
367
|
+
)
|
|
368
|
+
|
|
369
|
+
__eq__.__qualname__ = f"{__dataclass__cls.__qualname__}.__eq__"
|
|
370
|
+
if '__eq__' in __dataclass__cls.__dict__:
|
|
371
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __eq__ in class {__dataclass__cls.__name__}")
|
|
372
|
+
setattr(__dataclass__cls, '__eq__', __eq__)
|
|
373
|
+
|
|
374
|
+
__dataclass___setattr_frozen_fields = {
|
|
375
|
+
'model',
|
|
376
|
+
'created_at',
|
|
377
|
+
'done',
|
|
378
|
+
'done_reason',
|
|
379
|
+
'total_duration',
|
|
380
|
+
'load_duration',
|
|
381
|
+
'prompt_eval_count',
|
|
382
|
+
'prompt_eval_duration',
|
|
383
|
+
'eval_count',
|
|
384
|
+
'eval_duration',
|
|
385
|
+
}
|
|
386
|
+
|
|
387
|
+
def __setattr__(self, name, value):
|
|
388
|
+
if (
|
|
389
|
+
type(self) is __dataclass__cls
|
|
390
|
+
or name in __dataclass___setattr_frozen_fields
|
|
391
|
+
):
|
|
392
|
+
raise __dataclass__FrozenInstanceError(f"cannot assign to field {name!r}")
|
|
393
|
+
super(__dataclass__cls, self).__setattr__(name, value)
|
|
394
|
+
|
|
395
|
+
__setattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__setattr__"
|
|
396
|
+
if '__setattr__' in __dataclass__cls.__dict__:
|
|
397
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __setattr__ in class {__dataclass__cls.__name__}")
|
|
398
|
+
setattr(__dataclass__cls, '__setattr__', __setattr__)
|
|
399
|
+
|
|
400
|
+
__dataclass___delattr_frozen_fields = {
|
|
401
|
+
'model',
|
|
402
|
+
'created_at',
|
|
403
|
+
'done',
|
|
404
|
+
'done_reason',
|
|
405
|
+
'total_duration',
|
|
406
|
+
'load_duration',
|
|
407
|
+
'prompt_eval_count',
|
|
408
|
+
'prompt_eval_duration',
|
|
409
|
+
'eval_count',
|
|
410
|
+
'eval_duration',
|
|
411
|
+
}
|
|
412
|
+
|
|
413
|
+
def __delattr__(self, name):
|
|
414
|
+
if (
|
|
415
|
+
type(self) is __dataclass__cls
|
|
416
|
+
or name in __dataclass___delattr_frozen_fields
|
|
417
|
+
):
|
|
418
|
+
raise __dataclass__FrozenInstanceError(f"cannot delete field {name!r}")
|
|
419
|
+
super(__dataclass__cls, self).__delattr__(name)
|
|
420
|
+
|
|
421
|
+
__delattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__delattr__"
|
|
422
|
+
if '__delattr__' in __dataclass__cls.__dict__:
|
|
423
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __delattr__ in class {__dataclass__cls.__name__}")
|
|
424
|
+
setattr(__dataclass__cls, '__delattr__', __delattr__)
|
|
425
|
+
|
|
426
|
+
def __hash__(self):
|
|
427
|
+
return hash((
|
|
428
|
+
self.model,
|
|
429
|
+
self.created_at,
|
|
430
|
+
self.done,
|
|
431
|
+
self.done_reason,
|
|
432
|
+
self.total_duration,
|
|
433
|
+
self.load_duration,
|
|
434
|
+
self.prompt_eval_count,
|
|
435
|
+
self.prompt_eval_duration,
|
|
436
|
+
self.eval_count,
|
|
437
|
+
self.eval_duration,
|
|
438
|
+
))
|
|
439
|
+
|
|
440
|
+
__hash__.__qualname__ = f"{__dataclass__cls.__qualname__}.__hash__"
|
|
441
|
+
setattr(__dataclass__cls, '__hash__', __hash__)
|
|
442
|
+
|
|
443
|
+
def __init__(
|
|
444
|
+
self,
|
|
445
|
+
*,
|
|
446
|
+
model: __dataclass__init__fields__0__annotation = __dataclass__init__fields__0__default,
|
|
447
|
+
created_at: __dataclass__init__fields__1__annotation = __dataclass__init__fields__1__default,
|
|
448
|
+
done: __dataclass__init__fields__2__annotation = __dataclass__init__fields__2__default,
|
|
449
|
+
done_reason: __dataclass__init__fields__3__annotation = __dataclass__init__fields__3__default,
|
|
450
|
+
total_duration: __dataclass__init__fields__4__annotation = __dataclass__init__fields__4__default,
|
|
451
|
+
load_duration: __dataclass__init__fields__5__annotation = __dataclass__init__fields__5__default,
|
|
452
|
+
prompt_eval_count: __dataclass__init__fields__6__annotation = __dataclass__init__fields__6__default,
|
|
453
|
+
prompt_eval_duration: __dataclass__init__fields__7__annotation = __dataclass__init__fields__7__default,
|
|
454
|
+
eval_count: __dataclass__init__fields__8__annotation = __dataclass__init__fields__8__default,
|
|
455
|
+
eval_duration: __dataclass__init__fields__9__annotation = __dataclass__init__fields__9__default,
|
|
456
|
+
) -> __dataclass__None:
|
|
457
|
+
__dataclass__object_setattr(self, 'model', model)
|
|
458
|
+
__dataclass__object_setattr(self, 'created_at', created_at)
|
|
459
|
+
__dataclass__object_setattr(self, 'done', done)
|
|
460
|
+
__dataclass__object_setattr(self, 'done_reason', done_reason)
|
|
461
|
+
__dataclass__object_setattr(self, 'total_duration', total_duration)
|
|
462
|
+
__dataclass__object_setattr(self, 'load_duration', load_duration)
|
|
463
|
+
__dataclass__object_setattr(self, 'prompt_eval_count', prompt_eval_count)
|
|
464
|
+
__dataclass__object_setattr(self, 'prompt_eval_duration', prompt_eval_duration)
|
|
465
|
+
__dataclass__object_setattr(self, 'eval_count', eval_count)
|
|
466
|
+
__dataclass__object_setattr(self, 'eval_duration', eval_duration)
|
|
467
|
+
|
|
468
|
+
__init__.__qualname__ = f"{__dataclass__cls.__qualname__}.__init__"
|
|
469
|
+
if '__init__' in __dataclass__cls.__dict__:
|
|
470
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __init__ in class {__dataclass__cls.__name__}")
|
|
471
|
+
setattr(__dataclass__cls, '__init__', __init__)
|
|
472
|
+
|
|
473
|
+
@__dataclass___recursive_repr()
|
|
474
|
+
def __repr__(self):
|
|
475
|
+
parts = []
|
|
476
|
+
parts.append(f"model={self.model!r}")
|
|
477
|
+
parts.append(f"created_at={self.created_at!r}")
|
|
478
|
+
parts.append(f"done={self.done!r}")
|
|
479
|
+
parts.append(f"done_reason={self.done_reason!r}")
|
|
480
|
+
parts.append(f"total_duration={self.total_duration!r}")
|
|
481
|
+
parts.append(f"load_duration={self.load_duration!r}")
|
|
482
|
+
parts.append(f"prompt_eval_count={self.prompt_eval_count!r}")
|
|
483
|
+
parts.append(f"prompt_eval_duration={self.prompt_eval_duration!r}")
|
|
484
|
+
parts.append(f"eval_count={self.eval_count!r}")
|
|
485
|
+
parts.append(f"eval_duration={self.eval_duration!r}")
|
|
486
|
+
return (
|
|
487
|
+
f"{self.__class__.__qualname__}("
|
|
488
|
+
f"{', '.join(parts)}"
|
|
489
|
+
f")"
|
|
490
|
+
)
|
|
491
|
+
|
|
492
|
+
__repr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__repr__"
|
|
493
|
+
if '__repr__' in __dataclass__cls.__dict__:
|
|
494
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __repr__ in class {__dataclass__cls.__name__}")
|
|
495
|
+
setattr(__dataclass__cls, '__repr__', __repr__)
|
|
496
|
+
|
|
497
|
+
return _process_dataclass
|
|
498
|
+
|
|
499
|
+
|
|
500
|
+
@_register(
|
|
501
|
+
plan_repr=(
|
|
502
|
+
"Plans(tup=(CopyPlan(fields=('model',)), EqPlan(fields=('model',)), FrozenPlan(fields=('model',), allow_dynamic"
|
|
503
|
+
"_dunder_attrs=False), HashPlan(action='add', fields=('model',), cache=False), InitPlan(fields=(InitPlan.Field("
|
|
504
|
+
"name='model', annotation=OpRef(name='init.fields.0.annotation'), default=None, default_factory=None, init=True"
|
|
505
|
+
", override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None),), self_param='s"
|
|
506
|
+
"elf', std_params=(), kw_only_params=('model',), frozen=True, slots=False, post_init_params=None, init_fns=(), "
|
|
507
|
+
"validate_fns=()), ReprPlan(fields=(ReprPlan.Field(name='model', kw_only=True, fn=None),), id=False, terse=Fals"
|
|
508
|
+
"e, default_fn=None)))"
|
|
509
|
+
),
|
|
510
|
+
plan_repr_sha1='3310a48624d055c5c24df97f58e5c8f296523505',
|
|
511
|
+
op_ref_idents=(
|
|
512
|
+
'__dataclass__init__fields__0__annotation',
|
|
513
|
+
),
|
|
514
|
+
cls_names=(
|
|
515
|
+
('ommlds.backends.ollama.protocol', 'BaseRequest'),
|
|
516
|
+
),
|
|
517
|
+
)
|
|
518
|
+
def _process_dataclass__3310a48624d055c5c24df97f58e5c8f296523505():
|
|
519
|
+
def _process_dataclass(
|
|
520
|
+
*,
|
|
521
|
+
__dataclass__cls,
|
|
522
|
+
__dataclass__init__fields__0__annotation,
|
|
523
|
+
__dataclass__FieldFnValidationError, # noqa
|
|
524
|
+
__dataclass__FieldTypeValidationError, # noqa
|
|
525
|
+
__dataclass__FnValidationError, # noqa
|
|
526
|
+
__dataclass__FrozenInstanceError=dataclasses.FrozenInstanceError, # noqa
|
|
527
|
+
__dataclass__FunctionType=types.FunctionType, # noqa
|
|
528
|
+
__dataclass__HAS_DEFAULT_FACTORY=dataclasses._HAS_DEFAULT_FACTORY, # noqa
|
|
529
|
+
__dataclass__MISSING=dataclasses.MISSING, # noqa
|
|
530
|
+
__dataclass__None=None, # noqa
|
|
531
|
+
__dataclass__TypeError=TypeError, # noqa
|
|
532
|
+
__dataclass___recursive_repr=reprlib.recursive_repr, # noqa
|
|
533
|
+
__dataclass__isinstance=isinstance, # noqa
|
|
534
|
+
__dataclass__object_setattr=object.__setattr__, # noqa
|
|
535
|
+
__dataclass__property=property, # noqa
|
|
536
|
+
):
|
|
537
|
+
def __copy__(self):
|
|
538
|
+
if self.__class__ is not __dataclass__cls:
|
|
539
|
+
raise TypeError(self)
|
|
540
|
+
return __dataclass__cls( # noqa
|
|
541
|
+
model=self.model,
|
|
542
|
+
)
|
|
543
|
+
|
|
544
|
+
__copy__.__qualname__ = f"{__dataclass__cls.__qualname__}.__copy__"
|
|
545
|
+
if '__copy__' in __dataclass__cls.__dict__:
|
|
546
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __copy__ in class {__dataclass__cls.__name__}")
|
|
547
|
+
setattr(__dataclass__cls, '__copy__', __copy__)
|
|
548
|
+
|
|
549
|
+
def __eq__(self, other):
|
|
550
|
+
if self is other:
|
|
551
|
+
return True
|
|
552
|
+
if self.__class__ is not other.__class__:
|
|
553
|
+
return NotImplemented
|
|
554
|
+
return (
|
|
555
|
+
self.model == other.model
|
|
556
|
+
)
|
|
557
|
+
|
|
558
|
+
__eq__.__qualname__ = f"{__dataclass__cls.__qualname__}.__eq__"
|
|
559
|
+
if '__eq__' in __dataclass__cls.__dict__:
|
|
560
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __eq__ in class {__dataclass__cls.__name__}")
|
|
561
|
+
setattr(__dataclass__cls, '__eq__', __eq__)
|
|
562
|
+
|
|
563
|
+
__dataclass___setattr_frozen_fields = {
|
|
564
|
+
'model',
|
|
565
|
+
}
|
|
566
|
+
|
|
567
|
+
def __setattr__(self, name, value):
|
|
568
|
+
if (
|
|
569
|
+
type(self) is __dataclass__cls
|
|
570
|
+
or name in __dataclass___setattr_frozen_fields
|
|
571
|
+
):
|
|
572
|
+
raise __dataclass__FrozenInstanceError(f"cannot assign to field {name!r}")
|
|
573
|
+
super(__dataclass__cls, self).__setattr__(name, value)
|
|
574
|
+
|
|
575
|
+
__setattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__setattr__"
|
|
576
|
+
if '__setattr__' in __dataclass__cls.__dict__:
|
|
577
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __setattr__ in class {__dataclass__cls.__name__}")
|
|
578
|
+
setattr(__dataclass__cls, '__setattr__', __setattr__)
|
|
579
|
+
|
|
580
|
+
__dataclass___delattr_frozen_fields = {
|
|
581
|
+
'model',
|
|
582
|
+
}
|
|
583
|
+
|
|
584
|
+
def __delattr__(self, name):
|
|
585
|
+
if (
|
|
586
|
+
type(self) is __dataclass__cls
|
|
587
|
+
or name in __dataclass___delattr_frozen_fields
|
|
588
|
+
):
|
|
589
|
+
raise __dataclass__FrozenInstanceError(f"cannot delete field {name!r}")
|
|
590
|
+
super(__dataclass__cls, self).__delattr__(name)
|
|
591
|
+
|
|
592
|
+
__delattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__delattr__"
|
|
593
|
+
if '__delattr__' in __dataclass__cls.__dict__:
|
|
594
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __delattr__ in class {__dataclass__cls.__name__}")
|
|
595
|
+
setattr(__dataclass__cls, '__delattr__', __delattr__)
|
|
596
|
+
|
|
597
|
+
def __hash__(self):
|
|
598
|
+
return hash((
|
|
599
|
+
self.model,
|
|
600
|
+
))
|
|
601
|
+
|
|
602
|
+
__hash__.__qualname__ = f"{__dataclass__cls.__qualname__}.__hash__"
|
|
603
|
+
setattr(__dataclass__cls, '__hash__', __hash__)
|
|
604
|
+
|
|
605
|
+
def __init__(
|
|
606
|
+
self,
|
|
607
|
+
*,
|
|
608
|
+
model: __dataclass__init__fields__0__annotation,
|
|
609
|
+
) -> __dataclass__None:
|
|
610
|
+
__dataclass__object_setattr(self, 'model', model)
|
|
611
|
+
|
|
612
|
+
__init__.__qualname__ = f"{__dataclass__cls.__qualname__}.__init__"
|
|
613
|
+
if '__init__' in __dataclass__cls.__dict__:
|
|
614
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __init__ in class {__dataclass__cls.__name__}")
|
|
615
|
+
setattr(__dataclass__cls, '__init__', __init__)
|
|
616
|
+
|
|
617
|
+
@__dataclass___recursive_repr()
|
|
618
|
+
def __repr__(self):
|
|
619
|
+
parts = []
|
|
620
|
+
parts.append(f"model={self.model!r}")
|
|
621
|
+
return (
|
|
622
|
+
f"{self.__class__.__qualname__}("
|
|
623
|
+
f"{', '.join(parts)}"
|
|
624
|
+
f")"
|
|
625
|
+
)
|
|
626
|
+
|
|
627
|
+
__repr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__repr__"
|
|
628
|
+
if '__repr__' in __dataclass__cls.__dict__:
|
|
629
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __repr__ in class {__dataclass__cls.__name__}")
|
|
630
|
+
setattr(__dataclass__cls, '__repr__', __repr__)
|
|
631
|
+
|
|
632
|
+
return _process_dataclass
|
|
633
|
+
|
|
634
|
+
|
|
635
|
+
@_register(
|
|
636
|
+
plan_repr=(
|
|
637
|
+
"Plans(tup=(CopyPlan(fields=('model', 'stream')), EqPlan(fields=('model', 'stream')), FrozenPlan(fields=('model"
|
|
638
|
+
"', 'stream'), allow_dynamic_dunder_attrs=False), HashPlan(action='add', fields=('model', 'stream'), cache=Fals"
|
|
639
|
+
"e), InitPlan(fields=(InitPlan.Field(name='model', annotation=OpRef(name='init.fields.0.annotation'), default=N"
|
|
640
|
+
"one, default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=Non"
|
|
641
|
+
"e, check_type=None), InitPlan.Field(name='stream', annotation=OpRef(name='init.fields.1.annotation'), default="
|
|
642
|
+
"OpRef(name='init.fields.1.default'), default_factory=None, init=True, override=False, field_type=FieldType.INS"
|
|
643
|
+
"TANCE, coerce=None, validate=None, check_type=None)), self_param='self', std_params=(), kw_only_params=('model"
|
|
644
|
+
"', 'stream'), frozen=True, slots=False, post_init_params=None, init_fns=(), validate_fns=()), ReprPlan(fields="
|
|
645
|
+
"(ReprPlan.Field(name='model', kw_only=True, fn=None), ReprPlan.Field(name='stream', kw_only=True, fn=None)), i"
|
|
646
|
+
"d=False, terse=False, default_fn=None)))"
|
|
647
|
+
),
|
|
648
|
+
plan_repr_sha1='a0c68d946968391197d0c66f362ca6c3fed8d7a2',
|
|
649
|
+
op_ref_idents=(
|
|
650
|
+
'__dataclass__init__fields__0__annotation',
|
|
651
|
+
'__dataclass__init__fields__1__annotation',
|
|
652
|
+
'__dataclass__init__fields__1__default',
|
|
653
|
+
),
|
|
654
|
+
cls_names=(
|
|
655
|
+
('ommlds.backends.ollama.protocol', 'BaseStreamableRequest'),
|
|
656
|
+
),
|
|
657
|
+
)
|
|
658
|
+
def _process_dataclass__a0c68d946968391197d0c66f362ca6c3fed8d7a2():
|
|
659
|
+
def _process_dataclass(
|
|
660
|
+
*,
|
|
661
|
+
__dataclass__cls,
|
|
662
|
+
__dataclass__init__fields__0__annotation,
|
|
663
|
+
__dataclass__init__fields__1__annotation,
|
|
664
|
+
__dataclass__init__fields__1__default,
|
|
665
|
+
__dataclass__FieldFnValidationError, # noqa
|
|
666
|
+
__dataclass__FieldTypeValidationError, # noqa
|
|
667
|
+
__dataclass__FnValidationError, # noqa
|
|
668
|
+
__dataclass__FrozenInstanceError=dataclasses.FrozenInstanceError, # noqa
|
|
669
|
+
__dataclass__FunctionType=types.FunctionType, # noqa
|
|
670
|
+
__dataclass__HAS_DEFAULT_FACTORY=dataclasses._HAS_DEFAULT_FACTORY, # noqa
|
|
671
|
+
__dataclass__MISSING=dataclasses.MISSING, # noqa
|
|
672
|
+
__dataclass__None=None, # noqa
|
|
673
|
+
__dataclass__TypeError=TypeError, # noqa
|
|
674
|
+
__dataclass___recursive_repr=reprlib.recursive_repr, # noqa
|
|
675
|
+
__dataclass__isinstance=isinstance, # noqa
|
|
676
|
+
__dataclass__object_setattr=object.__setattr__, # noqa
|
|
677
|
+
__dataclass__property=property, # noqa
|
|
678
|
+
):
|
|
679
|
+
def __copy__(self):
|
|
680
|
+
if self.__class__ is not __dataclass__cls:
|
|
681
|
+
raise TypeError(self)
|
|
682
|
+
return __dataclass__cls( # noqa
|
|
683
|
+
model=self.model,
|
|
684
|
+
stream=self.stream,
|
|
685
|
+
)
|
|
686
|
+
|
|
687
|
+
__copy__.__qualname__ = f"{__dataclass__cls.__qualname__}.__copy__"
|
|
688
|
+
if '__copy__' in __dataclass__cls.__dict__:
|
|
689
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __copy__ in class {__dataclass__cls.__name__}")
|
|
690
|
+
setattr(__dataclass__cls, '__copy__', __copy__)
|
|
691
|
+
|
|
692
|
+
def __eq__(self, other):
|
|
693
|
+
if self is other:
|
|
694
|
+
return True
|
|
695
|
+
if self.__class__ is not other.__class__:
|
|
696
|
+
return NotImplemented
|
|
697
|
+
return (
|
|
698
|
+
self.model == other.model and
|
|
699
|
+
self.stream == other.stream
|
|
700
|
+
)
|
|
701
|
+
|
|
702
|
+
__eq__.__qualname__ = f"{__dataclass__cls.__qualname__}.__eq__"
|
|
703
|
+
if '__eq__' in __dataclass__cls.__dict__:
|
|
704
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __eq__ in class {__dataclass__cls.__name__}")
|
|
705
|
+
setattr(__dataclass__cls, '__eq__', __eq__)
|
|
706
|
+
|
|
707
|
+
__dataclass___setattr_frozen_fields = {
|
|
708
|
+
'model',
|
|
709
|
+
'stream',
|
|
710
|
+
}
|
|
711
|
+
|
|
712
|
+
def __setattr__(self, name, value):
|
|
713
|
+
if (
|
|
714
|
+
type(self) is __dataclass__cls
|
|
715
|
+
or name in __dataclass___setattr_frozen_fields
|
|
716
|
+
):
|
|
717
|
+
raise __dataclass__FrozenInstanceError(f"cannot assign to field {name!r}")
|
|
718
|
+
super(__dataclass__cls, self).__setattr__(name, value)
|
|
719
|
+
|
|
720
|
+
__setattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__setattr__"
|
|
721
|
+
if '__setattr__' in __dataclass__cls.__dict__:
|
|
722
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __setattr__ in class {__dataclass__cls.__name__}")
|
|
723
|
+
setattr(__dataclass__cls, '__setattr__', __setattr__)
|
|
724
|
+
|
|
725
|
+
__dataclass___delattr_frozen_fields = {
|
|
726
|
+
'model',
|
|
727
|
+
'stream',
|
|
728
|
+
}
|
|
729
|
+
|
|
730
|
+
def __delattr__(self, name):
|
|
731
|
+
if (
|
|
732
|
+
type(self) is __dataclass__cls
|
|
733
|
+
or name in __dataclass___delattr_frozen_fields
|
|
734
|
+
):
|
|
735
|
+
raise __dataclass__FrozenInstanceError(f"cannot delete field {name!r}")
|
|
736
|
+
super(__dataclass__cls, self).__delattr__(name)
|
|
737
|
+
|
|
738
|
+
__delattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__delattr__"
|
|
739
|
+
if '__delattr__' in __dataclass__cls.__dict__:
|
|
740
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __delattr__ in class {__dataclass__cls.__name__}")
|
|
741
|
+
setattr(__dataclass__cls, '__delattr__', __delattr__)
|
|
742
|
+
|
|
743
|
+
def __hash__(self):
|
|
744
|
+
return hash((
|
|
745
|
+
self.model,
|
|
746
|
+
self.stream,
|
|
747
|
+
))
|
|
748
|
+
|
|
749
|
+
__hash__.__qualname__ = f"{__dataclass__cls.__qualname__}.__hash__"
|
|
750
|
+
setattr(__dataclass__cls, '__hash__', __hash__)
|
|
751
|
+
|
|
752
|
+
def __init__(
|
|
753
|
+
self,
|
|
754
|
+
*,
|
|
755
|
+
model: __dataclass__init__fields__0__annotation,
|
|
756
|
+
stream: __dataclass__init__fields__1__annotation = __dataclass__init__fields__1__default,
|
|
757
|
+
) -> __dataclass__None:
|
|
758
|
+
__dataclass__object_setattr(self, 'model', model)
|
|
759
|
+
__dataclass__object_setattr(self, 'stream', stream)
|
|
760
|
+
|
|
761
|
+
__init__.__qualname__ = f"{__dataclass__cls.__qualname__}.__init__"
|
|
762
|
+
if '__init__' in __dataclass__cls.__dict__:
|
|
763
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __init__ in class {__dataclass__cls.__name__}")
|
|
764
|
+
setattr(__dataclass__cls, '__init__', __init__)
|
|
765
|
+
|
|
766
|
+
@__dataclass___recursive_repr()
|
|
767
|
+
def __repr__(self):
|
|
768
|
+
parts = []
|
|
769
|
+
parts.append(f"model={self.model!r}")
|
|
770
|
+
parts.append(f"stream={self.stream!r}")
|
|
771
|
+
return (
|
|
772
|
+
f"{self.__class__.__qualname__}("
|
|
773
|
+
f"{', '.join(parts)}"
|
|
774
|
+
f")"
|
|
775
|
+
)
|
|
776
|
+
|
|
777
|
+
__repr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__repr__"
|
|
778
|
+
if '__repr__' in __dataclass__cls.__dict__:
|
|
779
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __repr__ in class {__dataclass__cls.__name__}")
|
|
780
|
+
setattr(__dataclass__cls, '__repr__', __repr__)
|
|
781
|
+
|
|
782
|
+
return _process_dataclass
|
|
783
|
+
|
|
784
|
+
|
|
785
|
+
@_register(
|
|
786
|
+
plan_repr=(
|
|
787
|
+
"Plans(tup=(CopyPlan(fields=('model', 'stream', 'options', 'format', 'keep_alive', 'messages', 'tools', 'think'"
|
|
788
|
+
")), EqPlan(fields=('model', 'stream', 'options', 'format', 'keep_alive', 'messages', 'tools', 'think')), Froze"
|
|
789
|
+
"nPlan(fields=('model', 'stream', 'options', 'format', 'keep_alive', 'messages', 'tools', 'think'), allow_dynam"
|
|
790
|
+
"ic_dunder_attrs=False), HashPlan(action='add', fields=('model', 'stream', 'options', 'format', 'keep_alive', '"
|
|
791
|
+
"messages', 'tools', 'think'), cache=False), InitPlan(fields=(InitPlan.Field(name='model', annotation=OpRef(nam"
|
|
792
|
+
"e='init.fields.0.annotation'), default=None, default_factory=None, init=True, override=False, field_type=Field"
|
|
793
|
+
"Type.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='stream', annotation=OpRef(na"
|
|
794
|
+
"me='init.fields.1.annotation'), default=OpRef(name='init.fields.1.default'), default_factory=None, init=True, "
|
|
795
|
+
"override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(na"
|
|
796
|
+
"me='options', annotation=OpRef(name='init.fields.2.annotation'), default=OpRef(name='init.fields.2.default'), "
|
|
797
|
+
"default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, ch"
|
|
798
|
+
"eck_type=None), InitPlan.Field(name='format', annotation=OpRef(name='init.fields.3.annotation'), default=OpRef"
|
|
799
|
+
"(name='init.fields.3.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE"
|
|
800
|
+
", coerce=None, validate=None, check_type=None), InitPlan.Field(name='keep_alive', annotation=OpRef(name='init."
|
|
801
|
+
"fields.4.annotation'), default=OpRef(name='init.fields.4.default'), default_factory=None, init=True, override="
|
|
802
|
+
"False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='messa"
|
|
803
|
+
"ges', annotation=OpRef(name='init.fields.5.annotation'), default=OpRef(name='init.fields.5.default'), default_"
|
|
804
|
+
"factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type"
|
|
805
|
+
"=None), InitPlan.Field(name='tools', annotation=OpRef(name='init.fields.6.annotation'), default=OpRef(name='in"
|
|
806
|
+
"it.fields.6.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce="
|
|
807
|
+
"None, validate=None, check_type=None), InitPlan.Field(name='think', annotation=OpRef(name='init.fields.7.annot"
|
|
808
|
+
"ation'), default=OpRef(name='init.fields.7.default'), default_factory=None, init=True, override=False, field_t"
|
|
809
|
+
"ype=FieldType.INSTANCE, coerce=None, validate=None, check_type=None)), self_param='self', std_params=(), kw_on"
|
|
810
|
+
"ly_params=('model', 'stream', 'options', 'format', 'keep_alive', 'messages', 'tools', 'think'), frozen=True, s"
|
|
811
|
+
"lots=False, post_init_params=None, init_fns=(), validate_fns=()), ReprPlan(fields=(ReprPlan.Field(name='model'"
|
|
812
|
+
", kw_only=True, fn=None), ReprPlan.Field(name='stream', kw_only=True, fn=None), ReprPlan.Field(name='options',"
|
|
813
|
+
" kw_only=True, fn=None), ReprPlan.Field(name='format', kw_only=True, fn=None), ReprPlan.Field(name='keep_alive"
|
|
814
|
+
"', kw_only=True, fn=None), ReprPlan.Field(name='messages', kw_only=True, fn=None), ReprPlan.Field(name='tools'"
|
|
815
|
+
", kw_only=True, fn=None), ReprPlan.Field(name='think', kw_only=True, fn=None)), id=False, terse=False, default"
|
|
816
|
+
"_fn=OpRef(name='repr.default_fn'))))"
|
|
817
|
+
),
|
|
818
|
+
plan_repr_sha1='82c5163f58a3474e87891ea77e9a516262229fcb',
|
|
819
|
+
op_ref_idents=(
|
|
820
|
+
'__dataclass__init__fields__0__annotation',
|
|
821
|
+
'__dataclass__init__fields__1__annotation',
|
|
822
|
+
'__dataclass__init__fields__1__default',
|
|
823
|
+
'__dataclass__init__fields__2__annotation',
|
|
824
|
+
'__dataclass__init__fields__2__default',
|
|
825
|
+
'__dataclass__init__fields__3__annotation',
|
|
826
|
+
'__dataclass__init__fields__3__default',
|
|
827
|
+
'__dataclass__init__fields__4__annotation',
|
|
828
|
+
'__dataclass__init__fields__4__default',
|
|
829
|
+
'__dataclass__init__fields__5__annotation',
|
|
830
|
+
'__dataclass__init__fields__5__default',
|
|
831
|
+
'__dataclass__init__fields__6__annotation',
|
|
832
|
+
'__dataclass__init__fields__6__default',
|
|
833
|
+
'__dataclass__init__fields__7__annotation',
|
|
834
|
+
'__dataclass__init__fields__7__default',
|
|
835
|
+
'__dataclass__repr__default_fn',
|
|
836
|
+
),
|
|
837
|
+
cls_names=(
|
|
838
|
+
('ommlds.backends.ollama.protocol', 'ChatRequest'),
|
|
839
|
+
),
|
|
840
|
+
)
|
|
841
|
+
def _process_dataclass__82c5163f58a3474e87891ea77e9a516262229fcb():
|
|
842
|
+
def _process_dataclass(
|
|
843
|
+
*,
|
|
844
|
+
__dataclass__cls,
|
|
845
|
+
__dataclass__init__fields__0__annotation,
|
|
846
|
+
__dataclass__init__fields__1__annotation,
|
|
847
|
+
__dataclass__init__fields__1__default,
|
|
848
|
+
__dataclass__init__fields__2__annotation,
|
|
849
|
+
__dataclass__init__fields__2__default,
|
|
850
|
+
__dataclass__init__fields__3__annotation,
|
|
851
|
+
__dataclass__init__fields__3__default,
|
|
852
|
+
__dataclass__init__fields__4__annotation,
|
|
853
|
+
__dataclass__init__fields__4__default,
|
|
854
|
+
__dataclass__init__fields__5__annotation,
|
|
855
|
+
__dataclass__init__fields__5__default,
|
|
856
|
+
__dataclass__init__fields__6__annotation,
|
|
857
|
+
__dataclass__init__fields__6__default,
|
|
858
|
+
__dataclass__init__fields__7__annotation,
|
|
859
|
+
__dataclass__init__fields__7__default,
|
|
860
|
+
__dataclass__repr__default_fn,
|
|
861
|
+
__dataclass__FieldFnValidationError, # noqa
|
|
862
|
+
__dataclass__FieldTypeValidationError, # noqa
|
|
863
|
+
__dataclass__FnValidationError, # noqa
|
|
864
|
+
__dataclass__FrozenInstanceError=dataclasses.FrozenInstanceError, # noqa
|
|
865
|
+
__dataclass__FunctionType=types.FunctionType, # noqa
|
|
866
|
+
__dataclass__HAS_DEFAULT_FACTORY=dataclasses._HAS_DEFAULT_FACTORY, # noqa
|
|
867
|
+
__dataclass__MISSING=dataclasses.MISSING, # noqa
|
|
868
|
+
__dataclass__None=None, # noqa
|
|
869
|
+
__dataclass__TypeError=TypeError, # noqa
|
|
870
|
+
__dataclass___recursive_repr=reprlib.recursive_repr, # noqa
|
|
871
|
+
__dataclass__isinstance=isinstance, # noqa
|
|
872
|
+
__dataclass__object_setattr=object.__setattr__, # noqa
|
|
873
|
+
__dataclass__property=property, # noqa
|
|
874
|
+
):
|
|
875
|
+
def __copy__(self):
|
|
876
|
+
if self.__class__ is not __dataclass__cls:
|
|
877
|
+
raise TypeError(self)
|
|
878
|
+
return __dataclass__cls( # noqa
|
|
879
|
+
model=self.model,
|
|
880
|
+
stream=self.stream,
|
|
881
|
+
options=self.options,
|
|
882
|
+
format=self.format,
|
|
883
|
+
keep_alive=self.keep_alive,
|
|
884
|
+
messages=self.messages,
|
|
885
|
+
tools=self.tools,
|
|
886
|
+
think=self.think,
|
|
887
|
+
)
|
|
888
|
+
|
|
889
|
+
__copy__.__qualname__ = f"{__dataclass__cls.__qualname__}.__copy__"
|
|
890
|
+
if '__copy__' in __dataclass__cls.__dict__:
|
|
891
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __copy__ in class {__dataclass__cls.__name__}")
|
|
892
|
+
setattr(__dataclass__cls, '__copy__', __copy__)
|
|
893
|
+
|
|
894
|
+
def __eq__(self, other):
|
|
895
|
+
if self is other:
|
|
896
|
+
return True
|
|
897
|
+
if self.__class__ is not other.__class__:
|
|
898
|
+
return NotImplemented
|
|
899
|
+
return (
|
|
900
|
+
self.model == other.model and
|
|
901
|
+
self.stream == other.stream and
|
|
902
|
+
self.options == other.options and
|
|
903
|
+
self.format == other.format and
|
|
904
|
+
self.keep_alive == other.keep_alive and
|
|
905
|
+
self.messages == other.messages and
|
|
906
|
+
self.tools == other.tools and
|
|
907
|
+
self.think == other.think
|
|
908
|
+
)
|
|
909
|
+
|
|
910
|
+
__eq__.__qualname__ = f"{__dataclass__cls.__qualname__}.__eq__"
|
|
911
|
+
if '__eq__' in __dataclass__cls.__dict__:
|
|
912
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __eq__ in class {__dataclass__cls.__name__}")
|
|
913
|
+
setattr(__dataclass__cls, '__eq__', __eq__)
|
|
914
|
+
|
|
915
|
+
__dataclass___setattr_frozen_fields = {
|
|
916
|
+
'model',
|
|
917
|
+
'stream',
|
|
918
|
+
'options',
|
|
919
|
+
'format',
|
|
920
|
+
'keep_alive',
|
|
921
|
+
'messages',
|
|
922
|
+
'tools',
|
|
923
|
+
'think',
|
|
924
|
+
}
|
|
925
|
+
|
|
926
|
+
def __setattr__(self, name, value):
|
|
927
|
+
if (
|
|
928
|
+
type(self) is __dataclass__cls
|
|
929
|
+
or name in __dataclass___setattr_frozen_fields
|
|
930
|
+
):
|
|
931
|
+
raise __dataclass__FrozenInstanceError(f"cannot assign to field {name!r}")
|
|
932
|
+
super(__dataclass__cls, self).__setattr__(name, value)
|
|
933
|
+
|
|
934
|
+
__setattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__setattr__"
|
|
935
|
+
if '__setattr__' in __dataclass__cls.__dict__:
|
|
936
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __setattr__ in class {__dataclass__cls.__name__}")
|
|
937
|
+
setattr(__dataclass__cls, '__setattr__', __setattr__)
|
|
938
|
+
|
|
939
|
+
__dataclass___delattr_frozen_fields = {
|
|
940
|
+
'model',
|
|
941
|
+
'stream',
|
|
942
|
+
'options',
|
|
943
|
+
'format',
|
|
944
|
+
'keep_alive',
|
|
945
|
+
'messages',
|
|
946
|
+
'tools',
|
|
947
|
+
'think',
|
|
948
|
+
}
|
|
949
|
+
|
|
950
|
+
def __delattr__(self, name):
|
|
951
|
+
if (
|
|
952
|
+
type(self) is __dataclass__cls
|
|
953
|
+
or name in __dataclass___delattr_frozen_fields
|
|
954
|
+
):
|
|
955
|
+
raise __dataclass__FrozenInstanceError(f"cannot delete field {name!r}")
|
|
956
|
+
super(__dataclass__cls, self).__delattr__(name)
|
|
957
|
+
|
|
958
|
+
__delattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__delattr__"
|
|
959
|
+
if '__delattr__' in __dataclass__cls.__dict__:
|
|
960
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __delattr__ in class {__dataclass__cls.__name__}")
|
|
961
|
+
setattr(__dataclass__cls, '__delattr__', __delattr__)
|
|
962
|
+
|
|
963
|
+
def __hash__(self):
|
|
964
|
+
return hash((
|
|
965
|
+
self.model,
|
|
966
|
+
self.stream,
|
|
967
|
+
self.options,
|
|
968
|
+
self.format,
|
|
969
|
+
self.keep_alive,
|
|
970
|
+
self.messages,
|
|
971
|
+
self.tools,
|
|
972
|
+
self.think,
|
|
973
|
+
))
|
|
974
|
+
|
|
975
|
+
__hash__.__qualname__ = f"{__dataclass__cls.__qualname__}.__hash__"
|
|
976
|
+
setattr(__dataclass__cls, '__hash__', __hash__)
|
|
977
|
+
|
|
978
|
+
def __init__(
|
|
979
|
+
self,
|
|
980
|
+
*,
|
|
981
|
+
model: __dataclass__init__fields__0__annotation,
|
|
982
|
+
stream: __dataclass__init__fields__1__annotation = __dataclass__init__fields__1__default,
|
|
983
|
+
options: __dataclass__init__fields__2__annotation = __dataclass__init__fields__2__default,
|
|
984
|
+
format: __dataclass__init__fields__3__annotation = __dataclass__init__fields__3__default,
|
|
985
|
+
keep_alive: __dataclass__init__fields__4__annotation = __dataclass__init__fields__4__default,
|
|
986
|
+
messages: __dataclass__init__fields__5__annotation = __dataclass__init__fields__5__default,
|
|
987
|
+
tools: __dataclass__init__fields__6__annotation = __dataclass__init__fields__6__default,
|
|
988
|
+
think: __dataclass__init__fields__7__annotation = __dataclass__init__fields__7__default,
|
|
989
|
+
) -> __dataclass__None:
|
|
990
|
+
__dataclass__object_setattr(self, 'model', model)
|
|
991
|
+
__dataclass__object_setattr(self, 'stream', stream)
|
|
992
|
+
__dataclass__object_setattr(self, 'options', options)
|
|
993
|
+
__dataclass__object_setattr(self, 'format', format)
|
|
994
|
+
__dataclass__object_setattr(self, 'keep_alive', keep_alive)
|
|
995
|
+
__dataclass__object_setattr(self, 'messages', messages)
|
|
996
|
+
__dataclass__object_setattr(self, 'tools', tools)
|
|
997
|
+
__dataclass__object_setattr(self, 'think', think)
|
|
998
|
+
|
|
999
|
+
__init__.__qualname__ = f"{__dataclass__cls.__qualname__}.__init__"
|
|
1000
|
+
if '__init__' in __dataclass__cls.__dict__:
|
|
1001
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __init__ in class {__dataclass__cls.__name__}")
|
|
1002
|
+
setattr(__dataclass__cls, '__init__', __init__)
|
|
1003
|
+
|
|
1004
|
+
@__dataclass___recursive_repr()
|
|
1005
|
+
def __repr__(self):
|
|
1006
|
+
parts = []
|
|
1007
|
+
if (s := __dataclass__repr__default_fn(self.model)) is not None:
|
|
1008
|
+
parts.append(f"model={s}")
|
|
1009
|
+
if (s := __dataclass__repr__default_fn(self.stream)) is not None:
|
|
1010
|
+
parts.append(f"stream={s}")
|
|
1011
|
+
if (s := __dataclass__repr__default_fn(self.options)) is not None:
|
|
1012
|
+
parts.append(f"options={s}")
|
|
1013
|
+
if (s := __dataclass__repr__default_fn(self.format)) is not None:
|
|
1014
|
+
parts.append(f"format={s}")
|
|
1015
|
+
if (s := __dataclass__repr__default_fn(self.keep_alive)) is not None:
|
|
1016
|
+
parts.append(f"keep_alive={s}")
|
|
1017
|
+
if (s := __dataclass__repr__default_fn(self.messages)) is not None:
|
|
1018
|
+
parts.append(f"messages={s}")
|
|
1019
|
+
if (s := __dataclass__repr__default_fn(self.tools)) is not None:
|
|
1020
|
+
parts.append(f"tools={s}")
|
|
1021
|
+
if (s := __dataclass__repr__default_fn(self.think)) is not None:
|
|
1022
|
+
parts.append(f"think={s}")
|
|
1023
|
+
return (
|
|
1024
|
+
f"{self.__class__.__qualname__}("
|
|
1025
|
+
f"{', '.join(parts)}"
|
|
1026
|
+
f")"
|
|
1027
|
+
)
|
|
1028
|
+
|
|
1029
|
+
__repr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__repr__"
|
|
1030
|
+
if '__repr__' in __dataclass__cls.__dict__:
|
|
1031
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __repr__ in class {__dataclass__cls.__name__}")
|
|
1032
|
+
setattr(__dataclass__cls, '__repr__', __repr__)
|
|
1033
|
+
|
|
1034
|
+
return _process_dataclass
|
|
1035
|
+
|
|
1036
|
+
|
|
1037
|
+
@_register(
|
|
1038
|
+
plan_repr=(
|
|
1039
|
+
"Plans(tup=(CopyPlan(fields=('model', 'created_at', 'done', 'done_reason', 'total_duration', 'load_duration', '"
|
|
1040
|
+
"prompt_eval_count', 'prompt_eval_duration', 'eval_count', 'eval_duration', 'message')), EqPlan(fields=('model'"
|
|
1041
|
+
", 'created_at', 'done', 'done_reason', 'total_duration', 'load_duration', 'prompt_eval_count', 'prompt_eval_du"
|
|
1042
|
+
"ration', 'eval_count', 'eval_duration', 'message')), FrozenPlan(fields=('model', 'created_at', 'done', 'done_r"
|
|
1043
|
+
"eason', 'total_duration', 'load_duration', 'prompt_eval_count', 'prompt_eval_duration', 'eval_count', 'eval_du"
|
|
1044
|
+
"ration', 'message'), allow_dynamic_dunder_attrs=False), HashPlan(action='add', fields=('model', 'created_at', "
|
|
1045
|
+
"'done', 'done_reason', 'total_duration', 'load_duration', 'prompt_eval_count', 'prompt_eval_duration', 'eval_c"
|
|
1046
|
+
"ount', 'eval_duration', 'message'), cache=False), InitPlan(fields=(InitPlan.Field(name='model', annotation=OpR"
|
|
1047
|
+
"ef(name='init.fields.0.annotation'), default=OpRef(name='init.fields.0.default'), default_factory=None, init=T"
|
|
1048
|
+
"rue, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Fie"
|
|
1049
|
+
"ld(name='created_at', annotation=OpRef(name='init.fields.1.annotation'), default=OpRef(name='init.fields.1.def"
|
|
1050
|
+
"ault'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate="
|
|
1051
|
+
"None, check_type=None), InitPlan.Field(name='done', annotation=OpRef(name='init.fields.2.annotation'), default"
|
|
1052
|
+
"=OpRef(name='init.fields.2.default'), default_factory=None, init=True, override=False, field_type=FieldType.IN"
|
|
1053
|
+
"STANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='done_reason', annotation=OpRef(name"
|
|
1054
|
+
"='init.fields.3.annotation'), default=OpRef(name='init.fields.3.default'), default_factory=None, init=True, ov"
|
|
1055
|
+
"erride=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name"
|
|
1056
|
+
"='total_duration', annotation=OpRef(name='init.fields.4.annotation'), default=OpRef(name='init.fields.4.defaul"
|
|
1057
|
+
"t'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=Non"
|
|
1058
|
+
"e, check_type=None), InitPlan.Field(name='load_duration', annotation=OpRef(name='init.fields.5.annotation'), d"
|
|
1059
|
+
"efault=OpRef(name='init.fields.5.default'), default_factory=None, init=True, override=False, field_type=FieldT"
|
|
1060
|
+
"ype.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='prompt_eval_count', annotatio"
|
|
1061
|
+
"n=OpRef(name='init.fields.6.annotation'), default=OpRef(name='init.fields.6.default'), default_factory=None, i"
|
|
1062
|
+
"nit=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPla"
|
|
1063
|
+
"n.Field(name='prompt_eval_duration', annotation=OpRef(name='init.fields.7.annotation'), default=OpRef(name='in"
|
|
1064
|
+
"it.fields.7.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce="
|
|
1065
|
+
"None, validate=None, check_type=None), InitPlan.Field(name='eval_count', annotation=OpRef(name='init.fields.8."
|
|
1066
|
+
"annotation'), default=OpRef(name='init.fields.8.default'), default_factory=None, init=True, override=False, fi"
|
|
1067
|
+
"eld_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='eval_duration'"
|
|
1068
|
+
", annotation=OpRef(name='init.fields.9.annotation'), default=OpRef(name='init.fields.9.default'), default_fact"
|
|
1069
|
+
"ory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=Non"
|
|
1070
|
+
"e), InitPlan.Field(name='message', annotation=OpRef(name='init.fields.10.annotation'), default=None, default_f"
|
|
1071
|
+
"actory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type="
|
|
1072
|
+
"None)), self_param='self', std_params=(), kw_only_params=('model', 'created_at', 'done', 'done_reason', 'total"
|
|
1073
|
+
"_duration', 'load_duration', 'prompt_eval_count', 'prompt_eval_duration', 'eval_count', 'eval_duration', 'mess"
|
|
1074
|
+
"age'), frozen=True, slots=False, post_init_params=None, init_fns=(), validate_fns=()), ReprPlan(fields=(ReprPl"
|
|
1075
|
+
"an.Field(name='model', kw_only=True, fn=None), ReprPlan.Field(name='created_at', kw_only=True, fn=None), ReprP"
|
|
1076
|
+
"lan.Field(name='done', kw_only=True, fn=None), ReprPlan.Field(name='done_reason', kw_only=True, fn=None), Repr"
|
|
1077
|
+
"Plan.Field(name='total_duration', kw_only=True, fn=None), ReprPlan.Field(name='load_duration', kw_only=True, f"
|
|
1078
|
+
"n=None), ReprPlan.Field(name='prompt_eval_count', kw_only=True, fn=None), ReprPlan.Field(name='prompt_eval_dur"
|
|
1079
|
+
"ation', kw_only=True, fn=None), ReprPlan.Field(name='eval_count', kw_only=True, fn=None), ReprPlan.Field(name="
|
|
1080
|
+
"'eval_duration', kw_only=True, fn=None), ReprPlan.Field(name='message', kw_only=True, fn=None)), id=False, ter"
|
|
1081
|
+
"se=False, default_fn=OpRef(name='repr.default_fn'))))"
|
|
1082
|
+
),
|
|
1083
|
+
plan_repr_sha1='f14f2c9137552599b1b611852176514b259abb93',
|
|
1084
|
+
op_ref_idents=(
|
|
1085
|
+
'__dataclass__init__fields__0__annotation',
|
|
1086
|
+
'__dataclass__init__fields__0__default',
|
|
1087
|
+
'__dataclass__init__fields__10__annotation',
|
|
1088
|
+
'__dataclass__init__fields__1__annotation',
|
|
1089
|
+
'__dataclass__init__fields__1__default',
|
|
1090
|
+
'__dataclass__init__fields__2__annotation',
|
|
1091
|
+
'__dataclass__init__fields__2__default',
|
|
1092
|
+
'__dataclass__init__fields__3__annotation',
|
|
1093
|
+
'__dataclass__init__fields__3__default',
|
|
1094
|
+
'__dataclass__init__fields__4__annotation',
|
|
1095
|
+
'__dataclass__init__fields__4__default',
|
|
1096
|
+
'__dataclass__init__fields__5__annotation',
|
|
1097
|
+
'__dataclass__init__fields__5__default',
|
|
1098
|
+
'__dataclass__init__fields__6__annotation',
|
|
1099
|
+
'__dataclass__init__fields__6__default',
|
|
1100
|
+
'__dataclass__init__fields__7__annotation',
|
|
1101
|
+
'__dataclass__init__fields__7__default',
|
|
1102
|
+
'__dataclass__init__fields__8__annotation',
|
|
1103
|
+
'__dataclass__init__fields__8__default',
|
|
1104
|
+
'__dataclass__init__fields__9__annotation',
|
|
1105
|
+
'__dataclass__init__fields__9__default',
|
|
1106
|
+
'__dataclass__repr__default_fn',
|
|
1107
|
+
),
|
|
1108
|
+
cls_names=(
|
|
1109
|
+
('ommlds.backends.ollama.protocol', 'ChatResponse'),
|
|
1110
|
+
),
|
|
1111
|
+
)
|
|
1112
|
+
def _process_dataclass__f14f2c9137552599b1b611852176514b259abb93():
|
|
1113
|
+
def _process_dataclass(
|
|
1114
|
+
*,
|
|
1115
|
+
__dataclass__cls,
|
|
1116
|
+
__dataclass__init__fields__0__annotation,
|
|
1117
|
+
__dataclass__init__fields__0__default,
|
|
1118
|
+
__dataclass__init__fields__10__annotation,
|
|
1119
|
+
__dataclass__init__fields__1__annotation,
|
|
1120
|
+
__dataclass__init__fields__1__default,
|
|
1121
|
+
__dataclass__init__fields__2__annotation,
|
|
1122
|
+
__dataclass__init__fields__2__default,
|
|
1123
|
+
__dataclass__init__fields__3__annotation,
|
|
1124
|
+
__dataclass__init__fields__3__default,
|
|
1125
|
+
__dataclass__init__fields__4__annotation,
|
|
1126
|
+
__dataclass__init__fields__4__default,
|
|
1127
|
+
__dataclass__init__fields__5__annotation,
|
|
1128
|
+
__dataclass__init__fields__5__default,
|
|
1129
|
+
__dataclass__init__fields__6__annotation,
|
|
1130
|
+
__dataclass__init__fields__6__default,
|
|
1131
|
+
__dataclass__init__fields__7__annotation,
|
|
1132
|
+
__dataclass__init__fields__7__default,
|
|
1133
|
+
__dataclass__init__fields__8__annotation,
|
|
1134
|
+
__dataclass__init__fields__8__default,
|
|
1135
|
+
__dataclass__init__fields__9__annotation,
|
|
1136
|
+
__dataclass__init__fields__9__default,
|
|
1137
|
+
__dataclass__repr__default_fn,
|
|
1138
|
+
__dataclass__FieldFnValidationError, # noqa
|
|
1139
|
+
__dataclass__FieldTypeValidationError, # noqa
|
|
1140
|
+
__dataclass__FnValidationError, # noqa
|
|
1141
|
+
__dataclass__FrozenInstanceError=dataclasses.FrozenInstanceError, # noqa
|
|
1142
|
+
__dataclass__FunctionType=types.FunctionType, # noqa
|
|
1143
|
+
__dataclass__HAS_DEFAULT_FACTORY=dataclasses._HAS_DEFAULT_FACTORY, # noqa
|
|
1144
|
+
__dataclass__MISSING=dataclasses.MISSING, # noqa
|
|
1145
|
+
__dataclass__None=None, # noqa
|
|
1146
|
+
__dataclass__TypeError=TypeError, # noqa
|
|
1147
|
+
__dataclass___recursive_repr=reprlib.recursive_repr, # noqa
|
|
1148
|
+
__dataclass__isinstance=isinstance, # noqa
|
|
1149
|
+
__dataclass__object_setattr=object.__setattr__, # noqa
|
|
1150
|
+
__dataclass__property=property, # noqa
|
|
1151
|
+
):
|
|
1152
|
+
def __copy__(self):
|
|
1153
|
+
if self.__class__ is not __dataclass__cls:
|
|
1154
|
+
raise TypeError(self)
|
|
1155
|
+
return __dataclass__cls( # noqa
|
|
1156
|
+
model=self.model,
|
|
1157
|
+
created_at=self.created_at,
|
|
1158
|
+
done=self.done,
|
|
1159
|
+
done_reason=self.done_reason,
|
|
1160
|
+
total_duration=self.total_duration,
|
|
1161
|
+
load_duration=self.load_duration,
|
|
1162
|
+
prompt_eval_count=self.prompt_eval_count,
|
|
1163
|
+
prompt_eval_duration=self.prompt_eval_duration,
|
|
1164
|
+
eval_count=self.eval_count,
|
|
1165
|
+
eval_duration=self.eval_duration,
|
|
1166
|
+
message=self.message,
|
|
1167
|
+
)
|
|
1168
|
+
|
|
1169
|
+
__copy__.__qualname__ = f"{__dataclass__cls.__qualname__}.__copy__"
|
|
1170
|
+
if '__copy__' in __dataclass__cls.__dict__:
|
|
1171
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __copy__ in class {__dataclass__cls.__name__}")
|
|
1172
|
+
setattr(__dataclass__cls, '__copy__', __copy__)
|
|
1173
|
+
|
|
1174
|
+
def __eq__(self, other):
|
|
1175
|
+
if self is other:
|
|
1176
|
+
return True
|
|
1177
|
+
if self.__class__ is not other.__class__:
|
|
1178
|
+
return NotImplemented
|
|
1179
|
+
return (
|
|
1180
|
+
self.model == other.model and
|
|
1181
|
+
self.created_at == other.created_at and
|
|
1182
|
+
self.done == other.done and
|
|
1183
|
+
self.done_reason == other.done_reason and
|
|
1184
|
+
self.total_duration == other.total_duration and
|
|
1185
|
+
self.load_duration == other.load_duration and
|
|
1186
|
+
self.prompt_eval_count == other.prompt_eval_count and
|
|
1187
|
+
self.prompt_eval_duration == other.prompt_eval_duration and
|
|
1188
|
+
self.eval_count == other.eval_count and
|
|
1189
|
+
self.eval_duration == other.eval_duration and
|
|
1190
|
+
self.message == other.message
|
|
1191
|
+
)
|
|
1192
|
+
|
|
1193
|
+
__eq__.__qualname__ = f"{__dataclass__cls.__qualname__}.__eq__"
|
|
1194
|
+
if '__eq__' in __dataclass__cls.__dict__:
|
|
1195
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __eq__ in class {__dataclass__cls.__name__}")
|
|
1196
|
+
setattr(__dataclass__cls, '__eq__', __eq__)
|
|
1197
|
+
|
|
1198
|
+
__dataclass___setattr_frozen_fields = {
|
|
1199
|
+
'model',
|
|
1200
|
+
'created_at',
|
|
1201
|
+
'done',
|
|
1202
|
+
'done_reason',
|
|
1203
|
+
'total_duration',
|
|
1204
|
+
'load_duration',
|
|
1205
|
+
'prompt_eval_count',
|
|
1206
|
+
'prompt_eval_duration',
|
|
1207
|
+
'eval_count',
|
|
1208
|
+
'eval_duration',
|
|
1209
|
+
'message',
|
|
1210
|
+
}
|
|
1211
|
+
|
|
1212
|
+
def __setattr__(self, name, value):
|
|
1213
|
+
if (
|
|
1214
|
+
type(self) is __dataclass__cls
|
|
1215
|
+
or name in __dataclass___setattr_frozen_fields
|
|
1216
|
+
):
|
|
1217
|
+
raise __dataclass__FrozenInstanceError(f"cannot assign to field {name!r}")
|
|
1218
|
+
super(__dataclass__cls, self).__setattr__(name, value)
|
|
1219
|
+
|
|
1220
|
+
__setattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__setattr__"
|
|
1221
|
+
if '__setattr__' in __dataclass__cls.__dict__:
|
|
1222
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __setattr__ in class {__dataclass__cls.__name__}")
|
|
1223
|
+
setattr(__dataclass__cls, '__setattr__', __setattr__)
|
|
1224
|
+
|
|
1225
|
+
__dataclass___delattr_frozen_fields = {
|
|
1226
|
+
'model',
|
|
1227
|
+
'created_at',
|
|
1228
|
+
'done',
|
|
1229
|
+
'done_reason',
|
|
1230
|
+
'total_duration',
|
|
1231
|
+
'load_duration',
|
|
1232
|
+
'prompt_eval_count',
|
|
1233
|
+
'prompt_eval_duration',
|
|
1234
|
+
'eval_count',
|
|
1235
|
+
'eval_duration',
|
|
1236
|
+
'message',
|
|
1237
|
+
}
|
|
1238
|
+
|
|
1239
|
+
def __delattr__(self, name):
|
|
1240
|
+
if (
|
|
1241
|
+
type(self) is __dataclass__cls
|
|
1242
|
+
or name in __dataclass___delattr_frozen_fields
|
|
1243
|
+
):
|
|
1244
|
+
raise __dataclass__FrozenInstanceError(f"cannot delete field {name!r}")
|
|
1245
|
+
super(__dataclass__cls, self).__delattr__(name)
|
|
1246
|
+
|
|
1247
|
+
__delattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__delattr__"
|
|
1248
|
+
if '__delattr__' in __dataclass__cls.__dict__:
|
|
1249
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __delattr__ in class {__dataclass__cls.__name__}")
|
|
1250
|
+
setattr(__dataclass__cls, '__delattr__', __delattr__)
|
|
1251
|
+
|
|
1252
|
+
def __hash__(self):
|
|
1253
|
+
return hash((
|
|
1254
|
+
self.model,
|
|
1255
|
+
self.created_at,
|
|
1256
|
+
self.done,
|
|
1257
|
+
self.done_reason,
|
|
1258
|
+
self.total_duration,
|
|
1259
|
+
self.load_duration,
|
|
1260
|
+
self.prompt_eval_count,
|
|
1261
|
+
self.prompt_eval_duration,
|
|
1262
|
+
self.eval_count,
|
|
1263
|
+
self.eval_duration,
|
|
1264
|
+
self.message,
|
|
1265
|
+
))
|
|
1266
|
+
|
|
1267
|
+
__hash__.__qualname__ = f"{__dataclass__cls.__qualname__}.__hash__"
|
|
1268
|
+
setattr(__dataclass__cls, '__hash__', __hash__)
|
|
1269
|
+
|
|
1270
|
+
def __init__(
|
|
1271
|
+
self,
|
|
1272
|
+
*,
|
|
1273
|
+
model: __dataclass__init__fields__0__annotation = __dataclass__init__fields__0__default,
|
|
1274
|
+
created_at: __dataclass__init__fields__1__annotation = __dataclass__init__fields__1__default,
|
|
1275
|
+
done: __dataclass__init__fields__2__annotation = __dataclass__init__fields__2__default,
|
|
1276
|
+
done_reason: __dataclass__init__fields__3__annotation = __dataclass__init__fields__3__default,
|
|
1277
|
+
total_duration: __dataclass__init__fields__4__annotation = __dataclass__init__fields__4__default,
|
|
1278
|
+
load_duration: __dataclass__init__fields__5__annotation = __dataclass__init__fields__5__default,
|
|
1279
|
+
prompt_eval_count: __dataclass__init__fields__6__annotation = __dataclass__init__fields__6__default,
|
|
1280
|
+
prompt_eval_duration: __dataclass__init__fields__7__annotation = __dataclass__init__fields__7__default,
|
|
1281
|
+
eval_count: __dataclass__init__fields__8__annotation = __dataclass__init__fields__8__default,
|
|
1282
|
+
eval_duration: __dataclass__init__fields__9__annotation = __dataclass__init__fields__9__default,
|
|
1283
|
+
message: __dataclass__init__fields__10__annotation,
|
|
1284
|
+
) -> __dataclass__None:
|
|
1285
|
+
__dataclass__object_setattr(self, 'model', model)
|
|
1286
|
+
__dataclass__object_setattr(self, 'created_at', created_at)
|
|
1287
|
+
__dataclass__object_setattr(self, 'done', done)
|
|
1288
|
+
__dataclass__object_setattr(self, 'done_reason', done_reason)
|
|
1289
|
+
__dataclass__object_setattr(self, 'total_duration', total_duration)
|
|
1290
|
+
__dataclass__object_setattr(self, 'load_duration', load_duration)
|
|
1291
|
+
__dataclass__object_setattr(self, 'prompt_eval_count', prompt_eval_count)
|
|
1292
|
+
__dataclass__object_setattr(self, 'prompt_eval_duration', prompt_eval_duration)
|
|
1293
|
+
__dataclass__object_setattr(self, 'eval_count', eval_count)
|
|
1294
|
+
__dataclass__object_setattr(self, 'eval_duration', eval_duration)
|
|
1295
|
+
__dataclass__object_setattr(self, 'message', message)
|
|
1296
|
+
|
|
1297
|
+
__init__.__qualname__ = f"{__dataclass__cls.__qualname__}.__init__"
|
|
1298
|
+
if '__init__' in __dataclass__cls.__dict__:
|
|
1299
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __init__ in class {__dataclass__cls.__name__}")
|
|
1300
|
+
setattr(__dataclass__cls, '__init__', __init__)
|
|
1301
|
+
|
|
1302
|
+
@__dataclass___recursive_repr()
|
|
1303
|
+
def __repr__(self):
|
|
1304
|
+
parts = []
|
|
1305
|
+
if (s := __dataclass__repr__default_fn(self.model)) is not None:
|
|
1306
|
+
parts.append(f"model={s}")
|
|
1307
|
+
if (s := __dataclass__repr__default_fn(self.created_at)) is not None:
|
|
1308
|
+
parts.append(f"created_at={s}")
|
|
1309
|
+
if (s := __dataclass__repr__default_fn(self.done)) is not None:
|
|
1310
|
+
parts.append(f"done={s}")
|
|
1311
|
+
if (s := __dataclass__repr__default_fn(self.done_reason)) is not None:
|
|
1312
|
+
parts.append(f"done_reason={s}")
|
|
1313
|
+
if (s := __dataclass__repr__default_fn(self.total_duration)) is not None:
|
|
1314
|
+
parts.append(f"total_duration={s}")
|
|
1315
|
+
if (s := __dataclass__repr__default_fn(self.load_duration)) is not None:
|
|
1316
|
+
parts.append(f"load_duration={s}")
|
|
1317
|
+
if (s := __dataclass__repr__default_fn(self.prompt_eval_count)) is not None:
|
|
1318
|
+
parts.append(f"prompt_eval_count={s}")
|
|
1319
|
+
if (s := __dataclass__repr__default_fn(self.prompt_eval_duration)) is not None:
|
|
1320
|
+
parts.append(f"prompt_eval_duration={s}")
|
|
1321
|
+
if (s := __dataclass__repr__default_fn(self.eval_count)) is not None:
|
|
1322
|
+
parts.append(f"eval_count={s}")
|
|
1323
|
+
if (s := __dataclass__repr__default_fn(self.eval_duration)) is not None:
|
|
1324
|
+
parts.append(f"eval_duration={s}")
|
|
1325
|
+
if (s := __dataclass__repr__default_fn(self.message)) is not None:
|
|
1326
|
+
parts.append(f"message={s}")
|
|
1327
|
+
return (
|
|
1328
|
+
f"{self.__class__.__qualname__}("
|
|
1329
|
+
f"{', '.join(parts)}"
|
|
1330
|
+
f")"
|
|
1331
|
+
)
|
|
1332
|
+
|
|
1333
|
+
__repr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__repr__"
|
|
1334
|
+
if '__repr__' in __dataclass__cls.__dict__:
|
|
1335
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __repr__ in class {__dataclass__cls.__name__}")
|
|
1336
|
+
setattr(__dataclass__cls, '__repr__', __repr__)
|
|
1337
|
+
|
|
1338
|
+
return _process_dataclass
|
|
1339
|
+
|
|
1340
|
+
|
|
1341
|
+
@_register(
|
|
1342
|
+
plan_repr=(
|
|
1343
|
+
"Plans(tup=(CopyPlan(fields=('model', 'stream', 'options', 'format', 'keep_alive', 'prompt', 'suffix', 'system'"
|
|
1344
|
+
", 'template', 'context', 'raw', 'images', 'think')), EqPlan(fields=('model', 'stream', 'options', 'format', 'k"
|
|
1345
|
+
"eep_alive', 'prompt', 'suffix', 'system', 'template', 'context', 'raw', 'images', 'think')), FrozenPlan(fields"
|
|
1346
|
+
"=('model', 'stream', 'options', 'format', 'keep_alive', 'prompt', 'suffix', 'system', 'template', 'context', '"
|
|
1347
|
+
"raw', 'images', 'think'), allow_dynamic_dunder_attrs=False), HashPlan(action='add', fields=('model', 'stream',"
|
|
1348
|
+
" 'options', 'format', 'keep_alive', 'prompt', 'suffix', 'system', 'template', 'context', 'raw', 'images', 'thi"
|
|
1349
|
+
"nk'), cache=False), InitPlan(fields=(InitPlan.Field(name='model', annotation=OpRef(name='init.fields.0.annotat"
|
|
1350
|
+
"ion'), default=None, default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=No"
|
|
1351
|
+
"ne, validate=None, check_type=None), InitPlan.Field(name='stream', annotation=OpRef(name='init.fields.1.annota"
|
|
1352
|
+
"tion'), default=OpRef(name='init.fields.1.default'), default_factory=None, init=True, override=False, field_ty"
|
|
1353
|
+
"pe=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='options', annotation"
|
|
1354
|
+
"=OpRef(name='init.fields.2.annotation'), default=OpRef(name='init.fields.2.default'), default_factory=None, in"
|
|
1355
|
+
"it=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan"
|
|
1356
|
+
".Field(name='format', annotation=OpRef(name='init.fields.3.annotation'), default=OpRef(name='init.fields.3.def"
|
|
1357
|
+
"ault'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate="
|
|
1358
|
+
"None, check_type=None), InitPlan.Field(name='keep_alive', annotation=OpRef(name='init.fields.4.annotation'), d"
|
|
1359
|
+
"efault=OpRef(name='init.fields.4.default'), default_factory=None, init=True, override=False, field_type=FieldT"
|
|
1360
|
+
"ype.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='prompt', annotation=OpRef(nam"
|
|
1361
|
+
"e='init.fields.5.annotation'), default=OpRef(name='init.fields.5.default'), default_factory=None, init=True, o"
|
|
1362
|
+
"verride=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(nam"
|
|
1363
|
+
"e='suffix', annotation=OpRef(name='init.fields.6.annotation'), default=OpRef(name='init.fields.6.default'), de"
|
|
1364
|
+
"fault_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, chec"
|
|
1365
|
+
"k_type=None), InitPlan.Field(name='system', annotation=OpRef(name='init.fields.7.annotation'), default=OpRef(n"
|
|
1366
|
+
"ame='init.fields.7.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, "
|
|
1367
|
+
"coerce=None, validate=None, check_type=None), InitPlan.Field(name='template', annotation=OpRef(name='init.fiel"
|
|
1368
|
+
"ds.8.annotation'), default=OpRef(name='init.fields.8.default'), default_factory=None, init=True, override=Fals"
|
|
1369
|
+
"e, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='context',"
|
|
1370
|
+
" annotation=OpRef(name='init.fields.9.annotation'), default=OpRef(name='init.fields.9.default'), default_facto"
|
|
1371
|
+
"ry=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None"
|
|
1372
|
+
"), InitPlan.Field(name='raw', annotation=OpRef(name='init.fields.10.annotation'), default=OpRef(name='init.fie"
|
|
1373
|
+
"lds.10.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None,"
|
|
1374
|
+
" validate=None, check_type=None), InitPlan.Field(name='images', annotation=OpRef(name='init.fields.11.annotati"
|
|
1375
|
+
"on'), default=OpRef(name='init.fields.11.default'), default_factory=None, init=True, override=False, field_typ"
|
|
1376
|
+
"e=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='think', annotation=Op"
|
|
1377
|
+
"Ref(name='init.fields.12.annotation'), default=OpRef(name='init.fields.12.default'), default_factory=None, ini"
|
|
1378
|
+
"t=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None)), self_par"
|
|
1379
|
+
"am='self', std_params=(), kw_only_params=('model', 'stream', 'options', 'format', 'keep_alive', 'prompt', 'suf"
|
|
1380
|
+
"fix', 'system', 'template', 'context', 'raw', 'images', 'think'), frozen=True, slots=False, post_init_params=N"
|
|
1381
|
+
"one, init_fns=(), validate_fns=()), ReprPlan(fields=(ReprPlan.Field(name='model', kw_only=True, fn=None), Repr"
|
|
1382
|
+
"Plan.Field(name='stream', kw_only=True, fn=None), ReprPlan.Field(name='options', kw_only=True, fn=None), ReprP"
|
|
1383
|
+
"lan.Field(name='format', kw_only=True, fn=None), ReprPlan.Field(name='keep_alive', kw_only=True, fn=None), Rep"
|
|
1384
|
+
"rPlan.Field(name='prompt', kw_only=True, fn=None), ReprPlan.Field(name='suffix', kw_only=True, fn=None), ReprP"
|
|
1385
|
+
"lan.Field(name='system', kw_only=True, fn=None), ReprPlan.Field(name='template', kw_only=True, fn=None), ReprP"
|
|
1386
|
+
"lan.Field(name='context', kw_only=True, fn=None), ReprPlan.Field(name='raw', kw_only=True, fn=None), ReprPlan."
|
|
1387
|
+
"Field(name='images', kw_only=True, fn=None), ReprPlan.Field(name='think', kw_only=True, fn=None)), id=False, t"
|
|
1388
|
+
"erse=False, default_fn=OpRef(name='repr.default_fn'))))"
|
|
1389
|
+
),
|
|
1390
|
+
plan_repr_sha1='e8b909b51aff3e1fd8203ee672cfc0bab5067233',
|
|
1391
|
+
op_ref_idents=(
|
|
1392
|
+
'__dataclass__init__fields__0__annotation',
|
|
1393
|
+
'__dataclass__init__fields__10__annotation',
|
|
1394
|
+
'__dataclass__init__fields__10__default',
|
|
1395
|
+
'__dataclass__init__fields__11__annotation',
|
|
1396
|
+
'__dataclass__init__fields__11__default',
|
|
1397
|
+
'__dataclass__init__fields__12__annotation',
|
|
1398
|
+
'__dataclass__init__fields__12__default',
|
|
1399
|
+
'__dataclass__init__fields__1__annotation',
|
|
1400
|
+
'__dataclass__init__fields__1__default',
|
|
1401
|
+
'__dataclass__init__fields__2__annotation',
|
|
1402
|
+
'__dataclass__init__fields__2__default',
|
|
1403
|
+
'__dataclass__init__fields__3__annotation',
|
|
1404
|
+
'__dataclass__init__fields__3__default',
|
|
1405
|
+
'__dataclass__init__fields__4__annotation',
|
|
1406
|
+
'__dataclass__init__fields__4__default',
|
|
1407
|
+
'__dataclass__init__fields__5__annotation',
|
|
1408
|
+
'__dataclass__init__fields__5__default',
|
|
1409
|
+
'__dataclass__init__fields__6__annotation',
|
|
1410
|
+
'__dataclass__init__fields__6__default',
|
|
1411
|
+
'__dataclass__init__fields__7__annotation',
|
|
1412
|
+
'__dataclass__init__fields__7__default',
|
|
1413
|
+
'__dataclass__init__fields__8__annotation',
|
|
1414
|
+
'__dataclass__init__fields__8__default',
|
|
1415
|
+
'__dataclass__init__fields__9__annotation',
|
|
1416
|
+
'__dataclass__init__fields__9__default',
|
|
1417
|
+
'__dataclass__repr__default_fn',
|
|
1418
|
+
),
|
|
1419
|
+
cls_names=(
|
|
1420
|
+
('ommlds.backends.ollama.protocol', 'GenerateRequest'),
|
|
1421
|
+
),
|
|
1422
|
+
)
|
|
1423
|
+
def _process_dataclass__e8b909b51aff3e1fd8203ee672cfc0bab5067233():
|
|
1424
|
+
def _process_dataclass(
|
|
1425
|
+
*,
|
|
1426
|
+
__dataclass__cls,
|
|
1427
|
+
__dataclass__init__fields__0__annotation,
|
|
1428
|
+
__dataclass__init__fields__10__annotation,
|
|
1429
|
+
__dataclass__init__fields__10__default,
|
|
1430
|
+
__dataclass__init__fields__11__annotation,
|
|
1431
|
+
__dataclass__init__fields__11__default,
|
|
1432
|
+
__dataclass__init__fields__12__annotation,
|
|
1433
|
+
__dataclass__init__fields__12__default,
|
|
1434
|
+
__dataclass__init__fields__1__annotation,
|
|
1435
|
+
__dataclass__init__fields__1__default,
|
|
1436
|
+
__dataclass__init__fields__2__annotation,
|
|
1437
|
+
__dataclass__init__fields__2__default,
|
|
1438
|
+
__dataclass__init__fields__3__annotation,
|
|
1439
|
+
__dataclass__init__fields__3__default,
|
|
1440
|
+
__dataclass__init__fields__4__annotation,
|
|
1441
|
+
__dataclass__init__fields__4__default,
|
|
1442
|
+
__dataclass__init__fields__5__annotation,
|
|
1443
|
+
__dataclass__init__fields__5__default,
|
|
1444
|
+
__dataclass__init__fields__6__annotation,
|
|
1445
|
+
__dataclass__init__fields__6__default,
|
|
1446
|
+
__dataclass__init__fields__7__annotation,
|
|
1447
|
+
__dataclass__init__fields__7__default,
|
|
1448
|
+
__dataclass__init__fields__8__annotation,
|
|
1449
|
+
__dataclass__init__fields__8__default,
|
|
1450
|
+
__dataclass__init__fields__9__annotation,
|
|
1451
|
+
__dataclass__init__fields__9__default,
|
|
1452
|
+
__dataclass__repr__default_fn,
|
|
1453
|
+
__dataclass__FieldFnValidationError, # noqa
|
|
1454
|
+
__dataclass__FieldTypeValidationError, # noqa
|
|
1455
|
+
__dataclass__FnValidationError, # noqa
|
|
1456
|
+
__dataclass__FrozenInstanceError=dataclasses.FrozenInstanceError, # noqa
|
|
1457
|
+
__dataclass__FunctionType=types.FunctionType, # noqa
|
|
1458
|
+
__dataclass__HAS_DEFAULT_FACTORY=dataclasses._HAS_DEFAULT_FACTORY, # noqa
|
|
1459
|
+
__dataclass__MISSING=dataclasses.MISSING, # noqa
|
|
1460
|
+
__dataclass__None=None, # noqa
|
|
1461
|
+
__dataclass__TypeError=TypeError, # noqa
|
|
1462
|
+
__dataclass___recursive_repr=reprlib.recursive_repr, # noqa
|
|
1463
|
+
__dataclass__isinstance=isinstance, # noqa
|
|
1464
|
+
__dataclass__object_setattr=object.__setattr__, # noqa
|
|
1465
|
+
__dataclass__property=property, # noqa
|
|
1466
|
+
):
|
|
1467
|
+
def __copy__(self):
|
|
1468
|
+
if self.__class__ is not __dataclass__cls:
|
|
1469
|
+
raise TypeError(self)
|
|
1470
|
+
return __dataclass__cls( # noqa
|
|
1471
|
+
model=self.model,
|
|
1472
|
+
stream=self.stream,
|
|
1473
|
+
options=self.options,
|
|
1474
|
+
format=self.format,
|
|
1475
|
+
keep_alive=self.keep_alive,
|
|
1476
|
+
prompt=self.prompt,
|
|
1477
|
+
suffix=self.suffix,
|
|
1478
|
+
system=self.system,
|
|
1479
|
+
template=self.template,
|
|
1480
|
+
context=self.context,
|
|
1481
|
+
raw=self.raw,
|
|
1482
|
+
images=self.images,
|
|
1483
|
+
think=self.think,
|
|
1484
|
+
)
|
|
1485
|
+
|
|
1486
|
+
__copy__.__qualname__ = f"{__dataclass__cls.__qualname__}.__copy__"
|
|
1487
|
+
if '__copy__' in __dataclass__cls.__dict__:
|
|
1488
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __copy__ in class {__dataclass__cls.__name__}")
|
|
1489
|
+
setattr(__dataclass__cls, '__copy__', __copy__)
|
|
1490
|
+
|
|
1491
|
+
def __eq__(self, other):
|
|
1492
|
+
if self is other:
|
|
1493
|
+
return True
|
|
1494
|
+
if self.__class__ is not other.__class__:
|
|
1495
|
+
return NotImplemented
|
|
1496
|
+
return (
|
|
1497
|
+
self.model == other.model and
|
|
1498
|
+
self.stream == other.stream and
|
|
1499
|
+
self.options == other.options and
|
|
1500
|
+
self.format == other.format and
|
|
1501
|
+
self.keep_alive == other.keep_alive and
|
|
1502
|
+
self.prompt == other.prompt and
|
|
1503
|
+
self.suffix == other.suffix and
|
|
1504
|
+
self.system == other.system and
|
|
1505
|
+
self.template == other.template and
|
|
1506
|
+
self.context == other.context and
|
|
1507
|
+
self.raw == other.raw and
|
|
1508
|
+
self.images == other.images and
|
|
1509
|
+
self.think == other.think
|
|
1510
|
+
)
|
|
1511
|
+
|
|
1512
|
+
__eq__.__qualname__ = f"{__dataclass__cls.__qualname__}.__eq__"
|
|
1513
|
+
if '__eq__' in __dataclass__cls.__dict__:
|
|
1514
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __eq__ in class {__dataclass__cls.__name__}")
|
|
1515
|
+
setattr(__dataclass__cls, '__eq__', __eq__)
|
|
1516
|
+
|
|
1517
|
+
__dataclass___setattr_frozen_fields = {
|
|
1518
|
+
'model',
|
|
1519
|
+
'stream',
|
|
1520
|
+
'options',
|
|
1521
|
+
'format',
|
|
1522
|
+
'keep_alive',
|
|
1523
|
+
'prompt',
|
|
1524
|
+
'suffix',
|
|
1525
|
+
'system',
|
|
1526
|
+
'template',
|
|
1527
|
+
'context',
|
|
1528
|
+
'raw',
|
|
1529
|
+
'images',
|
|
1530
|
+
'think',
|
|
1531
|
+
}
|
|
1532
|
+
|
|
1533
|
+
def __setattr__(self, name, value):
|
|
1534
|
+
if (
|
|
1535
|
+
type(self) is __dataclass__cls
|
|
1536
|
+
or name in __dataclass___setattr_frozen_fields
|
|
1537
|
+
):
|
|
1538
|
+
raise __dataclass__FrozenInstanceError(f"cannot assign to field {name!r}")
|
|
1539
|
+
super(__dataclass__cls, self).__setattr__(name, value)
|
|
1540
|
+
|
|
1541
|
+
__setattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__setattr__"
|
|
1542
|
+
if '__setattr__' in __dataclass__cls.__dict__:
|
|
1543
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __setattr__ in class {__dataclass__cls.__name__}")
|
|
1544
|
+
setattr(__dataclass__cls, '__setattr__', __setattr__)
|
|
1545
|
+
|
|
1546
|
+
__dataclass___delattr_frozen_fields = {
|
|
1547
|
+
'model',
|
|
1548
|
+
'stream',
|
|
1549
|
+
'options',
|
|
1550
|
+
'format',
|
|
1551
|
+
'keep_alive',
|
|
1552
|
+
'prompt',
|
|
1553
|
+
'suffix',
|
|
1554
|
+
'system',
|
|
1555
|
+
'template',
|
|
1556
|
+
'context',
|
|
1557
|
+
'raw',
|
|
1558
|
+
'images',
|
|
1559
|
+
'think',
|
|
1560
|
+
}
|
|
1561
|
+
|
|
1562
|
+
def __delattr__(self, name):
|
|
1563
|
+
if (
|
|
1564
|
+
type(self) is __dataclass__cls
|
|
1565
|
+
or name in __dataclass___delattr_frozen_fields
|
|
1566
|
+
):
|
|
1567
|
+
raise __dataclass__FrozenInstanceError(f"cannot delete field {name!r}")
|
|
1568
|
+
super(__dataclass__cls, self).__delattr__(name)
|
|
1569
|
+
|
|
1570
|
+
__delattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__delattr__"
|
|
1571
|
+
if '__delattr__' in __dataclass__cls.__dict__:
|
|
1572
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __delattr__ in class {__dataclass__cls.__name__}")
|
|
1573
|
+
setattr(__dataclass__cls, '__delattr__', __delattr__)
|
|
1574
|
+
|
|
1575
|
+
def __hash__(self):
|
|
1576
|
+
return hash((
|
|
1577
|
+
self.model,
|
|
1578
|
+
self.stream,
|
|
1579
|
+
self.options,
|
|
1580
|
+
self.format,
|
|
1581
|
+
self.keep_alive,
|
|
1582
|
+
self.prompt,
|
|
1583
|
+
self.suffix,
|
|
1584
|
+
self.system,
|
|
1585
|
+
self.template,
|
|
1586
|
+
self.context,
|
|
1587
|
+
self.raw,
|
|
1588
|
+
self.images,
|
|
1589
|
+
self.think,
|
|
1590
|
+
))
|
|
1591
|
+
|
|
1592
|
+
__hash__.__qualname__ = f"{__dataclass__cls.__qualname__}.__hash__"
|
|
1593
|
+
setattr(__dataclass__cls, '__hash__', __hash__)
|
|
1594
|
+
|
|
1595
|
+
def __init__(
|
|
1596
|
+
self,
|
|
1597
|
+
*,
|
|
1598
|
+
model: __dataclass__init__fields__0__annotation,
|
|
1599
|
+
stream: __dataclass__init__fields__1__annotation = __dataclass__init__fields__1__default,
|
|
1600
|
+
options: __dataclass__init__fields__2__annotation = __dataclass__init__fields__2__default,
|
|
1601
|
+
format: __dataclass__init__fields__3__annotation = __dataclass__init__fields__3__default,
|
|
1602
|
+
keep_alive: __dataclass__init__fields__4__annotation = __dataclass__init__fields__4__default,
|
|
1603
|
+
prompt: __dataclass__init__fields__5__annotation = __dataclass__init__fields__5__default,
|
|
1604
|
+
suffix: __dataclass__init__fields__6__annotation = __dataclass__init__fields__6__default,
|
|
1605
|
+
system: __dataclass__init__fields__7__annotation = __dataclass__init__fields__7__default,
|
|
1606
|
+
template: __dataclass__init__fields__8__annotation = __dataclass__init__fields__8__default,
|
|
1607
|
+
context: __dataclass__init__fields__9__annotation = __dataclass__init__fields__9__default,
|
|
1608
|
+
raw: __dataclass__init__fields__10__annotation = __dataclass__init__fields__10__default,
|
|
1609
|
+
images: __dataclass__init__fields__11__annotation = __dataclass__init__fields__11__default,
|
|
1610
|
+
think: __dataclass__init__fields__12__annotation = __dataclass__init__fields__12__default,
|
|
1611
|
+
) -> __dataclass__None:
|
|
1612
|
+
__dataclass__object_setattr(self, 'model', model)
|
|
1613
|
+
__dataclass__object_setattr(self, 'stream', stream)
|
|
1614
|
+
__dataclass__object_setattr(self, 'options', options)
|
|
1615
|
+
__dataclass__object_setattr(self, 'format', format)
|
|
1616
|
+
__dataclass__object_setattr(self, 'keep_alive', keep_alive)
|
|
1617
|
+
__dataclass__object_setattr(self, 'prompt', prompt)
|
|
1618
|
+
__dataclass__object_setattr(self, 'suffix', suffix)
|
|
1619
|
+
__dataclass__object_setattr(self, 'system', system)
|
|
1620
|
+
__dataclass__object_setattr(self, 'template', template)
|
|
1621
|
+
__dataclass__object_setattr(self, 'context', context)
|
|
1622
|
+
__dataclass__object_setattr(self, 'raw', raw)
|
|
1623
|
+
__dataclass__object_setattr(self, 'images', images)
|
|
1624
|
+
__dataclass__object_setattr(self, 'think', think)
|
|
1625
|
+
|
|
1626
|
+
__init__.__qualname__ = f"{__dataclass__cls.__qualname__}.__init__"
|
|
1627
|
+
if '__init__' in __dataclass__cls.__dict__:
|
|
1628
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __init__ in class {__dataclass__cls.__name__}")
|
|
1629
|
+
setattr(__dataclass__cls, '__init__', __init__)
|
|
1630
|
+
|
|
1631
|
+
@__dataclass___recursive_repr()
|
|
1632
|
+
def __repr__(self):
|
|
1633
|
+
parts = []
|
|
1634
|
+
if (s := __dataclass__repr__default_fn(self.model)) is not None:
|
|
1635
|
+
parts.append(f"model={s}")
|
|
1636
|
+
if (s := __dataclass__repr__default_fn(self.stream)) is not None:
|
|
1637
|
+
parts.append(f"stream={s}")
|
|
1638
|
+
if (s := __dataclass__repr__default_fn(self.options)) is not None:
|
|
1639
|
+
parts.append(f"options={s}")
|
|
1640
|
+
if (s := __dataclass__repr__default_fn(self.format)) is not None:
|
|
1641
|
+
parts.append(f"format={s}")
|
|
1642
|
+
if (s := __dataclass__repr__default_fn(self.keep_alive)) is not None:
|
|
1643
|
+
parts.append(f"keep_alive={s}")
|
|
1644
|
+
if (s := __dataclass__repr__default_fn(self.prompt)) is not None:
|
|
1645
|
+
parts.append(f"prompt={s}")
|
|
1646
|
+
if (s := __dataclass__repr__default_fn(self.suffix)) is not None:
|
|
1647
|
+
parts.append(f"suffix={s}")
|
|
1648
|
+
if (s := __dataclass__repr__default_fn(self.system)) is not None:
|
|
1649
|
+
parts.append(f"system={s}")
|
|
1650
|
+
if (s := __dataclass__repr__default_fn(self.template)) is not None:
|
|
1651
|
+
parts.append(f"template={s}")
|
|
1652
|
+
if (s := __dataclass__repr__default_fn(self.context)) is not None:
|
|
1653
|
+
parts.append(f"context={s}")
|
|
1654
|
+
if (s := __dataclass__repr__default_fn(self.raw)) is not None:
|
|
1655
|
+
parts.append(f"raw={s}")
|
|
1656
|
+
if (s := __dataclass__repr__default_fn(self.images)) is not None:
|
|
1657
|
+
parts.append(f"images={s}")
|
|
1658
|
+
if (s := __dataclass__repr__default_fn(self.think)) is not None:
|
|
1659
|
+
parts.append(f"think={s}")
|
|
1660
|
+
return (
|
|
1661
|
+
f"{self.__class__.__qualname__}("
|
|
1662
|
+
f"{', '.join(parts)}"
|
|
1663
|
+
f")"
|
|
1664
|
+
)
|
|
1665
|
+
|
|
1666
|
+
__repr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__repr__"
|
|
1667
|
+
if '__repr__' in __dataclass__cls.__dict__:
|
|
1668
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __repr__ in class {__dataclass__cls.__name__}")
|
|
1669
|
+
setattr(__dataclass__cls, '__repr__', __repr__)
|
|
1670
|
+
|
|
1671
|
+
return _process_dataclass
|
|
1672
|
+
|
|
1673
|
+
|
|
1674
|
+
@_register(
|
|
1675
|
+
plan_repr=(
|
|
1676
|
+
"Plans(tup=(CopyPlan(fields=('model', 'created_at', 'done', 'done_reason', 'total_duration', 'load_duration', '"
|
|
1677
|
+
"prompt_eval_count', 'prompt_eval_duration', 'eval_count', 'eval_duration', 'response', 'thinking', 'context'))"
|
|
1678
|
+
", EqPlan(fields=('model', 'created_at', 'done', 'done_reason', 'total_duration', 'load_duration', 'prompt_eval"
|
|
1679
|
+
"_count', 'prompt_eval_duration', 'eval_count', 'eval_duration', 'response', 'thinking', 'context')), FrozenPla"
|
|
1680
|
+
"n(fields=('model', 'created_at', 'done', 'done_reason', 'total_duration', 'load_duration', 'prompt_eval_count'"
|
|
1681
|
+
", 'prompt_eval_duration', 'eval_count', 'eval_duration', 'response', 'thinking', 'context'), allow_dynamic_dun"
|
|
1682
|
+
"der_attrs=False), HashPlan(action='add', fields=('model', 'created_at', 'done', 'done_reason', 'total_duration"
|
|
1683
|
+
"', 'load_duration', 'prompt_eval_count', 'prompt_eval_duration', 'eval_count', 'eval_duration', 'response', 't"
|
|
1684
|
+
"hinking', 'context'), cache=False), InitPlan(fields=(InitPlan.Field(name='model', annotation=OpRef(name='init."
|
|
1685
|
+
"fields.0.annotation'), default=OpRef(name='init.fields.0.default'), default_factory=None, init=True, override="
|
|
1686
|
+
"False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='creat"
|
|
1687
|
+
"ed_at', annotation=OpRef(name='init.fields.1.annotation'), default=OpRef(name='init.fields.1.default'), defaul"
|
|
1688
|
+
"t_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_ty"
|
|
1689
|
+
"pe=None), InitPlan.Field(name='done', annotation=OpRef(name='init.fields.2.annotation'), default=OpRef(name='i"
|
|
1690
|
+
"nit.fields.2.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce"
|
|
1691
|
+
"=None, validate=None, check_type=None), InitPlan.Field(name='done_reason', annotation=OpRef(name='init.fields."
|
|
1692
|
+
"3.annotation'), default=OpRef(name='init.fields.3.default'), default_factory=None, init=True, override=False, "
|
|
1693
|
+
"field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='total_durati"
|
|
1694
|
+
"on', annotation=OpRef(name='init.fields.4.annotation'), default=OpRef(name='init.fields.4.default'), default_f"
|
|
1695
|
+
"actory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type="
|
|
1696
|
+
"None), InitPlan.Field(name='load_duration', annotation=OpRef(name='init.fields.5.annotation'), default=OpRef(n"
|
|
1697
|
+
"ame='init.fields.5.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, "
|
|
1698
|
+
"coerce=None, validate=None, check_type=None), InitPlan.Field(name='prompt_eval_count', annotation=OpRef(name='"
|
|
1699
|
+
"init.fields.6.annotation'), default=OpRef(name='init.fields.6.default'), default_factory=None, init=True, over"
|
|
1700
|
+
"ride=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='"
|
|
1701
|
+
"prompt_eval_duration', annotation=OpRef(name='init.fields.7.annotation'), default=OpRef(name='init.fields.7.de"
|
|
1702
|
+
"fault'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate"
|
|
1703
|
+
"=None, check_type=None), InitPlan.Field(name='eval_count', annotation=OpRef(name='init.fields.8.annotation'), "
|
|
1704
|
+
"default=OpRef(name='init.fields.8.default'), default_factory=None, init=True, override=False, field_type=Field"
|
|
1705
|
+
"Type.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='eval_duration', annotation=O"
|
|
1706
|
+
"pRef(name='init.fields.9.annotation'), default=OpRef(name='init.fields.9.default'), default_factory=None, init"
|
|
1707
|
+
"=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.F"
|
|
1708
|
+
"ield(name='response', annotation=OpRef(name='init.fields.10.annotation'), default=None, default_factory=None, "
|
|
1709
|
+
"init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPl"
|
|
1710
|
+
"an.Field(name='thinking', annotation=OpRef(name='init.fields.11.annotation'), default=OpRef(name='init.fields."
|
|
1711
|
+
"11.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, val"
|
|
1712
|
+
"idate=None, check_type=None), InitPlan.Field(name='context', annotation=OpRef(name='init.fields.12.annotation'"
|
|
1713
|
+
"), default=OpRef(name='init.fields.12.default'), default_factory=None, init=True, override=False, field_type=F"
|
|
1714
|
+
"ieldType.INSTANCE, coerce=None, validate=None, check_type=None)), self_param='self', std_params=(), kw_only_pa"
|
|
1715
|
+
"rams=('model', 'created_at', 'done', 'done_reason', 'total_duration', 'load_duration', 'prompt_eval_count', 'p"
|
|
1716
|
+
"rompt_eval_duration', 'eval_count', 'eval_duration', 'response', 'thinking', 'context'), frozen=True, slots=Fa"
|
|
1717
|
+
"lse, post_init_params=None, init_fns=(), validate_fns=()), ReprPlan(fields=(ReprPlan.Field(name='model', kw_on"
|
|
1718
|
+
"ly=True, fn=None), ReprPlan.Field(name='created_at', kw_only=True, fn=None), ReprPlan.Field(name='done', kw_on"
|
|
1719
|
+
"ly=True, fn=None), ReprPlan.Field(name='done_reason', kw_only=True, fn=None), ReprPlan.Field(name='total_durat"
|
|
1720
|
+
"ion', kw_only=True, fn=None), ReprPlan.Field(name='load_duration', kw_only=True, fn=None), ReprPlan.Field(name"
|
|
1721
|
+
"='prompt_eval_count', kw_only=True, fn=None), ReprPlan.Field(name='prompt_eval_duration', kw_only=True, fn=Non"
|
|
1722
|
+
"e), ReprPlan.Field(name='eval_count', kw_only=True, fn=None), ReprPlan.Field(name='eval_duration', kw_only=Tru"
|
|
1723
|
+
"e, fn=None), ReprPlan.Field(name='response', kw_only=True, fn=None), ReprPlan.Field(name='thinking', kw_only=T"
|
|
1724
|
+
"rue, fn=None), ReprPlan.Field(name='context', kw_only=True, fn=None)), id=False, terse=False, default_fn=OpRef"
|
|
1725
|
+
"(name='repr.default_fn'))))"
|
|
1726
|
+
),
|
|
1727
|
+
plan_repr_sha1='d4de027591ccf1da84a98a2734b94a36c6340c4b',
|
|
1728
|
+
op_ref_idents=(
|
|
1729
|
+
'__dataclass__init__fields__0__annotation',
|
|
1730
|
+
'__dataclass__init__fields__0__default',
|
|
1731
|
+
'__dataclass__init__fields__10__annotation',
|
|
1732
|
+
'__dataclass__init__fields__11__annotation',
|
|
1733
|
+
'__dataclass__init__fields__11__default',
|
|
1734
|
+
'__dataclass__init__fields__12__annotation',
|
|
1735
|
+
'__dataclass__init__fields__12__default',
|
|
1736
|
+
'__dataclass__init__fields__1__annotation',
|
|
1737
|
+
'__dataclass__init__fields__1__default',
|
|
1738
|
+
'__dataclass__init__fields__2__annotation',
|
|
1739
|
+
'__dataclass__init__fields__2__default',
|
|
1740
|
+
'__dataclass__init__fields__3__annotation',
|
|
1741
|
+
'__dataclass__init__fields__3__default',
|
|
1742
|
+
'__dataclass__init__fields__4__annotation',
|
|
1743
|
+
'__dataclass__init__fields__4__default',
|
|
1744
|
+
'__dataclass__init__fields__5__annotation',
|
|
1745
|
+
'__dataclass__init__fields__5__default',
|
|
1746
|
+
'__dataclass__init__fields__6__annotation',
|
|
1747
|
+
'__dataclass__init__fields__6__default',
|
|
1748
|
+
'__dataclass__init__fields__7__annotation',
|
|
1749
|
+
'__dataclass__init__fields__7__default',
|
|
1750
|
+
'__dataclass__init__fields__8__annotation',
|
|
1751
|
+
'__dataclass__init__fields__8__default',
|
|
1752
|
+
'__dataclass__init__fields__9__annotation',
|
|
1753
|
+
'__dataclass__init__fields__9__default',
|
|
1754
|
+
'__dataclass__repr__default_fn',
|
|
1755
|
+
),
|
|
1756
|
+
cls_names=(
|
|
1757
|
+
('ommlds.backends.ollama.protocol', 'GenerateResponse'),
|
|
1758
|
+
),
|
|
1759
|
+
)
|
|
1760
|
+
def _process_dataclass__d4de027591ccf1da84a98a2734b94a36c6340c4b():
|
|
1761
|
+
def _process_dataclass(
|
|
1762
|
+
*,
|
|
1763
|
+
__dataclass__cls,
|
|
1764
|
+
__dataclass__init__fields__0__annotation,
|
|
1765
|
+
__dataclass__init__fields__0__default,
|
|
1766
|
+
__dataclass__init__fields__10__annotation,
|
|
1767
|
+
__dataclass__init__fields__11__annotation,
|
|
1768
|
+
__dataclass__init__fields__11__default,
|
|
1769
|
+
__dataclass__init__fields__12__annotation,
|
|
1770
|
+
__dataclass__init__fields__12__default,
|
|
1771
|
+
__dataclass__init__fields__1__annotation,
|
|
1772
|
+
__dataclass__init__fields__1__default,
|
|
1773
|
+
__dataclass__init__fields__2__annotation,
|
|
1774
|
+
__dataclass__init__fields__2__default,
|
|
1775
|
+
__dataclass__init__fields__3__annotation,
|
|
1776
|
+
__dataclass__init__fields__3__default,
|
|
1777
|
+
__dataclass__init__fields__4__annotation,
|
|
1778
|
+
__dataclass__init__fields__4__default,
|
|
1779
|
+
__dataclass__init__fields__5__annotation,
|
|
1780
|
+
__dataclass__init__fields__5__default,
|
|
1781
|
+
__dataclass__init__fields__6__annotation,
|
|
1782
|
+
__dataclass__init__fields__6__default,
|
|
1783
|
+
__dataclass__init__fields__7__annotation,
|
|
1784
|
+
__dataclass__init__fields__7__default,
|
|
1785
|
+
__dataclass__init__fields__8__annotation,
|
|
1786
|
+
__dataclass__init__fields__8__default,
|
|
1787
|
+
__dataclass__init__fields__9__annotation,
|
|
1788
|
+
__dataclass__init__fields__9__default,
|
|
1789
|
+
__dataclass__repr__default_fn,
|
|
1790
|
+
__dataclass__FieldFnValidationError, # noqa
|
|
1791
|
+
__dataclass__FieldTypeValidationError, # noqa
|
|
1792
|
+
__dataclass__FnValidationError, # noqa
|
|
1793
|
+
__dataclass__FrozenInstanceError=dataclasses.FrozenInstanceError, # noqa
|
|
1794
|
+
__dataclass__FunctionType=types.FunctionType, # noqa
|
|
1795
|
+
__dataclass__HAS_DEFAULT_FACTORY=dataclasses._HAS_DEFAULT_FACTORY, # noqa
|
|
1796
|
+
__dataclass__MISSING=dataclasses.MISSING, # noqa
|
|
1797
|
+
__dataclass__None=None, # noqa
|
|
1798
|
+
__dataclass__TypeError=TypeError, # noqa
|
|
1799
|
+
__dataclass___recursive_repr=reprlib.recursive_repr, # noqa
|
|
1800
|
+
__dataclass__isinstance=isinstance, # noqa
|
|
1801
|
+
__dataclass__object_setattr=object.__setattr__, # noqa
|
|
1802
|
+
__dataclass__property=property, # noqa
|
|
1803
|
+
):
|
|
1804
|
+
def __copy__(self):
|
|
1805
|
+
if self.__class__ is not __dataclass__cls:
|
|
1806
|
+
raise TypeError(self)
|
|
1807
|
+
return __dataclass__cls( # noqa
|
|
1808
|
+
model=self.model,
|
|
1809
|
+
created_at=self.created_at,
|
|
1810
|
+
done=self.done,
|
|
1811
|
+
done_reason=self.done_reason,
|
|
1812
|
+
total_duration=self.total_duration,
|
|
1813
|
+
load_duration=self.load_duration,
|
|
1814
|
+
prompt_eval_count=self.prompt_eval_count,
|
|
1815
|
+
prompt_eval_duration=self.prompt_eval_duration,
|
|
1816
|
+
eval_count=self.eval_count,
|
|
1817
|
+
eval_duration=self.eval_duration,
|
|
1818
|
+
response=self.response,
|
|
1819
|
+
thinking=self.thinking,
|
|
1820
|
+
context=self.context,
|
|
1821
|
+
)
|
|
1822
|
+
|
|
1823
|
+
__copy__.__qualname__ = f"{__dataclass__cls.__qualname__}.__copy__"
|
|
1824
|
+
if '__copy__' in __dataclass__cls.__dict__:
|
|
1825
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __copy__ in class {__dataclass__cls.__name__}")
|
|
1826
|
+
setattr(__dataclass__cls, '__copy__', __copy__)
|
|
1827
|
+
|
|
1828
|
+
def __eq__(self, other):
|
|
1829
|
+
if self is other:
|
|
1830
|
+
return True
|
|
1831
|
+
if self.__class__ is not other.__class__:
|
|
1832
|
+
return NotImplemented
|
|
1833
|
+
return (
|
|
1834
|
+
self.model == other.model and
|
|
1835
|
+
self.created_at == other.created_at and
|
|
1836
|
+
self.done == other.done and
|
|
1837
|
+
self.done_reason == other.done_reason and
|
|
1838
|
+
self.total_duration == other.total_duration and
|
|
1839
|
+
self.load_duration == other.load_duration and
|
|
1840
|
+
self.prompt_eval_count == other.prompt_eval_count and
|
|
1841
|
+
self.prompt_eval_duration == other.prompt_eval_duration and
|
|
1842
|
+
self.eval_count == other.eval_count and
|
|
1843
|
+
self.eval_duration == other.eval_duration and
|
|
1844
|
+
self.response == other.response and
|
|
1845
|
+
self.thinking == other.thinking and
|
|
1846
|
+
self.context == other.context
|
|
1847
|
+
)
|
|
1848
|
+
|
|
1849
|
+
__eq__.__qualname__ = f"{__dataclass__cls.__qualname__}.__eq__"
|
|
1850
|
+
if '__eq__' in __dataclass__cls.__dict__:
|
|
1851
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __eq__ in class {__dataclass__cls.__name__}")
|
|
1852
|
+
setattr(__dataclass__cls, '__eq__', __eq__)
|
|
1853
|
+
|
|
1854
|
+
__dataclass___setattr_frozen_fields = {
|
|
1855
|
+
'model',
|
|
1856
|
+
'created_at',
|
|
1857
|
+
'done',
|
|
1858
|
+
'done_reason',
|
|
1859
|
+
'total_duration',
|
|
1860
|
+
'load_duration',
|
|
1861
|
+
'prompt_eval_count',
|
|
1862
|
+
'prompt_eval_duration',
|
|
1863
|
+
'eval_count',
|
|
1864
|
+
'eval_duration',
|
|
1865
|
+
'response',
|
|
1866
|
+
'thinking',
|
|
1867
|
+
'context',
|
|
1868
|
+
}
|
|
1869
|
+
|
|
1870
|
+
def __setattr__(self, name, value):
|
|
1871
|
+
if (
|
|
1872
|
+
type(self) is __dataclass__cls
|
|
1873
|
+
or name in __dataclass___setattr_frozen_fields
|
|
1874
|
+
):
|
|
1875
|
+
raise __dataclass__FrozenInstanceError(f"cannot assign to field {name!r}")
|
|
1876
|
+
super(__dataclass__cls, self).__setattr__(name, value)
|
|
1877
|
+
|
|
1878
|
+
__setattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__setattr__"
|
|
1879
|
+
if '__setattr__' in __dataclass__cls.__dict__:
|
|
1880
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __setattr__ in class {__dataclass__cls.__name__}")
|
|
1881
|
+
setattr(__dataclass__cls, '__setattr__', __setattr__)
|
|
1882
|
+
|
|
1883
|
+
__dataclass___delattr_frozen_fields = {
|
|
1884
|
+
'model',
|
|
1885
|
+
'created_at',
|
|
1886
|
+
'done',
|
|
1887
|
+
'done_reason',
|
|
1888
|
+
'total_duration',
|
|
1889
|
+
'load_duration',
|
|
1890
|
+
'prompt_eval_count',
|
|
1891
|
+
'prompt_eval_duration',
|
|
1892
|
+
'eval_count',
|
|
1893
|
+
'eval_duration',
|
|
1894
|
+
'response',
|
|
1895
|
+
'thinking',
|
|
1896
|
+
'context',
|
|
1897
|
+
}
|
|
1898
|
+
|
|
1899
|
+
def __delattr__(self, name):
|
|
1900
|
+
if (
|
|
1901
|
+
type(self) is __dataclass__cls
|
|
1902
|
+
or name in __dataclass___delattr_frozen_fields
|
|
1903
|
+
):
|
|
1904
|
+
raise __dataclass__FrozenInstanceError(f"cannot delete field {name!r}")
|
|
1905
|
+
super(__dataclass__cls, self).__delattr__(name)
|
|
1906
|
+
|
|
1907
|
+
__delattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__delattr__"
|
|
1908
|
+
if '__delattr__' in __dataclass__cls.__dict__:
|
|
1909
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __delattr__ in class {__dataclass__cls.__name__}")
|
|
1910
|
+
setattr(__dataclass__cls, '__delattr__', __delattr__)
|
|
1911
|
+
|
|
1912
|
+
def __hash__(self):
|
|
1913
|
+
return hash((
|
|
1914
|
+
self.model,
|
|
1915
|
+
self.created_at,
|
|
1916
|
+
self.done,
|
|
1917
|
+
self.done_reason,
|
|
1918
|
+
self.total_duration,
|
|
1919
|
+
self.load_duration,
|
|
1920
|
+
self.prompt_eval_count,
|
|
1921
|
+
self.prompt_eval_duration,
|
|
1922
|
+
self.eval_count,
|
|
1923
|
+
self.eval_duration,
|
|
1924
|
+
self.response,
|
|
1925
|
+
self.thinking,
|
|
1926
|
+
self.context,
|
|
1927
|
+
))
|
|
1928
|
+
|
|
1929
|
+
__hash__.__qualname__ = f"{__dataclass__cls.__qualname__}.__hash__"
|
|
1930
|
+
setattr(__dataclass__cls, '__hash__', __hash__)
|
|
1931
|
+
|
|
1932
|
+
def __init__(
|
|
1933
|
+
self,
|
|
1934
|
+
*,
|
|
1935
|
+
model: __dataclass__init__fields__0__annotation = __dataclass__init__fields__0__default,
|
|
1936
|
+
created_at: __dataclass__init__fields__1__annotation = __dataclass__init__fields__1__default,
|
|
1937
|
+
done: __dataclass__init__fields__2__annotation = __dataclass__init__fields__2__default,
|
|
1938
|
+
done_reason: __dataclass__init__fields__3__annotation = __dataclass__init__fields__3__default,
|
|
1939
|
+
total_duration: __dataclass__init__fields__4__annotation = __dataclass__init__fields__4__default,
|
|
1940
|
+
load_duration: __dataclass__init__fields__5__annotation = __dataclass__init__fields__5__default,
|
|
1941
|
+
prompt_eval_count: __dataclass__init__fields__6__annotation = __dataclass__init__fields__6__default,
|
|
1942
|
+
prompt_eval_duration: __dataclass__init__fields__7__annotation = __dataclass__init__fields__7__default,
|
|
1943
|
+
eval_count: __dataclass__init__fields__8__annotation = __dataclass__init__fields__8__default,
|
|
1944
|
+
eval_duration: __dataclass__init__fields__9__annotation = __dataclass__init__fields__9__default,
|
|
1945
|
+
response: __dataclass__init__fields__10__annotation,
|
|
1946
|
+
thinking: __dataclass__init__fields__11__annotation = __dataclass__init__fields__11__default,
|
|
1947
|
+
context: __dataclass__init__fields__12__annotation = __dataclass__init__fields__12__default,
|
|
1948
|
+
) -> __dataclass__None:
|
|
1949
|
+
__dataclass__object_setattr(self, 'model', model)
|
|
1950
|
+
__dataclass__object_setattr(self, 'created_at', created_at)
|
|
1951
|
+
__dataclass__object_setattr(self, 'done', done)
|
|
1952
|
+
__dataclass__object_setattr(self, 'done_reason', done_reason)
|
|
1953
|
+
__dataclass__object_setattr(self, 'total_duration', total_duration)
|
|
1954
|
+
__dataclass__object_setattr(self, 'load_duration', load_duration)
|
|
1955
|
+
__dataclass__object_setattr(self, 'prompt_eval_count', prompt_eval_count)
|
|
1956
|
+
__dataclass__object_setattr(self, 'prompt_eval_duration', prompt_eval_duration)
|
|
1957
|
+
__dataclass__object_setattr(self, 'eval_count', eval_count)
|
|
1958
|
+
__dataclass__object_setattr(self, 'eval_duration', eval_duration)
|
|
1959
|
+
__dataclass__object_setattr(self, 'response', response)
|
|
1960
|
+
__dataclass__object_setattr(self, 'thinking', thinking)
|
|
1961
|
+
__dataclass__object_setattr(self, 'context', context)
|
|
1962
|
+
|
|
1963
|
+
__init__.__qualname__ = f"{__dataclass__cls.__qualname__}.__init__"
|
|
1964
|
+
if '__init__' in __dataclass__cls.__dict__:
|
|
1965
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __init__ in class {__dataclass__cls.__name__}")
|
|
1966
|
+
setattr(__dataclass__cls, '__init__', __init__)
|
|
1967
|
+
|
|
1968
|
+
@__dataclass___recursive_repr()
|
|
1969
|
+
def __repr__(self):
|
|
1970
|
+
parts = []
|
|
1971
|
+
if (s := __dataclass__repr__default_fn(self.model)) is not None:
|
|
1972
|
+
parts.append(f"model={s}")
|
|
1973
|
+
if (s := __dataclass__repr__default_fn(self.created_at)) is not None:
|
|
1974
|
+
parts.append(f"created_at={s}")
|
|
1975
|
+
if (s := __dataclass__repr__default_fn(self.done)) is not None:
|
|
1976
|
+
parts.append(f"done={s}")
|
|
1977
|
+
if (s := __dataclass__repr__default_fn(self.done_reason)) is not None:
|
|
1978
|
+
parts.append(f"done_reason={s}")
|
|
1979
|
+
if (s := __dataclass__repr__default_fn(self.total_duration)) is not None:
|
|
1980
|
+
parts.append(f"total_duration={s}")
|
|
1981
|
+
if (s := __dataclass__repr__default_fn(self.load_duration)) is not None:
|
|
1982
|
+
parts.append(f"load_duration={s}")
|
|
1983
|
+
if (s := __dataclass__repr__default_fn(self.prompt_eval_count)) is not None:
|
|
1984
|
+
parts.append(f"prompt_eval_count={s}")
|
|
1985
|
+
if (s := __dataclass__repr__default_fn(self.prompt_eval_duration)) is not None:
|
|
1986
|
+
parts.append(f"prompt_eval_duration={s}")
|
|
1987
|
+
if (s := __dataclass__repr__default_fn(self.eval_count)) is not None:
|
|
1988
|
+
parts.append(f"eval_count={s}")
|
|
1989
|
+
if (s := __dataclass__repr__default_fn(self.eval_duration)) is not None:
|
|
1990
|
+
parts.append(f"eval_duration={s}")
|
|
1991
|
+
if (s := __dataclass__repr__default_fn(self.response)) is not None:
|
|
1992
|
+
parts.append(f"response={s}")
|
|
1993
|
+
if (s := __dataclass__repr__default_fn(self.thinking)) is not None:
|
|
1994
|
+
parts.append(f"thinking={s}")
|
|
1995
|
+
if (s := __dataclass__repr__default_fn(self.context)) is not None:
|
|
1996
|
+
parts.append(f"context={s}")
|
|
1997
|
+
return (
|
|
1998
|
+
f"{self.__class__.__qualname__}("
|
|
1999
|
+
f"{', '.join(parts)}"
|
|
2000
|
+
f")"
|
|
2001
|
+
)
|
|
2002
|
+
|
|
2003
|
+
__repr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__repr__"
|
|
2004
|
+
if '__repr__' in __dataclass__cls.__dict__:
|
|
2005
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __repr__ in class {__dataclass__cls.__name__}")
|
|
2006
|
+
setattr(__dataclass__cls, '__repr__', __repr__)
|
|
2007
|
+
|
|
2008
|
+
return _process_dataclass
|
|
2009
|
+
|
|
2010
|
+
|
|
2011
|
+
@_register(
|
|
2012
|
+
plan_repr=(
|
|
2013
|
+
"Plans(tup=(CopyPlan(fields=('name', 'model', 'remote_model', 'remote_host', 'modified_at', 'size', 'digest', '"
|
|
2014
|
+
"details')), EqPlan(fields=('name', 'model', 'remote_model', 'remote_host', 'modified_at', 'size', 'digest', 'd"
|
|
2015
|
+
"etails')), FrozenPlan(fields=('name', 'model', 'remote_model', 'remote_host', 'modified_at', 'size', 'digest',"
|
|
2016
|
+
" 'details'), allow_dynamic_dunder_attrs=False), HashPlan(action='add', fields=('name', 'model', 'remote_model'"
|
|
2017
|
+
", 'remote_host', 'modified_at', 'size', 'digest', 'details'), cache=False), InitPlan(fields=(InitPlan.Field(na"
|
|
2018
|
+
"me='name', annotation=OpRef(name='init.fields.0.annotation'), default=None, default_factory=None, init=True, o"
|
|
2019
|
+
"verride=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(nam"
|
|
2020
|
+
"e='model', annotation=OpRef(name='init.fields.1.annotation'), default=None, default_factory=None, init=True, o"
|
|
2021
|
+
"verride=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(nam"
|
|
2022
|
+
"e='remote_model', annotation=OpRef(name='init.fields.2.annotation'), default=OpRef(name='init.fields.2.default"
|
|
2023
|
+
"'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None"
|
|
2024
|
+
", check_type=None), InitPlan.Field(name='remote_host', annotation=OpRef(name='init.fields.3.annotation'), defa"
|
|
2025
|
+
"ult=OpRef(name='init.fields.3.default'), default_factory=None, init=True, override=False, field_type=FieldType"
|
|
2026
|
+
".INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='modified_at', annotation=OpRef(n"
|
|
2027
|
+
"ame='init.fields.4.annotation'), default=None, default_factory=None, init=True, override=False, field_type=Fie"
|
|
2028
|
+
"ldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='size', annotation=OpRef(na"
|
|
2029
|
+
"me='init.fields.5.annotation'), default=None, default_factory=None, init=True, override=False, field_type=Fiel"
|
|
2030
|
+
"dType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='digest', annotation=OpRef(n"
|
|
2031
|
+
"ame='init.fields.6.annotation'), default=None, default_factory=None, init=True, override=False, field_type=Fie"
|
|
2032
|
+
"ldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='details', annotation=OpRef"
|
|
2033
|
+
"(name='init.fields.7.annotation'), default=OpRef(name='init.fields.7.default'), default_factory=None, init=Tru"
|
|
2034
|
+
"e, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None)), self_param='s"
|
|
2035
|
+
"elf', std_params=(), kw_only_params=('name', 'model', 'remote_model', 'remote_host', 'modified_at', 'size', 'd"
|
|
2036
|
+
"igest', 'details'), frozen=True, slots=False, post_init_params=None, init_fns=(), validate_fns=()), ReprPlan(f"
|
|
2037
|
+
"ields=(ReprPlan.Field(name='name', kw_only=True, fn=None), ReprPlan.Field(name='model', kw_only=True, fn=None)"
|
|
2038
|
+
", ReprPlan.Field(name='remote_model', kw_only=True, fn=None), ReprPlan.Field(name='remote_host', kw_only=True,"
|
|
2039
|
+
" fn=None), ReprPlan.Field(name='modified_at', kw_only=True, fn=None), ReprPlan.Field(name='size', kw_only=True"
|
|
2040
|
+
", fn=None), ReprPlan.Field(name='digest', kw_only=True, fn=None), ReprPlan.Field(name='details', kw_only=True,"
|
|
2041
|
+
" fn=None)), id=False, terse=False, default_fn=OpRef(name='repr.default_fn'))))"
|
|
2042
|
+
),
|
|
2043
|
+
plan_repr_sha1='39f7bcef98c1ad6b9fc898613abfef167e9b916f',
|
|
2044
|
+
op_ref_idents=(
|
|
2045
|
+
'__dataclass__init__fields__0__annotation',
|
|
2046
|
+
'__dataclass__init__fields__1__annotation',
|
|
2047
|
+
'__dataclass__init__fields__2__annotation',
|
|
2048
|
+
'__dataclass__init__fields__2__default',
|
|
2049
|
+
'__dataclass__init__fields__3__annotation',
|
|
2050
|
+
'__dataclass__init__fields__3__default',
|
|
2051
|
+
'__dataclass__init__fields__4__annotation',
|
|
2052
|
+
'__dataclass__init__fields__5__annotation',
|
|
2053
|
+
'__dataclass__init__fields__6__annotation',
|
|
2054
|
+
'__dataclass__init__fields__7__annotation',
|
|
2055
|
+
'__dataclass__init__fields__7__default',
|
|
2056
|
+
'__dataclass__repr__default_fn',
|
|
2057
|
+
),
|
|
2058
|
+
cls_names=(
|
|
2059
|
+
('ommlds.backends.ollama.protocol', 'ListModelResponse'),
|
|
2060
|
+
),
|
|
2061
|
+
)
|
|
2062
|
+
def _process_dataclass__39f7bcef98c1ad6b9fc898613abfef167e9b916f():
|
|
2063
|
+
def _process_dataclass(
|
|
2064
|
+
*,
|
|
2065
|
+
__dataclass__cls,
|
|
2066
|
+
__dataclass__init__fields__0__annotation,
|
|
2067
|
+
__dataclass__init__fields__1__annotation,
|
|
2068
|
+
__dataclass__init__fields__2__annotation,
|
|
2069
|
+
__dataclass__init__fields__2__default,
|
|
2070
|
+
__dataclass__init__fields__3__annotation,
|
|
2071
|
+
__dataclass__init__fields__3__default,
|
|
2072
|
+
__dataclass__init__fields__4__annotation,
|
|
2073
|
+
__dataclass__init__fields__5__annotation,
|
|
2074
|
+
__dataclass__init__fields__6__annotation,
|
|
2075
|
+
__dataclass__init__fields__7__annotation,
|
|
2076
|
+
__dataclass__init__fields__7__default,
|
|
2077
|
+
__dataclass__repr__default_fn,
|
|
2078
|
+
__dataclass__FieldFnValidationError, # noqa
|
|
2079
|
+
__dataclass__FieldTypeValidationError, # noqa
|
|
2080
|
+
__dataclass__FnValidationError, # noqa
|
|
2081
|
+
__dataclass__FrozenInstanceError=dataclasses.FrozenInstanceError, # noqa
|
|
2082
|
+
__dataclass__FunctionType=types.FunctionType, # noqa
|
|
2083
|
+
__dataclass__HAS_DEFAULT_FACTORY=dataclasses._HAS_DEFAULT_FACTORY, # noqa
|
|
2084
|
+
__dataclass__MISSING=dataclasses.MISSING, # noqa
|
|
2085
|
+
__dataclass__None=None, # noqa
|
|
2086
|
+
__dataclass__TypeError=TypeError, # noqa
|
|
2087
|
+
__dataclass___recursive_repr=reprlib.recursive_repr, # noqa
|
|
2088
|
+
__dataclass__isinstance=isinstance, # noqa
|
|
2089
|
+
__dataclass__object_setattr=object.__setattr__, # noqa
|
|
2090
|
+
__dataclass__property=property, # noqa
|
|
2091
|
+
):
|
|
2092
|
+
def __copy__(self):
|
|
2093
|
+
if self.__class__ is not __dataclass__cls:
|
|
2094
|
+
raise TypeError(self)
|
|
2095
|
+
return __dataclass__cls( # noqa
|
|
2096
|
+
name=self.name,
|
|
2097
|
+
model=self.model,
|
|
2098
|
+
remote_model=self.remote_model,
|
|
2099
|
+
remote_host=self.remote_host,
|
|
2100
|
+
modified_at=self.modified_at,
|
|
2101
|
+
size=self.size,
|
|
2102
|
+
digest=self.digest,
|
|
2103
|
+
details=self.details,
|
|
2104
|
+
)
|
|
2105
|
+
|
|
2106
|
+
__copy__.__qualname__ = f"{__dataclass__cls.__qualname__}.__copy__"
|
|
2107
|
+
if '__copy__' in __dataclass__cls.__dict__:
|
|
2108
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __copy__ in class {__dataclass__cls.__name__}")
|
|
2109
|
+
setattr(__dataclass__cls, '__copy__', __copy__)
|
|
2110
|
+
|
|
2111
|
+
def __eq__(self, other):
|
|
2112
|
+
if self is other:
|
|
2113
|
+
return True
|
|
2114
|
+
if self.__class__ is not other.__class__:
|
|
2115
|
+
return NotImplemented
|
|
2116
|
+
return (
|
|
2117
|
+
self.name == other.name and
|
|
2118
|
+
self.model == other.model and
|
|
2119
|
+
self.remote_model == other.remote_model and
|
|
2120
|
+
self.remote_host == other.remote_host and
|
|
2121
|
+
self.modified_at == other.modified_at and
|
|
2122
|
+
self.size == other.size and
|
|
2123
|
+
self.digest == other.digest and
|
|
2124
|
+
self.details == other.details
|
|
2125
|
+
)
|
|
2126
|
+
|
|
2127
|
+
__eq__.__qualname__ = f"{__dataclass__cls.__qualname__}.__eq__"
|
|
2128
|
+
if '__eq__' in __dataclass__cls.__dict__:
|
|
2129
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __eq__ in class {__dataclass__cls.__name__}")
|
|
2130
|
+
setattr(__dataclass__cls, '__eq__', __eq__)
|
|
2131
|
+
|
|
2132
|
+
__dataclass___setattr_frozen_fields = {
|
|
2133
|
+
'name',
|
|
2134
|
+
'model',
|
|
2135
|
+
'remote_model',
|
|
2136
|
+
'remote_host',
|
|
2137
|
+
'modified_at',
|
|
2138
|
+
'size',
|
|
2139
|
+
'digest',
|
|
2140
|
+
'details',
|
|
2141
|
+
}
|
|
2142
|
+
|
|
2143
|
+
def __setattr__(self, name, value):
|
|
2144
|
+
if (
|
|
2145
|
+
type(self) is __dataclass__cls
|
|
2146
|
+
or name in __dataclass___setattr_frozen_fields
|
|
2147
|
+
):
|
|
2148
|
+
raise __dataclass__FrozenInstanceError(f"cannot assign to field {name!r}")
|
|
2149
|
+
super(__dataclass__cls, self).__setattr__(name, value)
|
|
2150
|
+
|
|
2151
|
+
__setattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__setattr__"
|
|
2152
|
+
if '__setattr__' in __dataclass__cls.__dict__:
|
|
2153
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __setattr__ in class {__dataclass__cls.__name__}")
|
|
2154
|
+
setattr(__dataclass__cls, '__setattr__', __setattr__)
|
|
2155
|
+
|
|
2156
|
+
__dataclass___delattr_frozen_fields = {
|
|
2157
|
+
'name',
|
|
2158
|
+
'model',
|
|
2159
|
+
'remote_model',
|
|
2160
|
+
'remote_host',
|
|
2161
|
+
'modified_at',
|
|
2162
|
+
'size',
|
|
2163
|
+
'digest',
|
|
2164
|
+
'details',
|
|
2165
|
+
}
|
|
2166
|
+
|
|
2167
|
+
def __delattr__(self, name):
|
|
2168
|
+
if (
|
|
2169
|
+
type(self) is __dataclass__cls
|
|
2170
|
+
or name in __dataclass___delattr_frozen_fields
|
|
2171
|
+
):
|
|
2172
|
+
raise __dataclass__FrozenInstanceError(f"cannot delete field {name!r}")
|
|
2173
|
+
super(__dataclass__cls, self).__delattr__(name)
|
|
2174
|
+
|
|
2175
|
+
__delattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__delattr__"
|
|
2176
|
+
if '__delattr__' in __dataclass__cls.__dict__:
|
|
2177
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __delattr__ in class {__dataclass__cls.__name__}")
|
|
2178
|
+
setattr(__dataclass__cls, '__delattr__', __delattr__)
|
|
2179
|
+
|
|
2180
|
+
def __hash__(self):
|
|
2181
|
+
return hash((
|
|
2182
|
+
self.name,
|
|
2183
|
+
self.model,
|
|
2184
|
+
self.remote_model,
|
|
2185
|
+
self.remote_host,
|
|
2186
|
+
self.modified_at,
|
|
2187
|
+
self.size,
|
|
2188
|
+
self.digest,
|
|
2189
|
+
self.details,
|
|
2190
|
+
))
|
|
2191
|
+
|
|
2192
|
+
__hash__.__qualname__ = f"{__dataclass__cls.__qualname__}.__hash__"
|
|
2193
|
+
setattr(__dataclass__cls, '__hash__', __hash__)
|
|
2194
|
+
|
|
2195
|
+
def __init__(
|
|
2196
|
+
self,
|
|
2197
|
+
*,
|
|
2198
|
+
name: __dataclass__init__fields__0__annotation,
|
|
2199
|
+
model: __dataclass__init__fields__1__annotation,
|
|
2200
|
+
remote_model: __dataclass__init__fields__2__annotation = __dataclass__init__fields__2__default,
|
|
2201
|
+
remote_host: __dataclass__init__fields__3__annotation = __dataclass__init__fields__3__default,
|
|
2202
|
+
modified_at: __dataclass__init__fields__4__annotation,
|
|
2203
|
+
size: __dataclass__init__fields__5__annotation,
|
|
2204
|
+
digest: __dataclass__init__fields__6__annotation,
|
|
2205
|
+
details: __dataclass__init__fields__7__annotation = __dataclass__init__fields__7__default,
|
|
2206
|
+
) -> __dataclass__None:
|
|
2207
|
+
__dataclass__object_setattr(self, 'name', name)
|
|
2208
|
+
__dataclass__object_setattr(self, 'model', model)
|
|
2209
|
+
__dataclass__object_setattr(self, 'remote_model', remote_model)
|
|
2210
|
+
__dataclass__object_setattr(self, 'remote_host', remote_host)
|
|
2211
|
+
__dataclass__object_setattr(self, 'modified_at', modified_at)
|
|
2212
|
+
__dataclass__object_setattr(self, 'size', size)
|
|
2213
|
+
__dataclass__object_setattr(self, 'digest', digest)
|
|
2214
|
+
__dataclass__object_setattr(self, 'details', details)
|
|
2215
|
+
|
|
2216
|
+
__init__.__qualname__ = f"{__dataclass__cls.__qualname__}.__init__"
|
|
2217
|
+
if '__init__' in __dataclass__cls.__dict__:
|
|
2218
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __init__ in class {__dataclass__cls.__name__}")
|
|
2219
|
+
setattr(__dataclass__cls, '__init__', __init__)
|
|
2220
|
+
|
|
2221
|
+
@__dataclass___recursive_repr()
|
|
2222
|
+
def __repr__(self):
|
|
2223
|
+
parts = []
|
|
2224
|
+
if (s := __dataclass__repr__default_fn(self.name)) is not None:
|
|
2225
|
+
parts.append(f"name={s}")
|
|
2226
|
+
if (s := __dataclass__repr__default_fn(self.model)) is not None:
|
|
2227
|
+
parts.append(f"model={s}")
|
|
2228
|
+
if (s := __dataclass__repr__default_fn(self.remote_model)) is not None:
|
|
2229
|
+
parts.append(f"remote_model={s}")
|
|
2230
|
+
if (s := __dataclass__repr__default_fn(self.remote_host)) is not None:
|
|
2231
|
+
parts.append(f"remote_host={s}")
|
|
2232
|
+
if (s := __dataclass__repr__default_fn(self.modified_at)) is not None:
|
|
2233
|
+
parts.append(f"modified_at={s}")
|
|
2234
|
+
if (s := __dataclass__repr__default_fn(self.size)) is not None:
|
|
2235
|
+
parts.append(f"size={s}")
|
|
2236
|
+
if (s := __dataclass__repr__default_fn(self.digest)) is not None:
|
|
2237
|
+
parts.append(f"digest={s}")
|
|
2238
|
+
if (s := __dataclass__repr__default_fn(self.details)) is not None:
|
|
2239
|
+
parts.append(f"details={s}")
|
|
2240
|
+
return (
|
|
2241
|
+
f"{self.__class__.__qualname__}("
|
|
2242
|
+
f"{', '.join(parts)}"
|
|
2243
|
+
f")"
|
|
2244
|
+
)
|
|
2245
|
+
|
|
2246
|
+
__repr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__repr__"
|
|
2247
|
+
if '__repr__' in __dataclass__cls.__dict__:
|
|
2248
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __repr__ in class {__dataclass__cls.__name__}")
|
|
2249
|
+
setattr(__dataclass__cls, '__repr__', __repr__)
|
|
2250
|
+
|
|
2251
|
+
return _process_dataclass
|
|
2252
|
+
|
|
2253
|
+
|
|
2254
|
+
@_register(
|
|
2255
|
+
plan_repr=(
|
|
2256
|
+
"Plans(tup=(CopyPlan(fields=('role', 'content', 'thinking', 'images', 'tool_name', 'tool_calls')), EqPlan(field"
|
|
2257
|
+
"s=('role', 'content', 'thinking', 'images', 'tool_name', 'tool_calls')), FrozenPlan(fields=('role', 'content',"
|
|
2258
|
+
" 'thinking', 'images', 'tool_name', 'tool_calls'), allow_dynamic_dunder_attrs=False), HashPlan(action='add', f"
|
|
2259
|
+
"ields=('role', 'content', 'thinking', 'images', 'tool_name', 'tool_calls'), cache=False), InitPlan(fields=(Ini"
|
|
2260
|
+
"tPlan.Field(name='role', annotation=OpRef(name='init.fields.0.annotation'), default=None, default_factory=None"
|
|
2261
|
+
", init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), Init"
|
|
2262
|
+
"Plan.Field(name='content', annotation=OpRef(name='init.fields.1.annotation'), default=OpRef(name='init.fields."
|
|
2263
|
+
"1.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, vali"
|
|
2264
|
+
"date=None, check_type=None), InitPlan.Field(name='thinking', annotation=OpRef(name='init.fields.2.annotation')"
|
|
2265
|
+
", default=OpRef(name='init.fields.2.default'), default_factory=None, init=True, override=False, field_type=Fie"
|
|
2266
|
+
"ldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='images', annotation=OpRef("
|
|
2267
|
+
"name='init.fields.3.annotation'), default=OpRef(name='init.fields.3.default'), default_factory=None, init=True"
|
|
2268
|
+
", override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field("
|
|
2269
|
+
"name='tool_name', annotation=OpRef(name='init.fields.4.annotation'), default=OpRef(name='init.fields.4.default"
|
|
2270
|
+
"'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None"
|
|
2271
|
+
", check_type=None), InitPlan.Field(name='tool_calls', annotation=OpRef(name='init.fields.5.annotation'), defau"
|
|
2272
|
+
"lt=OpRef(name='init.fields.5.default'), default_factory=None, init=True, override=False, field_type=FieldType."
|
|
2273
|
+
"INSTANCE, coerce=None, validate=None, check_type=None)), self_param='self', std_params=(), kw_only_params=('ro"
|
|
2274
|
+
"le', 'content', 'thinking', 'images', 'tool_name', 'tool_calls'), frozen=True, slots=False, post_init_params=N"
|
|
2275
|
+
"one, init_fns=(), validate_fns=()), ReprPlan(fields=(ReprPlan.Field(name='role', kw_only=True, fn=None), ReprP"
|
|
2276
|
+
"lan.Field(name='content', kw_only=True, fn=None), ReprPlan.Field(name='thinking', kw_only=True, fn=None), Repr"
|
|
2277
|
+
"Plan.Field(name='images', kw_only=True, fn=None), ReprPlan.Field(name='tool_name', kw_only=True, fn=None), Rep"
|
|
2278
|
+
"rPlan.Field(name='tool_calls', kw_only=True, fn=None)), id=False, terse=False, default_fn=OpRef(name='repr.def"
|
|
2279
|
+
"ault_fn'))))"
|
|
2280
|
+
),
|
|
2281
|
+
plan_repr_sha1='5ed26fc5132f873daeaffa682785bd1b47768acb',
|
|
2282
|
+
op_ref_idents=(
|
|
2283
|
+
'__dataclass__init__fields__0__annotation',
|
|
2284
|
+
'__dataclass__init__fields__1__annotation',
|
|
2285
|
+
'__dataclass__init__fields__1__default',
|
|
2286
|
+
'__dataclass__init__fields__2__annotation',
|
|
2287
|
+
'__dataclass__init__fields__2__default',
|
|
2288
|
+
'__dataclass__init__fields__3__annotation',
|
|
2289
|
+
'__dataclass__init__fields__3__default',
|
|
2290
|
+
'__dataclass__init__fields__4__annotation',
|
|
2291
|
+
'__dataclass__init__fields__4__default',
|
|
2292
|
+
'__dataclass__init__fields__5__annotation',
|
|
2293
|
+
'__dataclass__init__fields__5__default',
|
|
2294
|
+
'__dataclass__repr__default_fn',
|
|
2295
|
+
),
|
|
2296
|
+
cls_names=(
|
|
2297
|
+
('ommlds.backends.ollama.protocol', 'Message'),
|
|
2298
|
+
),
|
|
2299
|
+
)
|
|
2300
|
+
def _process_dataclass__5ed26fc5132f873daeaffa682785bd1b47768acb():
|
|
2301
|
+
def _process_dataclass(
|
|
2302
|
+
*,
|
|
2303
|
+
__dataclass__cls,
|
|
2304
|
+
__dataclass__init__fields__0__annotation,
|
|
2305
|
+
__dataclass__init__fields__1__annotation,
|
|
2306
|
+
__dataclass__init__fields__1__default,
|
|
2307
|
+
__dataclass__init__fields__2__annotation,
|
|
2308
|
+
__dataclass__init__fields__2__default,
|
|
2309
|
+
__dataclass__init__fields__3__annotation,
|
|
2310
|
+
__dataclass__init__fields__3__default,
|
|
2311
|
+
__dataclass__init__fields__4__annotation,
|
|
2312
|
+
__dataclass__init__fields__4__default,
|
|
2313
|
+
__dataclass__init__fields__5__annotation,
|
|
2314
|
+
__dataclass__init__fields__5__default,
|
|
2315
|
+
__dataclass__repr__default_fn,
|
|
2316
|
+
__dataclass__FieldFnValidationError, # noqa
|
|
2317
|
+
__dataclass__FieldTypeValidationError, # noqa
|
|
2318
|
+
__dataclass__FnValidationError, # noqa
|
|
2319
|
+
__dataclass__FrozenInstanceError=dataclasses.FrozenInstanceError, # noqa
|
|
2320
|
+
__dataclass__FunctionType=types.FunctionType, # noqa
|
|
2321
|
+
__dataclass__HAS_DEFAULT_FACTORY=dataclasses._HAS_DEFAULT_FACTORY, # noqa
|
|
2322
|
+
__dataclass__MISSING=dataclasses.MISSING, # noqa
|
|
2323
|
+
__dataclass__None=None, # noqa
|
|
2324
|
+
__dataclass__TypeError=TypeError, # noqa
|
|
2325
|
+
__dataclass___recursive_repr=reprlib.recursive_repr, # noqa
|
|
2326
|
+
__dataclass__isinstance=isinstance, # noqa
|
|
2327
|
+
__dataclass__object_setattr=object.__setattr__, # noqa
|
|
2328
|
+
__dataclass__property=property, # noqa
|
|
2329
|
+
):
|
|
2330
|
+
def __copy__(self):
|
|
2331
|
+
if self.__class__ is not __dataclass__cls:
|
|
2332
|
+
raise TypeError(self)
|
|
2333
|
+
return __dataclass__cls( # noqa
|
|
2334
|
+
role=self.role,
|
|
2335
|
+
content=self.content,
|
|
2336
|
+
thinking=self.thinking,
|
|
2337
|
+
images=self.images,
|
|
2338
|
+
tool_name=self.tool_name,
|
|
2339
|
+
tool_calls=self.tool_calls,
|
|
2340
|
+
)
|
|
2341
|
+
|
|
2342
|
+
__copy__.__qualname__ = f"{__dataclass__cls.__qualname__}.__copy__"
|
|
2343
|
+
if '__copy__' in __dataclass__cls.__dict__:
|
|
2344
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __copy__ in class {__dataclass__cls.__name__}")
|
|
2345
|
+
setattr(__dataclass__cls, '__copy__', __copy__)
|
|
2346
|
+
|
|
2347
|
+
def __eq__(self, other):
|
|
2348
|
+
if self is other:
|
|
2349
|
+
return True
|
|
2350
|
+
if self.__class__ is not other.__class__:
|
|
2351
|
+
return NotImplemented
|
|
2352
|
+
return (
|
|
2353
|
+
self.role == other.role and
|
|
2354
|
+
self.content == other.content and
|
|
2355
|
+
self.thinking == other.thinking and
|
|
2356
|
+
self.images == other.images and
|
|
2357
|
+
self.tool_name == other.tool_name and
|
|
2358
|
+
self.tool_calls == other.tool_calls
|
|
2359
|
+
)
|
|
2360
|
+
|
|
2361
|
+
__eq__.__qualname__ = f"{__dataclass__cls.__qualname__}.__eq__"
|
|
2362
|
+
if '__eq__' in __dataclass__cls.__dict__:
|
|
2363
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __eq__ in class {__dataclass__cls.__name__}")
|
|
2364
|
+
setattr(__dataclass__cls, '__eq__', __eq__)
|
|
2365
|
+
|
|
2366
|
+
__dataclass___setattr_frozen_fields = {
|
|
2367
|
+
'role',
|
|
2368
|
+
'content',
|
|
2369
|
+
'thinking',
|
|
2370
|
+
'images',
|
|
2371
|
+
'tool_name',
|
|
2372
|
+
'tool_calls',
|
|
2373
|
+
}
|
|
2374
|
+
|
|
2375
|
+
def __setattr__(self, name, value):
|
|
2376
|
+
if (
|
|
2377
|
+
type(self) is __dataclass__cls
|
|
2378
|
+
or name in __dataclass___setattr_frozen_fields
|
|
2379
|
+
):
|
|
2380
|
+
raise __dataclass__FrozenInstanceError(f"cannot assign to field {name!r}")
|
|
2381
|
+
super(__dataclass__cls, self).__setattr__(name, value)
|
|
2382
|
+
|
|
2383
|
+
__setattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__setattr__"
|
|
2384
|
+
if '__setattr__' in __dataclass__cls.__dict__:
|
|
2385
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __setattr__ in class {__dataclass__cls.__name__}")
|
|
2386
|
+
setattr(__dataclass__cls, '__setattr__', __setattr__)
|
|
2387
|
+
|
|
2388
|
+
__dataclass___delattr_frozen_fields = {
|
|
2389
|
+
'role',
|
|
2390
|
+
'content',
|
|
2391
|
+
'thinking',
|
|
2392
|
+
'images',
|
|
2393
|
+
'tool_name',
|
|
2394
|
+
'tool_calls',
|
|
2395
|
+
}
|
|
2396
|
+
|
|
2397
|
+
def __delattr__(self, name):
|
|
2398
|
+
if (
|
|
2399
|
+
type(self) is __dataclass__cls
|
|
2400
|
+
or name in __dataclass___delattr_frozen_fields
|
|
2401
|
+
):
|
|
2402
|
+
raise __dataclass__FrozenInstanceError(f"cannot delete field {name!r}")
|
|
2403
|
+
super(__dataclass__cls, self).__delattr__(name)
|
|
2404
|
+
|
|
2405
|
+
__delattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__delattr__"
|
|
2406
|
+
if '__delattr__' in __dataclass__cls.__dict__:
|
|
2407
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __delattr__ in class {__dataclass__cls.__name__}")
|
|
2408
|
+
setattr(__dataclass__cls, '__delattr__', __delattr__)
|
|
2409
|
+
|
|
2410
|
+
def __hash__(self):
|
|
2411
|
+
return hash((
|
|
2412
|
+
self.role,
|
|
2413
|
+
self.content,
|
|
2414
|
+
self.thinking,
|
|
2415
|
+
self.images,
|
|
2416
|
+
self.tool_name,
|
|
2417
|
+
self.tool_calls,
|
|
2418
|
+
))
|
|
2419
|
+
|
|
2420
|
+
__hash__.__qualname__ = f"{__dataclass__cls.__qualname__}.__hash__"
|
|
2421
|
+
setattr(__dataclass__cls, '__hash__', __hash__)
|
|
2422
|
+
|
|
2423
|
+
def __init__(
|
|
2424
|
+
self,
|
|
2425
|
+
*,
|
|
2426
|
+
role: __dataclass__init__fields__0__annotation,
|
|
2427
|
+
content: __dataclass__init__fields__1__annotation = __dataclass__init__fields__1__default,
|
|
2428
|
+
thinking: __dataclass__init__fields__2__annotation = __dataclass__init__fields__2__default,
|
|
2429
|
+
images: __dataclass__init__fields__3__annotation = __dataclass__init__fields__3__default,
|
|
2430
|
+
tool_name: __dataclass__init__fields__4__annotation = __dataclass__init__fields__4__default,
|
|
2431
|
+
tool_calls: __dataclass__init__fields__5__annotation = __dataclass__init__fields__5__default,
|
|
2432
|
+
) -> __dataclass__None:
|
|
2433
|
+
__dataclass__object_setattr(self, 'role', role)
|
|
2434
|
+
__dataclass__object_setattr(self, 'content', content)
|
|
2435
|
+
__dataclass__object_setattr(self, 'thinking', thinking)
|
|
2436
|
+
__dataclass__object_setattr(self, 'images', images)
|
|
2437
|
+
__dataclass__object_setattr(self, 'tool_name', tool_name)
|
|
2438
|
+
__dataclass__object_setattr(self, 'tool_calls', tool_calls)
|
|
2439
|
+
|
|
2440
|
+
__init__.__qualname__ = f"{__dataclass__cls.__qualname__}.__init__"
|
|
2441
|
+
if '__init__' in __dataclass__cls.__dict__:
|
|
2442
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __init__ in class {__dataclass__cls.__name__}")
|
|
2443
|
+
setattr(__dataclass__cls, '__init__', __init__)
|
|
2444
|
+
|
|
2445
|
+
@__dataclass___recursive_repr()
|
|
2446
|
+
def __repr__(self):
|
|
2447
|
+
parts = []
|
|
2448
|
+
if (s := __dataclass__repr__default_fn(self.role)) is not None:
|
|
2449
|
+
parts.append(f"role={s}")
|
|
2450
|
+
if (s := __dataclass__repr__default_fn(self.content)) is not None:
|
|
2451
|
+
parts.append(f"content={s}")
|
|
2452
|
+
if (s := __dataclass__repr__default_fn(self.thinking)) is not None:
|
|
2453
|
+
parts.append(f"thinking={s}")
|
|
2454
|
+
if (s := __dataclass__repr__default_fn(self.images)) is not None:
|
|
2455
|
+
parts.append(f"images={s}")
|
|
2456
|
+
if (s := __dataclass__repr__default_fn(self.tool_name)) is not None:
|
|
2457
|
+
parts.append(f"tool_name={s}")
|
|
2458
|
+
if (s := __dataclass__repr__default_fn(self.tool_calls)) is not None:
|
|
2459
|
+
parts.append(f"tool_calls={s}")
|
|
2460
|
+
return (
|
|
2461
|
+
f"{self.__class__.__qualname__}("
|
|
2462
|
+
f"{', '.join(parts)}"
|
|
2463
|
+
f")"
|
|
2464
|
+
)
|
|
2465
|
+
|
|
2466
|
+
__repr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__repr__"
|
|
2467
|
+
if '__repr__' in __dataclass__cls.__dict__:
|
|
2468
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __repr__ in class {__dataclass__cls.__name__}")
|
|
2469
|
+
setattr(__dataclass__cls, '__repr__', __repr__)
|
|
2470
|
+
|
|
2471
|
+
return _process_dataclass
|
|
2472
|
+
|
|
2473
|
+
|
|
2474
|
+
@_register(
|
|
2475
|
+
plan_repr=(
|
|
2476
|
+
"Plans(tup=(CopyPlan(fields=('id', 'function')), EqPlan(fields=('id', 'function')), FrozenPlan(fields=('id', 'f"
|
|
2477
|
+
"unction'), allow_dynamic_dunder_attrs=False), HashPlan(action='add', fields=('id', 'function'), cache=False), "
|
|
2478
|
+
"InitPlan(fields=(InitPlan.Field(name='id', annotation=OpRef(name='init.fields.0.annotation'), default=OpRef(na"
|
|
2479
|
+
"me='init.fields.0.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, c"
|
|
2480
|
+
"oerce=None, validate=None, check_type=None), InitPlan.Field(name='function', annotation=OpRef(name='init.field"
|
|
2481
|
+
"s.1.annotation'), default=None, default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE"
|
|
2482
|
+
", coerce=None, validate=None, check_type=None)), self_param='self', std_params=(), kw_only_params=('id', 'func"
|
|
2483
|
+
"tion'), frozen=True, slots=False, post_init_params=None, init_fns=(), validate_fns=()), ReprPlan(fields=(ReprP"
|
|
2484
|
+
"lan.Field(name='id', kw_only=True, fn=None), ReprPlan.Field(name='function', kw_only=True, fn=None)), id=False"
|
|
2485
|
+
", terse=False, default_fn=None)))"
|
|
2486
|
+
),
|
|
2487
|
+
plan_repr_sha1='7d5771c082d3ad6a1d478102e83deb352ad93e34',
|
|
2488
|
+
op_ref_idents=(
|
|
2489
|
+
'__dataclass__init__fields__0__annotation',
|
|
2490
|
+
'__dataclass__init__fields__0__default',
|
|
2491
|
+
'__dataclass__init__fields__1__annotation',
|
|
2492
|
+
),
|
|
2493
|
+
cls_names=(
|
|
2494
|
+
('ommlds.backends.ollama.protocol', 'Message.ToolCall'),
|
|
2495
|
+
),
|
|
2496
|
+
)
|
|
2497
|
+
def _process_dataclass__7d5771c082d3ad6a1d478102e83deb352ad93e34():
|
|
2498
|
+
def _process_dataclass(
|
|
2499
|
+
*,
|
|
2500
|
+
__dataclass__cls,
|
|
2501
|
+
__dataclass__init__fields__0__annotation,
|
|
2502
|
+
__dataclass__init__fields__0__default,
|
|
2503
|
+
__dataclass__init__fields__1__annotation,
|
|
2504
|
+
__dataclass__FieldFnValidationError, # noqa
|
|
2505
|
+
__dataclass__FieldTypeValidationError, # noqa
|
|
2506
|
+
__dataclass__FnValidationError, # noqa
|
|
2507
|
+
__dataclass__FrozenInstanceError=dataclasses.FrozenInstanceError, # noqa
|
|
2508
|
+
__dataclass__FunctionType=types.FunctionType, # noqa
|
|
2509
|
+
__dataclass__HAS_DEFAULT_FACTORY=dataclasses._HAS_DEFAULT_FACTORY, # noqa
|
|
2510
|
+
__dataclass__MISSING=dataclasses.MISSING, # noqa
|
|
2511
|
+
__dataclass__None=None, # noqa
|
|
2512
|
+
__dataclass__TypeError=TypeError, # noqa
|
|
2513
|
+
__dataclass___recursive_repr=reprlib.recursive_repr, # noqa
|
|
2514
|
+
__dataclass__isinstance=isinstance, # noqa
|
|
2515
|
+
__dataclass__object_setattr=object.__setattr__, # noqa
|
|
2516
|
+
__dataclass__property=property, # noqa
|
|
2517
|
+
):
|
|
2518
|
+
def __copy__(self):
|
|
2519
|
+
if self.__class__ is not __dataclass__cls:
|
|
2520
|
+
raise TypeError(self)
|
|
2521
|
+
return __dataclass__cls( # noqa
|
|
2522
|
+
id=self.id,
|
|
2523
|
+
function=self.function,
|
|
2524
|
+
)
|
|
2525
|
+
|
|
2526
|
+
__copy__.__qualname__ = f"{__dataclass__cls.__qualname__}.__copy__"
|
|
2527
|
+
if '__copy__' in __dataclass__cls.__dict__:
|
|
2528
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __copy__ in class {__dataclass__cls.__name__}")
|
|
2529
|
+
setattr(__dataclass__cls, '__copy__', __copy__)
|
|
2530
|
+
|
|
2531
|
+
def __eq__(self, other):
|
|
2532
|
+
if self is other:
|
|
2533
|
+
return True
|
|
2534
|
+
if self.__class__ is not other.__class__:
|
|
2535
|
+
return NotImplemented
|
|
2536
|
+
return (
|
|
2537
|
+
self.id == other.id and
|
|
2538
|
+
self.function == other.function
|
|
2539
|
+
)
|
|
2540
|
+
|
|
2541
|
+
__eq__.__qualname__ = f"{__dataclass__cls.__qualname__}.__eq__"
|
|
2542
|
+
if '__eq__' in __dataclass__cls.__dict__:
|
|
2543
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __eq__ in class {__dataclass__cls.__name__}")
|
|
2544
|
+
setattr(__dataclass__cls, '__eq__', __eq__)
|
|
2545
|
+
|
|
2546
|
+
__dataclass___setattr_frozen_fields = {
|
|
2547
|
+
'id',
|
|
2548
|
+
'function',
|
|
2549
|
+
}
|
|
2550
|
+
|
|
2551
|
+
def __setattr__(self, name, value):
|
|
2552
|
+
if (
|
|
2553
|
+
type(self) is __dataclass__cls
|
|
2554
|
+
or name in __dataclass___setattr_frozen_fields
|
|
2555
|
+
):
|
|
2556
|
+
raise __dataclass__FrozenInstanceError(f"cannot assign to field {name!r}")
|
|
2557
|
+
super(__dataclass__cls, self).__setattr__(name, value)
|
|
2558
|
+
|
|
2559
|
+
__setattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__setattr__"
|
|
2560
|
+
if '__setattr__' in __dataclass__cls.__dict__:
|
|
2561
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __setattr__ in class {__dataclass__cls.__name__}")
|
|
2562
|
+
setattr(__dataclass__cls, '__setattr__', __setattr__)
|
|
2563
|
+
|
|
2564
|
+
__dataclass___delattr_frozen_fields = {
|
|
2565
|
+
'id',
|
|
2566
|
+
'function',
|
|
2567
|
+
}
|
|
2568
|
+
|
|
2569
|
+
def __delattr__(self, name):
|
|
2570
|
+
if (
|
|
2571
|
+
type(self) is __dataclass__cls
|
|
2572
|
+
or name in __dataclass___delattr_frozen_fields
|
|
2573
|
+
):
|
|
2574
|
+
raise __dataclass__FrozenInstanceError(f"cannot delete field {name!r}")
|
|
2575
|
+
super(__dataclass__cls, self).__delattr__(name)
|
|
2576
|
+
|
|
2577
|
+
__delattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__delattr__"
|
|
2578
|
+
if '__delattr__' in __dataclass__cls.__dict__:
|
|
2579
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __delattr__ in class {__dataclass__cls.__name__}")
|
|
2580
|
+
setattr(__dataclass__cls, '__delattr__', __delattr__)
|
|
2581
|
+
|
|
2582
|
+
def __hash__(self):
|
|
2583
|
+
return hash((
|
|
2584
|
+
self.id,
|
|
2585
|
+
self.function,
|
|
2586
|
+
))
|
|
2587
|
+
|
|
2588
|
+
__hash__.__qualname__ = f"{__dataclass__cls.__qualname__}.__hash__"
|
|
2589
|
+
setattr(__dataclass__cls, '__hash__', __hash__)
|
|
2590
|
+
|
|
2591
|
+
def __init__(
|
|
2592
|
+
self,
|
|
2593
|
+
*,
|
|
2594
|
+
id: __dataclass__init__fields__0__annotation = __dataclass__init__fields__0__default,
|
|
2595
|
+
function: __dataclass__init__fields__1__annotation,
|
|
2596
|
+
) -> __dataclass__None:
|
|
2597
|
+
__dataclass__object_setattr(self, 'id', id)
|
|
2598
|
+
__dataclass__object_setattr(self, 'function', function)
|
|
2599
|
+
|
|
2600
|
+
__init__.__qualname__ = f"{__dataclass__cls.__qualname__}.__init__"
|
|
2601
|
+
if '__init__' in __dataclass__cls.__dict__:
|
|
2602
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __init__ in class {__dataclass__cls.__name__}")
|
|
2603
|
+
setattr(__dataclass__cls, '__init__', __init__)
|
|
2604
|
+
|
|
2605
|
+
@__dataclass___recursive_repr()
|
|
2606
|
+
def __repr__(self):
|
|
2607
|
+
parts = []
|
|
2608
|
+
parts.append(f"id={self.id!r}")
|
|
2609
|
+
parts.append(f"function={self.function!r}")
|
|
2610
|
+
return (
|
|
2611
|
+
f"{self.__class__.__qualname__}("
|
|
2612
|
+
f"{', '.join(parts)}"
|
|
2613
|
+
f")"
|
|
2614
|
+
)
|
|
2615
|
+
|
|
2616
|
+
__repr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__repr__"
|
|
2617
|
+
if '__repr__' in __dataclass__cls.__dict__:
|
|
2618
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __repr__ in class {__dataclass__cls.__name__}")
|
|
2619
|
+
setattr(__dataclass__cls, '__repr__', __repr__)
|
|
2620
|
+
|
|
2621
|
+
return _process_dataclass
|
|
2622
|
+
|
|
2623
|
+
|
|
2624
|
+
@_register(
|
|
2625
|
+
plan_repr=(
|
|
2626
|
+
"Plans(tup=(CopyPlan(fields=('name', 'arguments', 'index')), EqPlan(fields=('name', 'arguments', 'index')), Fro"
|
|
2627
|
+
"zenPlan(fields=('name', 'arguments', 'index'), allow_dynamic_dunder_attrs=False), HashPlan(action='add', field"
|
|
2628
|
+
"s=('name', 'arguments', 'index'), cache=False), InitPlan(fields=(InitPlan.Field(name='name', annotation=OpRef("
|
|
2629
|
+
"name='init.fields.0.annotation'), default=None, default_factory=None, init=True, override=False, field_type=Fi"
|
|
2630
|
+
"eldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='arguments', annotation=Op"
|
|
2631
|
+
"Ref(name='init.fields.1.annotation'), default=None, default_factory=None, init=True, override=False, field_typ"
|
|
2632
|
+
"e=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='index', annotation=Op"
|
|
2633
|
+
"Ref(name='init.fields.2.annotation'), default=OpRef(name='init.fields.2.default'), default_factory=None, init="
|
|
2634
|
+
"True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None)), self_param"
|
|
2635
|
+
"='self', std_params=(), kw_only_params=('name', 'arguments', 'index'), frozen=True, slots=False, post_init_par"
|
|
2636
|
+
"ams=None, init_fns=(), validate_fns=()), ReprPlan(fields=(ReprPlan.Field(name='name', kw_only=True, fn=None), "
|
|
2637
|
+
"ReprPlan.Field(name='arguments', kw_only=True, fn=None), ReprPlan.Field(name='index', kw_only=True, fn=None)),"
|
|
2638
|
+
" id=False, terse=False, default_fn=None)))"
|
|
2639
|
+
),
|
|
2640
|
+
plan_repr_sha1='c679b8dd972a245826381e3200fe81df0cd736c1',
|
|
2641
|
+
op_ref_idents=(
|
|
2642
|
+
'__dataclass__init__fields__0__annotation',
|
|
2643
|
+
'__dataclass__init__fields__1__annotation',
|
|
2644
|
+
'__dataclass__init__fields__2__annotation',
|
|
2645
|
+
'__dataclass__init__fields__2__default',
|
|
2646
|
+
),
|
|
2647
|
+
cls_names=(
|
|
2648
|
+
('ommlds.backends.ollama.protocol', 'Message.ToolCall.Function'),
|
|
2649
|
+
),
|
|
2650
|
+
)
|
|
2651
|
+
def _process_dataclass__c679b8dd972a245826381e3200fe81df0cd736c1():
|
|
2652
|
+
def _process_dataclass(
|
|
2653
|
+
*,
|
|
2654
|
+
__dataclass__cls,
|
|
2655
|
+
__dataclass__init__fields__0__annotation,
|
|
2656
|
+
__dataclass__init__fields__1__annotation,
|
|
2657
|
+
__dataclass__init__fields__2__annotation,
|
|
2658
|
+
__dataclass__init__fields__2__default,
|
|
2659
|
+
__dataclass__FieldFnValidationError, # noqa
|
|
2660
|
+
__dataclass__FieldTypeValidationError, # noqa
|
|
2661
|
+
__dataclass__FnValidationError, # noqa
|
|
2662
|
+
__dataclass__FrozenInstanceError=dataclasses.FrozenInstanceError, # noqa
|
|
2663
|
+
__dataclass__FunctionType=types.FunctionType, # noqa
|
|
2664
|
+
__dataclass__HAS_DEFAULT_FACTORY=dataclasses._HAS_DEFAULT_FACTORY, # noqa
|
|
2665
|
+
__dataclass__MISSING=dataclasses.MISSING, # noqa
|
|
2666
|
+
__dataclass__None=None, # noqa
|
|
2667
|
+
__dataclass__TypeError=TypeError, # noqa
|
|
2668
|
+
__dataclass___recursive_repr=reprlib.recursive_repr, # noqa
|
|
2669
|
+
__dataclass__isinstance=isinstance, # noqa
|
|
2670
|
+
__dataclass__object_setattr=object.__setattr__, # noqa
|
|
2671
|
+
__dataclass__property=property, # noqa
|
|
2672
|
+
):
|
|
2673
|
+
def __copy__(self):
|
|
2674
|
+
if self.__class__ is not __dataclass__cls:
|
|
2675
|
+
raise TypeError(self)
|
|
2676
|
+
return __dataclass__cls( # noqa
|
|
2677
|
+
name=self.name,
|
|
2678
|
+
arguments=self.arguments,
|
|
2679
|
+
index=self.index,
|
|
2680
|
+
)
|
|
2681
|
+
|
|
2682
|
+
__copy__.__qualname__ = f"{__dataclass__cls.__qualname__}.__copy__"
|
|
2683
|
+
if '__copy__' in __dataclass__cls.__dict__:
|
|
2684
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __copy__ in class {__dataclass__cls.__name__}")
|
|
2685
|
+
setattr(__dataclass__cls, '__copy__', __copy__)
|
|
2686
|
+
|
|
2687
|
+
def __eq__(self, other):
|
|
2688
|
+
if self is other:
|
|
2689
|
+
return True
|
|
2690
|
+
if self.__class__ is not other.__class__:
|
|
2691
|
+
return NotImplemented
|
|
2692
|
+
return (
|
|
2693
|
+
self.name == other.name and
|
|
2694
|
+
self.arguments == other.arguments and
|
|
2695
|
+
self.index == other.index
|
|
2696
|
+
)
|
|
2697
|
+
|
|
2698
|
+
__eq__.__qualname__ = f"{__dataclass__cls.__qualname__}.__eq__"
|
|
2699
|
+
if '__eq__' in __dataclass__cls.__dict__:
|
|
2700
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __eq__ in class {__dataclass__cls.__name__}")
|
|
2701
|
+
setattr(__dataclass__cls, '__eq__', __eq__)
|
|
2702
|
+
|
|
2703
|
+
__dataclass___setattr_frozen_fields = {
|
|
2704
|
+
'name',
|
|
2705
|
+
'arguments',
|
|
2706
|
+
'index',
|
|
2707
|
+
}
|
|
2708
|
+
|
|
2709
|
+
def __setattr__(self, name, value):
|
|
2710
|
+
if (
|
|
2711
|
+
type(self) is __dataclass__cls
|
|
2712
|
+
or name in __dataclass___setattr_frozen_fields
|
|
2713
|
+
):
|
|
2714
|
+
raise __dataclass__FrozenInstanceError(f"cannot assign to field {name!r}")
|
|
2715
|
+
super(__dataclass__cls, self).__setattr__(name, value)
|
|
2716
|
+
|
|
2717
|
+
__setattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__setattr__"
|
|
2718
|
+
if '__setattr__' in __dataclass__cls.__dict__:
|
|
2719
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __setattr__ in class {__dataclass__cls.__name__}")
|
|
2720
|
+
setattr(__dataclass__cls, '__setattr__', __setattr__)
|
|
2721
|
+
|
|
2722
|
+
__dataclass___delattr_frozen_fields = {
|
|
2723
|
+
'name',
|
|
2724
|
+
'arguments',
|
|
2725
|
+
'index',
|
|
2726
|
+
}
|
|
2727
|
+
|
|
2728
|
+
def __delattr__(self, name):
|
|
2729
|
+
if (
|
|
2730
|
+
type(self) is __dataclass__cls
|
|
2731
|
+
or name in __dataclass___delattr_frozen_fields
|
|
2732
|
+
):
|
|
2733
|
+
raise __dataclass__FrozenInstanceError(f"cannot delete field {name!r}")
|
|
2734
|
+
super(__dataclass__cls, self).__delattr__(name)
|
|
2735
|
+
|
|
2736
|
+
__delattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__delattr__"
|
|
2737
|
+
if '__delattr__' in __dataclass__cls.__dict__:
|
|
2738
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __delattr__ in class {__dataclass__cls.__name__}")
|
|
2739
|
+
setattr(__dataclass__cls, '__delattr__', __delattr__)
|
|
2740
|
+
|
|
2741
|
+
def __hash__(self):
|
|
2742
|
+
return hash((
|
|
2743
|
+
self.name,
|
|
2744
|
+
self.arguments,
|
|
2745
|
+
self.index,
|
|
2746
|
+
))
|
|
2747
|
+
|
|
2748
|
+
__hash__.__qualname__ = f"{__dataclass__cls.__qualname__}.__hash__"
|
|
2749
|
+
setattr(__dataclass__cls, '__hash__', __hash__)
|
|
2750
|
+
|
|
2751
|
+
def __init__(
|
|
2752
|
+
self,
|
|
2753
|
+
*,
|
|
2754
|
+
name: __dataclass__init__fields__0__annotation,
|
|
2755
|
+
arguments: __dataclass__init__fields__1__annotation,
|
|
2756
|
+
index: __dataclass__init__fields__2__annotation = __dataclass__init__fields__2__default,
|
|
2757
|
+
) -> __dataclass__None:
|
|
2758
|
+
__dataclass__object_setattr(self, 'name', name)
|
|
2759
|
+
__dataclass__object_setattr(self, 'arguments', arguments)
|
|
2760
|
+
__dataclass__object_setattr(self, 'index', index)
|
|
2761
|
+
|
|
2762
|
+
__init__.__qualname__ = f"{__dataclass__cls.__qualname__}.__init__"
|
|
2763
|
+
if '__init__' in __dataclass__cls.__dict__:
|
|
2764
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __init__ in class {__dataclass__cls.__name__}")
|
|
2765
|
+
setattr(__dataclass__cls, '__init__', __init__)
|
|
2766
|
+
|
|
2767
|
+
@__dataclass___recursive_repr()
|
|
2768
|
+
def __repr__(self):
|
|
2769
|
+
parts = []
|
|
2770
|
+
parts.append(f"name={self.name!r}")
|
|
2771
|
+
parts.append(f"arguments={self.arguments!r}")
|
|
2772
|
+
parts.append(f"index={self.index!r}")
|
|
2773
|
+
return (
|
|
2774
|
+
f"{self.__class__.__qualname__}("
|
|
2775
|
+
f"{', '.join(parts)}"
|
|
2776
|
+
f")"
|
|
2777
|
+
)
|
|
2778
|
+
|
|
2779
|
+
__repr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__repr__"
|
|
2780
|
+
if '__repr__' in __dataclass__cls.__dict__:
|
|
2781
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __repr__ in class {__dataclass__cls.__name__}")
|
|
2782
|
+
setattr(__dataclass__cls, '__repr__', __repr__)
|
|
2783
|
+
|
|
2784
|
+
return _process_dataclass
|
|
2785
|
+
|
|
2786
|
+
|
|
2787
|
+
@_register(
|
|
2788
|
+
plan_repr=(
|
|
2789
|
+
"Plans(tup=(CopyPlan(fields=('parent_model', 'format', 'family', 'families', 'parameter_size', 'quantization_le"
|
|
2790
|
+
"vel')), EqPlan(fields=('parent_model', 'format', 'family', 'families', 'parameter_size', 'quantization_level')"
|
|
2791
|
+
"), FrozenPlan(fields=('parent_model', 'format', 'family', 'families', 'parameter_size', 'quantization_level'),"
|
|
2792
|
+
" allow_dynamic_dunder_attrs=False), HashPlan(action='add', fields=('parent_model', 'format', 'family', 'famili"
|
|
2793
|
+
"es', 'parameter_size', 'quantization_level'), cache=False), InitPlan(fields=(InitPlan.Field(name='parent_model"
|
|
2794
|
+
"', annotation=OpRef(name='init.fields.0.annotation'), default=None, default_factory=None, init=True, override="
|
|
2795
|
+
"False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='forma"
|
|
2796
|
+
"t', annotation=OpRef(name='init.fields.1.annotation'), default=None, default_factory=None, init=True, override"
|
|
2797
|
+
"=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='fami"
|
|
2798
|
+
"ly', annotation=OpRef(name='init.fields.2.annotation'), default=None, default_factory=None, init=True, overrid"
|
|
2799
|
+
"e=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='fam"
|
|
2800
|
+
"ilies', annotation=OpRef(name='init.fields.3.annotation'), default=None, default_factory=None, init=True, over"
|
|
2801
|
+
"ride=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='"
|
|
2802
|
+
"parameter_size', annotation=OpRef(name='init.fields.4.annotation'), default=None, default_factory=None, init=T"
|
|
2803
|
+
"rue, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Fie"
|
|
2804
|
+
"ld(name='quantization_level', annotation=OpRef(name='init.fields.5.annotation'), default=None, default_factory"
|
|
2805
|
+
"=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None))"
|
|
2806
|
+
", self_param='self', std_params=(), kw_only_params=('parent_model', 'format', 'family', 'families', 'parameter"
|
|
2807
|
+
"_size', 'quantization_level'), frozen=True, slots=False, post_init_params=None, init_fns=(), validate_fns=()),"
|
|
2808
|
+
" ReprPlan(fields=(ReprPlan.Field(name='parent_model', kw_only=True, fn=None), ReprPlan.Field(name='format', kw"
|
|
2809
|
+
"_only=True, fn=None), ReprPlan.Field(name='family', kw_only=True, fn=None), ReprPlan.Field(name='families', kw"
|
|
2810
|
+
"_only=True, fn=None), ReprPlan.Field(name='parameter_size', kw_only=True, fn=None), ReprPlan.Field(name='quant"
|
|
2811
|
+
"ization_level', kw_only=True, fn=None)), id=False, terse=False, default_fn=OpRef(name='repr.default_fn'))))"
|
|
2812
|
+
),
|
|
2813
|
+
plan_repr_sha1='6d086e850feb59746e721b8edda1c8a1d7256381',
|
|
2814
|
+
op_ref_idents=(
|
|
2815
|
+
'__dataclass__init__fields__0__annotation',
|
|
2816
|
+
'__dataclass__init__fields__1__annotation',
|
|
2817
|
+
'__dataclass__init__fields__2__annotation',
|
|
2818
|
+
'__dataclass__init__fields__3__annotation',
|
|
2819
|
+
'__dataclass__init__fields__4__annotation',
|
|
2820
|
+
'__dataclass__init__fields__5__annotation',
|
|
2821
|
+
'__dataclass__repr__default_fn',
|
|
2822
|
+
),
|
|
2823
|
+
cls_names=(
|
|
2824
|
+
('ommlds.backends.ollama.protocol', 'ModelDetails'),
|
|
2825
|
+
),
|
|
2826
|
+
)
|
|
2827
|
+
def _process_dataclass__6d086e850feb59746e721b8edda1c8a1d7256381():
|
|
2828
|
+
def _process_dataclass(
|
|
2829
|
+
*,
|
|
2830
|
+
__dataclass__cls,
|
|
2831
|
+
__dataclass__init__fields__0__annotation,
|
|
2832
|
+
__dataclass__init__fields__1__annotation,
|
|
2833
|
+
__dataclass__init__fields__2__annotation,
|
|
2834
|
+
__dataclass__init__fields__3__annotation,
|
|
2835
|
+
__dataclass__init__fields__4__annotation,
|
|
2836
|
+
__dataclass__init__fields__5__annotation,
|
|
2837
|
+
__dataclass__repr__default_fn,
|
|
2838
|
+
__dataclass__FieldFnValidationError, # noqa
|
|
2839
|
+
__dataclass__FieldTypeValidationError, # noqa
|
|
2840
|
+
__dataclass__FnValidationError, # noqa
|
|
2841
|
+
__dataclass__FrozenInstanceError=dataclasses.FrozenInstanceError, # noqa
|
|
2842
|
+
__dataclass__FunctionType=types.FunctionType, # noqa
|
|
2843
|
+
__dataclass__HAS_DEFAULT_FACTORY=dataclasses._HAS_DEFAULT_FACTORY, # noqa
|
|
2844
|
+
__dataclass__MISSING=dataclasses.MISSING, # noqa
|
|
2845
|
+
__dataclass__None=None, # noqa
|
|
2846
|
+
__dataclass__TypeError=TypeError, # noqa
|
|
2847
|
+
__dataclass___recursive_repr=reprlib.recursive_repr, # noqa
|
|
2848
|
+
__dataclass__isinstance=isinstance, # noqa
|
|
2849
|
+
__dataclass__object_setattr=object.__setattr__, # noqa
|
|
2850
|
+
__dataclass__property=property, # noqa
|
|
2851
|
+
):
|
|
2852
|
+
def __copy__(self):
|
|
2853
|
+
if self.__class__ is not __dataclass__cls:
|
|
2854
|
+
raise TypeError(self)
|
|
2855
|
+
return __dataclass__cls( # noqa
|
|
2856
|
+
parent_model=self.parent_model,
|
|
2857
|
+
format=self.format,
|
|
2858
|
+
family=self.family,
|
|
2859
|
+
families=self.families,
|
|
2860
|
+
parameter_size=self.parameter_size,
|
|
2861
|
+
quantization_level=self.quantization_level,
|
|
2862
|
+
)
|
|
2863
|
+
|
|
2864
|
+
__copy__.__qualname__ = f"{__dataclass__cls.__qualname__}.__copy__"
|
|
2865
|
+
if '__copy__' in __dataclass__cls.__dict__:
|
|
2866
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __copy__ in class {__dataclass__cls.__name__}")
|
|
2867
|
+
setattr(__dataclass__cls, '__copy__', __copy__)
|
|
2868
|
+
|
|
2869
|
+
def __eq__(self, other):
|
|
2870
|
+
if self is other:
|
|
2871
|
+
return True
|
|
2872
|
+
if self.__class__ is not other.__class__:
|
|
2873
|
+
return NotImplemented
|
|
2874
|
+
return (
|
|
2875
|
+
self.parent_model == other.parent_model and
|
|
2876
|
+
self.format == other.format and
|
|
2877
|
+
self.family == other.family and
|
|
2878
|
+
self.families == other.families and
|
|
2879
|
+
self.parameter_size == other.parameter_size and
|
|
2880
|
+
self.quantization_level == other.quantization_level
|
|
2881
|
+
)
|
|
2882
|
+
|
|
2883
|
+
__eq__.__qualname__ = f"{__dataclass__cls.__qualname__}.__eq__"
|
|
2884
|
+
if '__eq__' in __dataclass__cls.__dict__:
|
|
2885
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __eq__ in class {__dataclass__cls.__name__}")
|
|
2886
|
+
setattr(__dataclass__cls, '__eq__', __eq__)
|
|
2887
|
+
|
|
2888
|
+
__dataclass___setattr_frozen_fields = {
|
|
2889
|
+
'parent_model',
|
|
2890
|
+
'format',
|
|
2891
|
+
'family',
|
|
2892
|
+
'families',
|
|
2893
|
+
'parameter_size',
|
|
2894
|
+
'quantization_level',
|
|
2895
|
+
}
|
|
2896
|
+
|
|
2897
|
+
def __setattr__(self, name, value):
|
|
2898
|
+
if (
|
|
2899
|
+
type(self) is __dataclass__cls
|
|
2900
|
+
or name in __dataclass___setattr_frozen_fields
|
|
2901
|
+
):
|
|
2902
|
+
raise __dataclass__FrozenInstanceError(f"cannot assign to field {name!r}")
|
|
2903
|
+
super(__dataclass__cls, self).__setattr__(name, value)
|
|
2904
|
+
|
|
2905
|
+
__setattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__setattr__"
|
|
2906
|
+
if '__setattr__' in __dataclass__cls.__dict__:
|
|
2907
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __setattr__ in class {__dataclass__cls.__name__}")
|
|
2908
|
+
setattr(__dataclass__cls, '__setattr__', __setattr__)
|
|
2909
|
+
|
|
2910
|
+
__dataclass___delattr_frozen_fields = {
|
|
2911
|
+
'parent_model',
|
|
2912
|
+
'format',
|
|
2913
|
+
'family',
|
|
2914
|
+
'families',
|
|
2915
|
+
'parameter_size',
|
|
2916
|
+
'quantization_level',
|
|
2917
|
+
}
|
|
2918
|
+
|
|
2919
|
+
def __delattr__(self, name):
|
|
2920
|
+
if (
|
|
2921
|
+
type(self) is __dataclass__cls
|
|
2922
|
+
or name in __dataclass___delattr_frozen_fields
|
|
2923
|
+
):
|
|
2924
|
+
raise __dataclass__FrozenInstanceError(f"cannot delete field {name!r}")
|
|
2925
|
+
super(__dataclass__cls, self).__delattr__(name)
|
|
2926
|
+
|
|
2927
|
+
__delattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__delattr__"
|
|
2928
|
+
if '__delattr__' in __dataclass__cls.__dict__:
|
|
2929
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __delattr__ in class {__dataclass__cls.__name__}")
|
|
2930
|
+
setattr(__dataclass__cls, '__delattr__', __delattr__)
|
|
2931
|
+
|
|
2932
|
+
def __hash__(self):
|
|
2933
|
+
return hash((
|
|
2934
|
+
self.parent_model,
|
|
2935
|
+
self.format,
|
|
2936
|
+
self.family,
|
|
2937
|
+
self.families,
|
|
2938
|
+
self.parameter_size,
|
|
2939
|
+
self.quantization_level,
|
|
2940
|
+
))
|
|
2941
|
+
|
|
2942
|
+
__hash__.__qualname__ = f"{__dataclass__cls.__qualname__}.__hash__"
|
|
2943
|
+
setattr(__dataclass__cls, '__hash__', __hash__)
|
|
2944
|
+
|
|
2945
|
+
def __init__(
|
|
2946
|
+
self,
|
|
2947
|
+
*,
|
|
2948
|
+
parent_model: __dataclass__init__fields__0__annotation,
|
|
2949
|
+
format: __dataclass__init__fields__1__annotation,
|
|
2950
|
+
family: __dataclass__init__fields__2__annotation,
|
|
2951
|
+
families: __dataclass__init__fields__3__annotation,
|
|
2952
|
+
parameter_size: __dataclass__init__fields__4__annotation,
|
|
2953
|
+
quantization_level: __dataclass__init__fields__5__annotation,
|
|
2954
|
+
) -> __dataclass__None:
|
|
2955
|
+
__dataclass__object_setattr(self, 'parent_model', parent_model)
|
|
2956
|
+
__dataclass__object_setattr(self, 'format', format)
|
|
2957
|
+
__dataclass__object_setattr(self, 'family', family)
|
|
2958
|
+
__dataclass__object_setattr(self, 'families', families)
|
|
2959
|
+
__dataclass__object_setattr(self, 'parameter_size', parameter_size)
|
|
2960
|
+
__dataclass__object_setattr(self, 'quantization_level', quantization_level)
|
|
2961
|
+
|
|
2962
|
+
__init__.__qualname__ = f"{__dataclass__cls.__qualname__}.__init__"
|
|
2963
|
+
if '__init__' in __dataclass__cls.__dict__:
|
|
2964
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __init__ in class {__dataclass__cls.__name__}")
|
|
2965
|
+
setattr(__dataclass__cls, '__init__', __init__)
|
|
2966
|
+
|
|
2967
|
+
@__dataclass___recursive_repr()
|
|
2968
|
+
def __repr__(self):
|
|
2969
|
+
parts = []
|
|
2970
|
+
if (s := __dataclass__repr__default_fn(self.parent_model)) is not None:
|
|
2971
|
+
parts.append(f"parent_model={s}")
|
|
2972
|
+
if (s := __dataclass__repr__default_fn(self.format)) is not None:
|
|
2973
|
+
parts.append(f"format={s}")
|
|
2974
|
+
if (s := __dataclass__repr__default_fn(self.family)) is not None:
|
|
2975
|
+
parts.append(f"family={s}")
|
|
2976
|
+
if (s := __dataclass__repr__default_fn(self.families)) is not None:
|
|
2977
|
+
parts.append(f"families={s}")
|
|
2978
|
+
if (s := __dataclass__repr__default_fn(self.parameter_size)) is not None:
|
|
2979
|
+
parts.append(f"parameter_size={s}")
|
|
2980
|
+
if (s := __dataclass__repr__default_fn(self.quantization_level)) is not None:
|
|
2981
|
+
parts.append(f"quantization_level={s}")
|
|
2982
|
+
return (
|
|
2983
|
+
f"{self.__class__.__qualname__}("
|
|
2984
|
+
f"{', '.join(parts)}"
|
|
2985
|
+
f")"
|
|
2986
|
+
)
|
|
2987
|
+
|
|
2988
|
+
__repr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__repr__"
|
|
2989
|
+
if '__repr__' in __dataclass__cls.__dict__:
|
|
2990
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __repr__ in class {__dataclass__cls.__name__}")
|
|
2991
|
+
setattr(__dataclass__cls, '__repr__', __repr__)
|
|
2992
|
+
|
|
2993
|
+
return _process_dataclass
|
|
2994
|
+
|
|
2995
|
+
|
|
2996
|
+
@_register(
|
|
2997
|
+
plan_repr=(
|
|
2998
|
+
"Plans(tup=(CopyPlan(fields=('numa', 'num_ctx', 'num_batch', 'num_gpu', 'main_gpu', 'low_vram', 'f16_kv', 'logi"
|
|
2999
|
+
"ts_all', 'vocab_only', 'use_mmap', 'use_mlock', 'embedding_only', 'num_thread', 'num_keep', 'seed', 'num_predi"
|
|
3000
|
+
"ct', 'top_k', 'top_p', 'tfs_z', 'typical_p', 'repeat_last_n', 'temperature', 'repeat_penalty', 'presence_penal"
|
|
3001
|
+
"ty', 'frequency_penalty', 'mirostat', 'mirostat_tau', 'mirostat_eta', 'penalize_newline', 'stop')), EqPlan(fie"
|
|
3002
|
+
"lds=('numa', 'num_ctx', 'num_batch', 'num_gpu', 'main_gpu', 'low_vram', 'f16_kv', 'logits_all', 'vocab_only', "
|
|
3003
|
+
"'use_mmap', 'use_mlock', 'embedding_only', 'num_thread', 'num_keep', 'seed', 'num_predict', 'top_k', 'top_p', "
|
|
3004
|
+
"'tfs_z', 'typical_p', 'repeat_last_n', 'temperature', 'repeat_penalty', 'presence_penalty', 'frequency_penalty"
|
|
3005
|
+
"', 'mirostat', 'mirostat_tau', 'mirostat_eta', 'penalize_newline', 'stop')), FrozenPlan(fields=('numa', 'num_c"
|
|
3006
|
+
"tx', 'num_batch', 'num_gpu', 'main_gpu', 'low_vram', 'f16_kv', 'logits_all', 'vocab_only', 'use_mmap', 'use_ml"
|
|
3007
|
+
"ock', 'embedding_only', 'num_thread', 'num_keep', 'seed', 'num_predict', 'top_k', 'top_p', 'tfs_z', 'typical_p"
|
|
3008
|
+
"', 'repeat_last_n', 'temperature', 'repeat_penalty', 'presence_penalty', 'frequency_penalty', 'mirostat', 'mir"
|
|
3009
|
+
"ostat_tau', 'mirostat_eta', 'penalize_newline', 'stop'), allow_dynamic_dunder_attrs=False), HashPlan(action='a"
|
|
3010
|
+
"dd', fields=('numa', 'num_ctx', 'num_batch', 'num_gpu', 'main_gpu', 'low_vram', 'f16_kv', 'logits_all', 'vocab"
|
|
3011
|
+
"_only', 'use_mmap', 'use_mlock', 'embedding_only', 'num_thread', 'num_keep', 'seed', 'num_predict', 'top_k', '"
|
|
3012
|
+
"top_p', 'tfs_z', 'typical_p', 'repeat_last_n', 'temperature', 'repeat_penalty', 'presence_penalty', 'frequency"
|
|
3013
|
+
"_penalty', 'mirostat', 'mirostat_tau', 'mirostat_eta', 'penalize_newline', 'stop'), cache=False), InitPlan(fie"
|
|
3014
|
+
"lds=(InitPlan.Field(name='numa', annotation=OpRef(name='init.fields.0.annotation'), default=OpRef(name='init.f"
|
|
3015
|
+
"ields.0.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None"
|
|
3016
|
+
", validate=None, check_type=None), InitPlan.Field(name='num_ctx', annotation=OpRef(name='init.fields.1.annotat"
|
|
3017
|
+
"ion'), default=OpRef(name='init.fields.1.default'), default_factory=None, init=True, override=False, field_typ"
|
|
3018
|
+
"e=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='num_batch', annotatio"
|
|
3019
|
+
"n=OpRef(name='init.fields.2.annotation'), default=OpRef(name='init.fields.2.default'), default_factory=None, i"
|
|
3020
|
+
"nit=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPla"
|
|
3021
|
+
"n.Field(name='num_gpu', annotation=OpRef(name='init.fields.3.annotation'), default=OpRef(name='init.fields.3.d"
|
|
3022
|
+
"efault'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validat"
|
|
3023
|
+
"e=None, check_type=None), InitPlan.Field(name='main_gpu', annotation=OpRef(name='init.fields.4.annotation'), d"
|
|
3024
|
+
"efault=OpRef(name='init.fields.4.default'), default_factory=None, init=True, override=False, field_type=FieldT"
|
|
3025
|
+
"ype.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='low_vram', annotation=OpRef(n"
|
|
3026
|
+
"ame='init.fields.5.annotation'), default=OpRef(name='init.fields.5.default'), default_factory=None, init=True,"
|
|
3027
|
+
" override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(n"
|
|
3028
|
+
"ame='f16_kv', annotation=OpRef(name='init.fields.6.annotation'), default=OpRef(name='init.fields.6.default'), "
|
|
3029
|
+
"default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, ch"
|
|
3030
|
+
"eck_type=None), InitPlan.Field(name='logits_all', annotation=OpRef(name='init.fields.7.annotation'), default=O"
|
|
3031
|
+
"pRef(name='init.fields.7.default'), default_factory=None, init=True, override=False, field_type=FieldType.INST"
|
|
3032
|
+
"ANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='vocab_only', annotation=OpRef(name='i"
|
|
3033
|
+
"nit.fields.8.annotation'), default=OpRef(name='init.fields.8.default'), default_factory=None, init=True, overr"
|
|
3034
|
+
"ide=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='u"
|
|
3035
|
+
"se_mmap', annotation=OpRef(name='init.fields.9.annotation'), default=OpRef(name='init.fields.9.default'), defa"
|
|
3036
|
+
"ult_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_"
|
|
3037
|
+
"type=None), InitPlan.Field(name='use_mlock', annotation=OpRef(name='init.fields.10.annotation'), default=OpRef"
|
|
3038
|
+
"(name='init.fields.10.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANC"
|
|
3039
|
+
"E, coerce=None, validate=None, check_type=None), InitPlan.Field(name='embedding_only', annotation=OpRef(name='"
|
|
3040
|
+
"init.fields.11.annotation'), default=OpRef(name='init.fields.11.default'), default_factory=None, init=True, ov"
|
|
3041
|
+
"erride=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name"
|
|
3042
|
+
"='num_thread', annotation=OpRef(name='init.fields.12.annotation'), default=OpRef(name='init.fields.12.default'"
|
|
3043
|
+
"), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None,"
|
|
3044
|
+
" check_type=None), InitPlan.Field(name='num_keep', annotation=OpRef(name='init.fields.13.annotation'), default"
|
|
3045
|
+
"=OpRef(name='init.fields.13.default'), default_factory=None, init=True, override=False, field_type=FieldType.I"
|
|
3046
|
+
"NSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='seed', annotation=OpRef(name='init"
|
|
3047
|
+
".fields.14.annotation'), default=OpRef(name='init.fields.14.default'), default_factory=None, init=True, overri"
|
|
3048
|
+
"de=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='nu"
|
|
3049
|
+
"m_predict', annotation=OpRef(name='init.fields.15.annotation'), default=OpRef(name='init.fields.15.default'), "
|
|
3050
|
+
"default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, ch"
|
|
3051
|
+
"eck_type=None), InitPlan.Field(name='top_k', annotation=OpRef(name='init.fields.16.annotation'), default=OpRef"
|
|
3052
|
+
"(name='init.fields.16.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANC"
|
|
3053
|
+
"E, coerce=None, validate=None, check_type=None), InitPlan.Field(name='top_p', annotation=OpRef(name='init.fiel"
|
|
3054
|
+
"ds.17.annotation'), default=OpRef(name='init.fields.17.default'), default_factory=None, init=True, override=Fa"
|
|
3055
|
+
"lse, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='tfs_z',"
|
|
3056
|
+
" annotation=OpRef(name='init.fields.18.annotation'), default=OpRef(name='init.fields.18.default'), default_fac"
|
|
3057
|
+
"tory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=No"
|
|
3058
|
+
"ne), InitPlan.Field(name='typical_p', annotation=OpRef(name='init.fields.19.annotation'), default=OpRef(name='"
|
|
3059
|
+
"init.fields.19.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coer"
|
|
3060
|
+
"ce=None, validate=None, check_type=None), InitPlan.Field(name='repeat_last_n', annotation=OpRef(name='init.fie"
|
|
3061
|
+
"lds.20.annotation'), default=OpRef(name='init.fields.20.default'), default_factory=None, init=True, override=F"
|
|
3062
|
+
"alse, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='temper"
|
|
3063
|
+
"ature', annotation=OpRef(name='init.fields.21.annotation'), default=OpRef(name='init.fields.21.default'), defa"
|
|
3064
|
+
"ult_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_"
|
|
3065
|
+
"type=None), InitPlan.Field(name='repeat_penalty', annotation=OpRef(name='init.fields.22.annotation'), default="
|
|
3066
|
+
"OpRef(name='init.fields.22.default'), default_factory=None, init=True, override=False, field_type=FieldType.IN"
|
|
3067
|
+
"STANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='presence_penalty', annotation=OpRef"
|
|
3068
|
+
"(name='init.fields.23.annotation'), default=OpRef(name='init.fields.23.default'), default_factory=None, init=T"
|
|
3069
|
+
"rue, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Fie"
|
|
3070
|
+
"ld(name='frequency_penalty', annotation=OpRef(name='init.fields.24.annotation'), default=OpRef(name='init.fiel"
|
|
3071
|
+
"ds.24.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, "
|
|
3072
|
+
"validate=None, check_type=None), InitPlan.Field(name='mirostat', annotation=OpRef(name='init.fields.25.annotat"
|
|
3073
|
+
"ion'), default=OpRef(name='init.fields.25.default'), default_factory=None, init=True, override=False, field_ty"
|
|
3074
|
+
"pe=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='mirostat_tau', annot"
|
|
3075
|
+
"ation=OpRef(name='init.fields.26.annotation'), default=OpRef(name='init.fields.26.default'), default_factory=N"
|
|
3076
|
+
"one, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), I"
|
|
3077
|
+
"nitPlan.Field(name='mirostat_eta', annotation=OpRef(name='init.fields.27.annotation'), default=OpRef(name='ini"
|
|
3078
|
+
"t.fields.27.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce="
|
|
3079
|
+
"None, validate=None, check_type=None), InitPlan.Field(name='penalize_newline', annotation=OpRef(name='init.fie"
|
|
3080
|
+
"lds.28.annotation'), default=OpRef(name='init.fields.28.default'), default_factory=None, init=True, override=F"
|
|
3081
|
+
"alse, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='stop',"
|
|
3082
|
+
" annotation=OpRef(name='init.fields.29.annotation'), default=OpRef(name='init.fields.29.default'), default_fac"
|
|
3083
|
+
"tory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=No"
|
|
3084
|
+
"ne)), self_param='self', std_params=(), kw_only_params=('numa', 'num_ctx', 'num_batch', 'num_gpu', 'main_gpu',"
|
|
3085
|
+
" 'low_vram', 'f16_kv', 'logits_all', 'vocab_only', 'use_mmap', 'use_mlock', 'embedding_only', 'num_thread', 'n"
|
|
3086
|
+
"um_keep', 'seed', 'num_predict', 'top_k', 'top_p', 'tfs_z', 'typical_p', 'repeat_last_n', 'temperature', 'repe"
|
|
3087
|
+
"at_penalty', 'presence_penalty', 'frequency_penalty', 'mirostat', 'mirostat_tau', 'mirostat_eta', 'penalize_ne"
|
|
3088
|
+
"wline', 'stop'), frozen=True, slots=False, post_init_params=None, init_fns=(), validate_fns=()), ReprPlan(fiel"
|
|
3089
|
+
"ds=(ReprPlan.Field(name='numa', kw_only=True, fn=None), ReprPlan.Field(name='num_ctx', kw_only=True, fn=None),"
|
|
3090
|
+
" ReprPlan.Field(name='num_batch', kw_only=True, fn=None), ReprPlan.Field(name='num_gpu', kw_only=True, fn=None"
|
|
3091
|
+
"), ReprPlan.Field(name='main_gpu', kw_only=True, fn=None), ReprPlan.Field(name='low_vram', kw_only=True, fn=No"
|
|
3092
|
+
"ne), ReprPlan.Field(name='f16_kv', kw_only=True, fn=None), ReprPlan.Field(name='logits_all', kw_only=True, fn="
|
|
3093
|
+
"None), ReprPlan.Field(name='vocab_only', kw_only=True, fn=None), ReprPlan.Field(name='use_mmap', kw_only=True,"
|
|
3094
|
+
" fn=None), ReprPlan.Field(name='use_mlock', kw_only=True, fn=None), ReprPlan.Field(name='embedding_only', kw_o"
|
|
3095
|
+
"nly=True, fn=None), ReprPlan.Field(name='num_thread', kw_only=True, fn=None), ReprPlan.Field(name='num_keep', "
|
|
3096
|
+
"kw_only=True, fn=None), ReprPlan.Field(name='seed', kw_only=True, fn=None), ReprPlan.Field(name='num_predict',"
|
|
3097
|
+
" kw_only=True, fn=None), ReprPlan.Field(name='top_k', kw_only=True, fn=None), ReprPlan.Field(name='top_p', kw_"
|
|
3098
|
+
"only=True, fn=None), ReprPlan.Field(name='tfs_z', kw_only=True, fn=None), ReprPlan.Field(name='typical_p', kw_"
|
|
3099
|
+
"only=True, fn=None), ReprPlan.Field(name='repeat_last_n', kw_only=True, fn=None), ReprPlan.Field(name='tempera"
|
|
3100
|
+
"ture', kw_only=True, fn=None), ReprPlan.Field(name='repeat_penalty', kw_only=True, fn=None), ReprPlan.Field(na"
|
|
3101
|
+
"me='presence_penalty', kw_only=True, fn=None), ReprPlan.Field(name='frequency_penalty', kw_only=True, fn=None)"
|
|
3102
|
+
", ReprPlan.Field(name='mirostat', kw_only=True, fn=None), ReprPlan.Field(name='mirostat_tau', kw_only=True, fn"
|
|
3103
|
+
"=None), ReprPlan.Field(name='mirostat_eta', kw_only=True, fn=None), ReprPlan.Field(name='penalize_newline', kw"
|
|
3104
|
+
"_only=True, fn=None), ReprPlan.Field(name='stop', kw_only=True, fn=None)), id=False, terse=False, default_fn=O"
|
|
3105
|
+
"pRef(name='repr.default_fn'))))"
|
|
3106
|
+
),
|
|
3107
|
+
plan_repr_sha1='ee676a855d03365888791d5b18db34dc1c6d5e77',
|
|
3108
|
+
op_ref_idents=(
|
|
3109
|
+
'__dataclass__init__fields__0__annotation',
|
|
3110
|
+
'__dataclass__init__fields__0__default',
|
|
3111
|
+
'__dataclass__init__fields__10__annotation',
|
|
3112
|
+
'__dataclass__init__fields__10__default',
|
|
3113
|
+
'__dataclass__init__fields__11__annotation',
|
|
3114
|
+
'__dataclass__init__fields__11__default',
|
|
3115
|
+
'__dataclass__init__fields__12__annotation',
|
|
3116
|
+
'__dataclass__init__fields__12__default',
|
|
3117
|
+
'__dataclass__init__fields__13__annotation',
|
|
3118
|
+
'__dataclass__init__fields__13__default',
|
|
3119
|
+
'__dataclass__init__fields__14__annotation',
|
|
3120
|
+
'__dataclass__init__fields__14__default',
|
|
3121
|
+
'__dataclass__init__fields__15__annotation',
|
|
3122
|
+
'__dataclass__init__fields__15__default',
|
|
3123
|
+
'__dataclass__init__fields__16__annotation',
|
|
3124
|
+
'__dataclass__init__fields__16__default',
|
|
3125
|
+
'__dataclass__init__fields__17__annotation',
|
|
3126
|
+
'__dataclass__init__fields__17__default',
|
|
3127
|
+
'__dataclass__init__fields__18__annotation',
|
|
3128
|
+
'__dataclass__init__fields__18__default',
|
|
3129
|
+
'__dataclass__init__fields__19__annotation',
|
|
3130
|
+
'__dataclass__init__fields__19__default',
|
|
3131
|
+
'__dataclass__init__fields__1__annotation',
|
|
3132
|
+
'__dataclass__init__fields__1__default',
|
|
3133
|
+
'__dataclass__init__fields__20__annotation',
|
|
3134
|
+
'__dataclass__init__fields__20__default',
|
|
3135
|
+
'__dataclass__init__fields__21__annotation',
|
|
3136
|
+
'__dataclass__init__fields__21__default',
|
|
3137
|
+
'__dataclass__init__fields__22__annotation',
|
|
3138
|
+
'__dataclass__init__fields__22__default',
|
|
3139
|
+
'__dataclass__init__fields__23__annotation',
|
|
3140
|
+
'__dataclass__init__fields__23__default',
|
|
3141
|
+
'__dataclass__init__fields__24__annotation',
|
|
3142
|
+
'__dataclass__init__fields__24__default',
|
|
3143
|
+
'__dataclass__init__fields__25__annotation',
|
|
3144
|
+
'__dataclass__init__fields__25__default',
|
|
3145
|
+
'__dataclass__init__fields__26__annotation',
|
|
3146
|
+
'__dataclass__init__fields__26__default',
|
|
3147
|
+
'__dataclass__init__fields__27__annotation',
|
|
3148
|
+
'__dataclass__init__fields__27__default',
|
|
3149
|
+
'__dataclass__init__fields__28__annotation',
|
|
3150
|
+
'__dataclass__init__fields__28__default',
|
|
3151
|
+
'__dataclass__init__fields__29__annotation',
|
|
3152
|
+
'__dataclass__init__fields__29__default',
|
|
3153
|
+
'__dataclass__init__fields__2__annotation',
|
|
3154
|
+
'__dataclass__init__fields__2__default',
|
|
3155
|
+
'__dataclass__init__fields__3__annotation',
|
|
3156
|
+
'__dataclass__init__fields__3__default',
|
|
3157
|
+
'__dataclass__init__fields__4__annotation',
|
|
3158
|
+
'__dataclass__init__fields__4__default',
|
|
3159
|
+
'__dataclass__init__fields__5__annotation',
|
|
3160
|
+
'__dataclass__init__fields__5__default',
|
|
3161
|
+
'__dataclass__init__fields__6__annotation',
|
|
3162
|
+
'__dataclass__init__fields__6__default',
|
|
3163
|
+
'__dataclass__init__fields__7__annotation',
|
|
3164
|
+
'__dataclass__init__fields__7__default',
|
|
3165
|
+
'__dataclass__init__fields__8__annotation',
|
|
3166
|
+
'__dataclass__init__fields__8__default',
|
|
3167
|
+
'__dataclass__init__fields__9__annotation',
|
|
3168
|
+
'__dataclass__init__fields__9__default',
|
|
3169
|
+
'__dataclass__repr__default_fn',
|
|
3170
|
+
),
|
|
3171
|
+
cls_names=(
|
|
3172
|
+
('ommlds.backends.ollama.protocol', 'Options'),
|
|
3173
|
+
),
|
|
3174
|
+
)
|
|
3175
|
+
def _process_dataclass__ee676a855d03365888791d5b18db34dc1c6d5e77():
|
|
3176
|
+
def _process_dataclass(
|
|
3177
|
+
*,
|
|
3178
|
+
__dataclass__cls,
|
|
3179
|
+
__dataclass__init__fields__0__annotation,
|
|
3180
|
+
__dataclass__init__fields__0__default,
|
|
3181
|
+
__dataclass__init__fields__10__annotation,
|
|
3182
|
+
__dataclass__init__fields__10__default,
|
|
3183
|
+
__dataclass__init__fields__11__annotation,
|
|
3184
|
+
__dataclass__init__fields__11__default,
|
|
3185
|
+
__dataclass__init__fields__12__annotation,
|
|
3186
|
+
__dataclass__init__fields__12__default,
|
|
3187
|
+
__dataclass__init__fields__13__annotation,
|
|
3188
|
+
__dataclass__init__fields__13__default,
|
|
3189
|
+
__dataclass__init__fields__14__annotation,
|
|
3190
|
+
__dataclass__init__fields__14__default,
|
|
3191
|
+
__dataclass__init__fields__15__annotation,
|
|
3192
|
+
__dataclass__init__fields__15__default,
|
|
3193
|
+
__dataclass__init__fields__16__annotation,
|
|
3194
|
+
__dataclass__init__fields__16__default,
|
|
3195
|
+
__dataclass__init__fields__17__annotation,
|
|
3196
|
+
__dataclass__init__fields__17__default,
|
|
3197
|
+
__dataclass__init__fields__18__annotation,
|
|
3198
|
+
__dataclass__init__fields__18__default,
|
|
3199
|
+
__dataclass__init__fields__19__annotation,
|
|
3200
|
+
__dataclass__init__fields__19__default,
|
|
3201
|
+
__dataclass__init__fields__1__annotation,
|
|
3202
|
+
__dataclass__init__fields__1__default,
|
|
3203
|
+
__dataclass__init__fields__20__annotation,
|
|
3204
|
+
__dataclass__init__fields__20__default,
|
|
3205
|
+
__dataclass__init__fields__21__annotation,
|
|
3206
|
+
__dataclass__init__fields__21__default,
|
|
3207
|
+
__dataclass__init__fields__22__annotation,
|
|
3208
|
+
__dataclass__init__fields__22__default,
|
|
3209
|
+
__dataclass__init__fields__23__annotation,
|
|
3210
|
+
__dataclass__init__fields__23__default,
|
|
3211
|
+
__dataclass__init__fields__24__annotation,
|
|
3212
|
+
__dataclass__init__fields__24__default,
|
|
3213
|
+
__dataclass__init__fields__25__annotation,
|
|
3214
|
+
__dataclass__init__fields__25__default,
|
|
3215
|
+
__dataclass__init__fields__26__annotation,
|
|
3216
|
+
__dataclass__init__fields__26__default,
|
|
3217
|
+
__dataclass__init__fields__27__annotation,
|
|
3218
|
+
__dataclass__init__fields__27__default,
|
|
3219
|
+
__dataclass__init__fields__28__annotation,
|
|
3220
|
+
__dataclass__init__fields__28__default,
|
|
3221
|
+
__dataclass__init__fields__29__annotation,
|
|
3222
|
+
__dataclass__init__fields__29__default,
|
|
3223
|
+
__dataclass__init__fields__2__annotation,
|
|
3224
|
+
__dataclass__init__fields__2__default,
|
|
3225
|
+
__dataclass__init__fields__3__annotation,
|
|
3226
|
+
__dataclass__init__fields__3__default,
|
|
3227
|
+
__dataclass__init__fields__4__annotation,
|
|
3228
|
+
__dataclass__init__fields__4__default,
|
|
3229
|
+
__dataclass__init__fields__5__annotation,
|
|
3230
|
+
__dataclass__init__fields__5__default,
|
|
3231
|
+
__dataclass__init__fields__6__annotation,
|
|
3232
|
+
__dataclass__init__fields__6__default,
|
|
3233
|
+
__dataclass__init__fields__7__annotation,
|
|
3234
|
+
__dataclass__init__fields__7__default,
|
|
3235
|
+
__dataclass__init__fields__8__annotation,
|
|
3236
|
+
__dataclass__init__fields__8__default,
|
|
3237
|
+
__dataclass__init__fields__9__annotation,
|
|
3238
|
+
__dataclass__init__fields__9__default,
|
|
3239
|
+
__dataclass__repr__default_fn,
|
|
3240
|
+
__dataclass__FieldFnValidationError, # noqa
|
|
3241
|
+
__dataclass__FieldTypeValidationError, # noqa
|
|
3242
|
+
__dataclass__FnValidationError, # noqa
|
|
3243
|
+
__dataclass__FrozenInstanceError=dataclasses.FrozenInstanceError, # noqa
|
|
3244
|
+
__dataclass__FunctionType=types.FunctionType, # noqa
|
|
3245
|
+
__dataclass__HAS_DEFAULT_FACTORY=dataclasses._HAS_DEFAULT_FACTORY, # noqa
|
|
3246
|
+
__dataclass__MISSING=dataclasses.MISSING, # noqa
|
|
3247
|
+
__dataclass__None=None, # noqa
|
|
3248
|
+
__dataclass__TypeError=TypeError, # noqa
|
|
3249
|
+
__dataclass___recursive_repr=reprlib.recursive_repr, # noqa
|
|
3250
|
+
__dataclass__isinstance=isinstance, # noqa
|
|
3251
|
+
__dataclass__object_setattr=object.__setattr__, # noqa
|
|
3252
|
+
__dataclass__property=property, # noqa
|
|
3253
|
+
):
|
|
3254
|
+
def __copy__(self):
|
|
3255
|
+
if self.__class__ is not __dataclass__cls:
|
|
3256
|
+
raise TypeError(self)
|
|
3257
|
+
return __dataclass__cls( # noqa
|
|
3258
|
+
numa=self.numa,
|
|
3259
|
+
num_ctx=self.num_ctx,
|
|
3260
|
+
num_batch=self.num_batch,
|
|
3261
|
+
num_gpu=self.num_gpu,
|
|
3262
|
+
main_gpu=self.main_gpu,
|
|
3263
|
+
low_vram=self.low_vram,
|
|
3264
|
+
f16_kv=self.f16_kv,
|
|
3265
|
+
logits_all=self.logits_all,
|
|
3266
|
+
vocab_only=self.vocab_only,
|
|
3267
|
+
use_mmap=self.use_mmap,
|
|
3268
|
+
use_mlock=self.use_mlock,
|
|
3269
|
+
embedding_only=self.embedding_only,
|
|
3270
|
+
num_thread=self.num_thread,
|
|
3271
|
+
num_keep=self.num_keep,
|
|
3272
|
+
seed=self.seed,
|
|
3273
|
+
num_predict=self.num_predict,
|
|
3274
|
+
top_k=self.top_k,
|
|
3275
|
+
top_p=self.top_p,
|
|
3276
|
+
tfs_z=self.tfs_z,
|
|
3277
|
+
typical_p=self.typical_p,
|
|
3278
|
+
repeat_last_n=self.repeat_last_n,
|
|
3279
|
+
temperature=self.temperature,
|
|
3280
|
+
repeat_penalty=self.repeat_penalty,
|
|
3281
|
+
presence_penalty=self.presence_penalty,
|
|
3282
|
+
frequency_penalty=self.frequency_penalty,
|
|
3283
|
+
mirostat=self.mirostat,
|
|
3284
|
+
mirostat_tau=self.mirostat_tau,
|
|
3285
|
+
mirostat_eta=self.mirostat_eta,
|
|
3286
|
+
penalize_newline=self.penalize_newline,
|
|
3287
|
+
stop=self.stop,
|
|
3288
|
+
)
|
|
3289
|
+
|
|
3290
|
+
__copy__.__qualname__ = f"{__dataclass__cls.__qualname__}.__copy__"
|
|
3291
|
+
if '__copy__' in __dataclass__cls.__dict__:
|
|
3292
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __copy__ in class {__dataclass__cls.__name__}")
|
|
3293
|
+
setattr(__dataclass__cls, '__copy__', __copy__)
|
|
3294
|
+
|
|
3295
|
+
def __eq__(self, other):
|
|
3296
|
+
if self is other:
|
|
3297
|
+
return True
|
|
3298
|
+
if self.__class__ is not other.__class__:
|
|
3299
|
+
return NotImplemented
|
|
3300
|
+
return (
|
|
3301
|
+
self.numa == other.numa and
|
|
3302
|
+
self.num_ctx == other.num_ctx and
|
|
3303
|
+
self.num_batch == other.num_batch and
|
|
3304
|
+
self.num_gpu == other.num_gpu and
|
|
3305
|
+
self.main_gpu == other.main_gpu and
|
|
3306
|
+
self.low_vram == other.low_vram and
|
|
3307
|
+
self.f16_kv == other.f16_kv and
|
|
3308
|
+
self.logits_all == other.logits_all and
|
|
3309
|
+
self.vocab_only == other.vocab_only and
|
|
3310
|
+
self.use_mmap == other.use_mmap and
|
|
3311
|
+
self.use_mlock == other.use_mlock and
|
|
3312
|
+
self.embedding_only == other.embedding_only and
|
|
3313
|
+
self.num_thread == other.num_thread and
|
|
3314
|
+
self.num_keep == other.num_keep and
|
|
3315
|
+
self.seed == other.seed and
|
|
3316
|
+
self.num_predict == other.num_predict and
|
|
3317
|
+
self.top_k == other.top_k and
|
|
3318
|
+
self.top_p == other.top_p and
|
|
3319
|
+
self.tfs_z == other.tfs_z and
|
|
3320
|
+
self.typical_p == other.typical_p and
|
|
3321
|
+
self.repeat_last_n == other.repeat_last_n and
|
|
3322
|
+
self.temperature == other.temperature and
|
|
3323
|
+
self.repeat_penalty == other.repeat_penalty and
|
|
3324
|
+
self.presence_penalty == other.presence_penalty and
|
|
3325
|
+
self.frequency_penalty == other.frequency_penalty and
|
|
3326
|
+
self.mirostat == other.mirostat and
|
|
3327
|
+
self.mirostat_tau == other.mirostat_tau and
|
|
3328
|
+
self.mirostat_eta == other.mirostat_eta and
|
|
3329
|
+
self.penalize_newline == other.penalize_newline and
|
|
3330
|
+
self.stop == other.stop
|
|
3331
|
+
)
|
|
3332
|
+
|
|
3333
|
+
__eq__.__qualname__ = f"{__dataclass__cls.__qualname__}.__eq__"
|
|
3334
|
+
if '__eq__' in __dataclass__cls.__dict__:
|
|
3335
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __eq__ in class {__dataclass__cls.__name__}")
|
|
3336
|
+
setattr(__dataclass__cls, '__eq__', __eq__)
|
|
3337
|
+
|
|
3338
|
+
__dataclass___setattr_frozen_fields = {
|
|
3339
|
+
'numa',
|
|
3340
|
+
'num_ctx',
|
|
3341
|
+
'num_batch',
|
|
3342
|
+
'num_gpu',
|
|
3343
|
+
'main_gpu',
|
|
3344
|
+
'low_vram',
|
|
3345
|
+
'f16_kv',
|
|
3346
|
+
'logits_all',
|
|
3347
|
+
'vocab_only',
|
|
3348
|
+
'use_mmap',
|
|
3349
|
+
'use_mlock',
|
|
3350
|
+
'embedding_only',
|
|
3351
|
+
'num_thread',
|
|
3352
|
+
'num_keep',
|
|
3353
|
+
'seed',
|
|
3354
|
+
'num_predict',
|
|
3355
|
+
'top_k',
|
|
3356
|
+
'top_p',
|
|
3357
|
+
'tfs_z',
|
|
3358
|
+
'typical_p',
|
|
3359
|
+
'repeat_last_n',
|
|
3360
|
+
'temperature',
|
|
3361
|
+
'repeat_penalty',
|
|
3362
|
+
'presence_penalty',
|
|
3363
|
+
'frequency_penalty',
|
|
3364
|
+
'mirostat',
|
|
3365
|
+
'mirostat_tau',
|
|
3366
|
+
'mirostat_eta',
|
|
3367
|
+
'penalize_newline',
|
|
3368
|
+
'stop',
|
|
3369
|
+
}
|
|
3370
|
+
|
|
3371
|
+
def __setattr__(self, name, value):
|
|
3372
|
+
if (
|
|
3373
|
+
type(self) is __dataclass__cls
|
|
3374
|
+
or name in __dataclass___setattr_frozen_fields
|
|
3375
|
+
):
|
|
3376
|
+
raise __dataclass__FrozenInstanceError(f"cannot assign to field {name!r}")
|
|
3377
|
+
super(__dataclass__cls, self).__setattr__(name, value)
|
|
3378
|
+
|
|
3379
|
+
__setattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__setattr__"
|
|
3380
|
+
if '__setattr__' in __dataclass__cls.__dict__:
|
|
3381
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __setattr__ in class {__dataclass__cls.__name__}")
|
|
3382
|
+
setattr(__dataclass__cls, '__setattr__', __setattr__)
|
|
3383
|
+
|
|
3384
|
+
__dataclass___delattr_frozen_fields = {
|
|
3385
|
+
'numa',
|
|
3386
|
+
'num_ctx',
|
|
3387
|
+
'num_batch',
|
|
3388
|
+
'num_gpu',
|
|
3389
|
+
'main_gpu',
|
|
3390
|
+
'low_vram',
|
|
3391
|
+
'f16_kv',
|
|
3392
|
+
'logits_all',
|
|
3393
|
+
'vocab_only',
|
|
3394
|
+
'use_mmap',
|
|
3395
|
+
'use_mlock',
|
|
3396
|
+
'embedding_only',
|
|
3397
|
+
'num_thread',
|
|
3398
|
+
'num_keep',
|
|
3399
|
+
'seed',
|
|
3400
|
+
'num_predict',
|
|
3401
|
+
'top_k',
|
|
3402
|
+
'top_p',
|
|
3403
|
+
'tfs_z',
|
|
3404
|
+
'typical_p',
|
|
3405
|
+
'repeat_last_n',
|
|
3406
|
+
'temperature',
|
|
3407
|
+
'repeat_penalty',
|
|
3408
|
+
'presence_penalty',
|
|
3409
|
+
'frequency_penalty',
|
|
3410
|
+
'mirostat',
|
|
3411
|
+
'mirostat_tau',
|
|
3412
|
+
'mirostat_eta',
|
|
3413
|
+
'penalize_newline',
|
|
3414
|
+
'stop',
|
|
3415
|
+
}
|
|
3416
|
+
|
|
3417
|
+
def __delattr__(self, name):
|
|
3418
|
+
if (
|
|
3419
|
+
type(self) is __dataclass__cls
|
|
3420
|
+
or name in __dataclass___delattr_frozen_fields
|
|
3421
|
+
):
|
|
3422
|
+
raise __dataclass__FrozenInstanceError(f"cannot delete field {name!r}")
|
|
3423
|
+
super(__dataclass__cls, self).__delattr__(name)
|
|
3424
|
+
|
|
3425
|
+
__delattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__delattr__"
|
|
3426
|
+
if '__delattr__' in __dataclass__cls.__dict__:
|
|
3427
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __delattr__ in class {__dataclass__cls.__name__}")
|
|
3428
|
+
setattr(__dataclass__cls, '__delattr__', __delattr__)
|
|
3429
|
+
|
|
3430
|
+
def __hash__(self):
|
|
3431
|
+
return hash((
|
|
3432
|
+
self.numa,
|
|
3433
|
+
self.num_ctx,
|
|
3434
|
+
self.num_batch,
|
|
3435
|
+
self.num_gpu,
|
|
3436
|
+
self.main_gpu,
|
|
3437
|
+
self.low_vram,
|
|
3438
|
+
self.f16_kv,
|
|
3439
|
+
self.logits_all,
|
|
3440
|
+
self.vocab_only,
|
|
3441
|
+
self.use_mmap,
|
|
3442
|
+
self.use_mlock,
|
|
3443
|
+
self.embedding_only,
|
|
3444
|
+
self.num_thread,
|
|
3445
|
+
self.num_keep,
|
|
3446
|
+
self.seed,
|
|
3447
|
+
self.num_predict,
|
|
3448
|
+
self.top_k,
|
|
3449
|
+
self.top_p,
|
|
3450
|
+
self.tfs_z,
|
|
3451
|
+
self.typical_p,
|
|
3452
|
+
self.repeat_last_n,
|
|
3453
|
+
self.temperature,
|
|
3454
|
+
self.repeat_penalty,
|
|
3455
|
+
self.presence_penalty,
|
|
3456
|
+
self.frequency_penalty,
|
|
3457
|
+
self.mirostat,
|
|
3458
|
+
self.mirostat_tau,
|
|
3459
|
+
self.mirostat_eta,
|
|
3460
|
+
self.penalize_newline,
|
|
3461
|
+
self.stop,
|
|
3462
|
+
))
|
|
3463
|
+
|
|
3464
|
+
__hash__.__qualname__ = f"{__dataclass__cls.__qualname__}.__hash__"
|
|
3465
|
+
setattr(__dataclass__cls, '__hash__', __hash__)
|
|
3466
|
+
|
|
3467
|
+
def __init__(
|
|
3468
|
+
self,
|
|
3469
|
+
*,
|
|
3470
|
+
numa: __dataclass__init__fields__0__annotation = __dataclass__init__fields__0__default,
|
|
3471
|
+
num_ctx: __dataclass__init__fields__1__annotation = __dataclass__init__fields__1__default,
|
|
3472
|
+
num_batch: __dataclass__init__fields__2__annotation = __dataclass__init__fields__2__default,
|
|
3473
|
+
num_gpu: __dataclass__init__fields__3__annotation = __dataclass__init__fields__3__default,
|
|
3474
|
+
main_gpu: __dataclass__init__fields__4__annotation = __dataclass__init__fields__4__default,
|
|
3475
|
+
low_vram: __dataclass__init__fields__5__annotation = __dataclass__init__fields__5__default,
|
|
3476
|
+
f16_kv: __dataclass__init__fields__6__annotation = __dataclass__init__fields__6__default,
|
|
3477
|
+
logits_all: __dataclass__init__fields__7__annotation = __dataclass__init__fields__7__default,
|
|
3478
|
+
vocab_only: __dataclass__init__fields__8__annotation = __dataclass__init__fields__8__default,
|
|
3479
|
+
use_mmap: __dataclass__init__fields__9__annotation = __dataclass__init__fields__9__default,
|
|
3480
|
+
use_mlock: __dataclass__init__fields__10__annotation = __dataclass__init__fields__10__default,
|
|
3481
|
+
embedding_only: __dataclass__init__fields__11__annotation = __dataclass__init__fields__11__default,
|
|
3482
|
+
num_thread: __dataclass__init__fields__12__annotation = __dataclass__init__fields__12__default,
|
|
3483
|
+
num_keep: __dataclass__init__fields__13__annotation = __dataclass__init__fields__13__default,
|
|
3484
|
+
seed: __dataclass__init__fields__14__annotation = __dataclass__init__fields__14__default,
|
|
3485
|
+
num_predict: __dataclass__init__fields__15__annotation = __dataclass__init__fields__15__default,
|
|
3486
|
+
top_k: __dataclass__init__fields__16__annotation = __dataclass__init__fields__16__default,
|
|
3487
|
+
top_p: __dataclass__init__fields__17__annotation = __dataclass__init__fields__17__default,
|
|
3488
|
+
tfs_z: __dataclass__init__fields__18__annotation = __dataclass__init__fields__18__default,
|
|
3489
|
+
typical_p: __dataclass__init__fields__19__annotation = __dataclass__init__fields__19__default,
|
|
3490
|
+
repeat_last_n: __dataclass__init__fields__20__annotation = __dataclass__init__fields__20__default,
|
|
3491
|
+
temperature: __dataclass__init__fields__21__annotation = __dataclass__init__fields__21__default,
|
|
3492
|
+
repeat_penalty: __dataclass__init__fields__22__annotation = __dataclass__init__fields__22__default,
|
|
3493
|
+
presence_penalty: __dataclass__init__fields__23__annotation = __dataclass__init__fields__23__default,
|
|
3494
|
+
frequency_penalty: __dataclass__init__fields__24__annotation = __dataclass__init__fields__24__default,
|
|
3495
|
+
mirostat: __dataclass__init__fields__25__annotation = __dataclass__init__fields__25__default,
|
|
3496
|
+
mirostat_tau: __dataclass__init__fields__26__annotation = __dataclass__init__fields__26__default,
|
|
3497
|
+
mirostat_eta: __dataclass__init__fields__27__annotation = __dataclass__init__fields__27__default,
|
|
3498
|
+
penalize_newline: __dataclass__init__fields__28__annotation = __dataclass__init__fields__28__default,
|
|
3499
|
+
stop: __dataclass__init__fields__29__annotation = __dataclass__init__fields__29__default,
|
|
3500
|
+
) -> __dataclass__None:
|
|
3501
|
+
__dataclass__object_setattr(self, 'numa', numa)
|
|
3502
|
+
__dataclass__object_setattr(self, 'num_ctx', num_ctx)
|
|
3503
|
+
__dataclass__object_setattr(self, 'num_batch', num_batch)
|
|
3504
|
+
__dataclass__object_setattr(self, 'num_gpu', num_gpu)
|
|
3505
|
+
__dataclass__object_setattr(self, 'main_gpu', main_gpu)
|
|
3506
|
+
__dataclass__object_setattr(self, 'low_vram', low_vram)
|
|
3507
|
+
__dataclass__object_setattr(self, 'f16_kv', f16_kv)
|
|
3508
|
+
__dataclass__object_setattr(self, 'logits_all', logits_all)
|
|
3509
|
+
__dataclass__object_setattr(self, 'vocab_only', vocab_only)
|
|
3510
|
+
__dataclass__object_setattr(self, 'use_mmap', use_mmap)
|
|
3511
|
+
__dataclass__object_setattr(self, 'use_mlock', use_mlock)
|
|
3512
|
+
__dataclass__object_setattr(self, 'embedding_only', embedding_only)
|
|
3513
|
+
__dataclass__object_setattr(self, 'num_thread', num_thread)
|
|
3514
|
+
__dataclass__object_setattr(self, 'num_keep', num_keep)
|
|
3515
|
+
__dataclass__object_setattr(self, 'seed', seed)
|
|
3516
|
+
__dataclass__object_setattr(self, 'num_predict', num_predict)
|
|
3517
|
+
__dataclass__object_setattr(self, 'top_k', top_k)
|
|
3518
|
+
__dataclass__object_setattr(self, 'top_p', top_p)
|
|
3519
|
+
__dataclass__object_setattr(self, 'tfs_z', tfs_z)
|
|
3520
|
+
__dataclass__object_setattr(self, 'typical_p', typical_p)
|
|
3521
|
+
__dataclass__object_setattr(self, 'repeat_last_n', repeat_last_n)
|
|
3522
|
+
__dataclass__object_setattr(self, 'temperature', temperature)
|
|
3523
|
+
__dataclass__object_setattr(self, 'repeat_penalty', repeat_penalty)
|
|
3524
|
+
__dataclass__object_setattr(self, 'presence_penalty', presence_penalty)
|
|
3525
|
+
__dataclass__object_setattr(self, 'frequency_penalty', frequency_penalty)
|
|
3526
|
+
__dataclass__object_setattr(self, 'mirostat', mirostat)
|
|
3527
|
+
__dataclass__object_setattr(self, 'mirostat_tau', mirostat_tau)
|
|
3528
|
+
__dataclass__object_setattr(self, 'mirostat_eta', mirostat_eta)
|
|
3529
|
+
__dataclass__object_setattr(self, 'penalize_newline', penalize_newline)
|
|
3530
|
+
__dataclass__object_setattr(self, 'stop', stop)
|
|
3531
|
+
|
|
3532
|
+
__init__.__qualname__ = f"{__dataclass__cls.__qualname__}.__init__"
|
|
3533
|
+
if '__init__' in __dataclass__cls.__dict__:
|
|
3534
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __init__ in class {__dataclass__cls.__name__}")
|
|
3535
|
+
setattr(__dataclass__cls, '__init__', __init__)
|
|
3536
|
+
|
|
3537
|
+
@__dataclass___recursive_repr()
|
|
3538
|
+
def __repr__(self):
|
|
3539
|
+
parts = []
|
|
3540
|
+
if (s := __dataclass__repr__default_fn(self.numa)) is not None:
|
|
3541
|
+
parts.append(f"numa={s}")
|
|
3542
|
+
if (s := __dataclass__repr__default_fn(self.num_ctx)) is not None:
|
|
3543
|
+
parts.append(f"num_ctx={s}")
|
|
3544
|
+
if (s := __dataclass__repr__default_fn(self.num_batch)) is not None:
|
|
3545
|
+
parts.append(f"num_batch={s}")
|
|
3546
|
+
if (s := __dataclass__repr__default_fn(self.num_gpu)) is not None:
|
|
3547
|
+
parts.append(f"num_gpu={s}")
|
|
3548
|
+
if (s := __dataclass__repr__default_fn(self.main_gpu)) is not None:
|
|
3549
|
+
parts.append(f"main_gpu={s}")
|
|
3550
|
+
if (s := __dataclass__repr__default_fn(self.low_vram)) is not None:
|
|
3551
|
+
parts.append(f"low_vram={s}")
|
|
3552
|
+
if (s := __dataclass__repr__default_fn(self.f16_kv)) is not None:
|
|
3553
|
+
parts.append(f"f16_kv={s}")
|
|
3554
|
+
if (s := __dataclass__repr__default_fn(self.logits_all)) is not None:
|
|
3555
|
+
parts.append(f"logits_all={s}")
|
|
3556
|
+
if (s := __dataclass__repr__default_fn(self.vocab_only)) is not None:
|
|
3557
|
+
parts.append(f"vocab_only={s}")
|
|
3558
|
+
if (s := __dataclass__repr__default_fn(self.use_mmap)) is not None:
|
|
3559
|
+
parts.append(f"use_mmap={s}")
|
|
3560
|
+
if (s := __dataclass__repr__default_fn(self.use_mlock)) is not None:
|
|
3561
|
+
parts.append(f"use_mlock={s}")
|
|
3562
|
+
if (s := __dataclass__repr__default_fn(self.embedding_only)) is not None:
|
|
3563
|
+
parts.append(f"embedding_only={s}")
|
|
3564
|
+
if (s := __dataclass__repr__default_fn(self.num_thread)) is not None:
|
|
3565
|
+
parts.append(f"num_thread={s}")
|
|
3566
|
+
if (s := __dataclass__repr__default_fn(self.num_keep)) is not None:
|
|
3567
|
+
parts.append(f"num_keep={s}")
|
|
3568
|
+
if (s := __dataclass__repr__default_fn(self.seed)) is not None:
|
|
3569
|
+
parts.append(f"seed={s}")
|
|
3570
|
+
if (s := __dataclass__repr__default_fn(self.num_predict)) is not None:
|
|
3571
|
+
parts.append(f"num_predict={s}")
|
|
3572
|
+
if (s := __dataclass__repr__default_fn(self.top_k)) is not None:
|
|
3573
|
+
parts.append(f"top_k={s}")
|
|
3574
|
+
if (s := __dataclass__repr__default_fn(self.top_p)) is not None:
|
|
3575
|
+
parts.append(f"top_p={s}")
|
|
3576
|
+
if (s := __dataclass__repr__default_fn(self.tfs_z)) is not None:
|
|
3577
|
+
parts.append(f"tfs_z={s}")
|
|
3578
|
+
if (s := __dataclass__repr__default_fn(self.typical_p)) is not None:
|
|
3579
|
+
parts.append(f"typical_p={s}")
|
|
3580
|
+
if (s := __dataclass__repr__default_fn(self.repeat_last_n)) is not None:
|
|
3581
|
+
parts.append(f"repeat_last_n={s}")
|
|
3582
|
+
if (s := __dataclass__repr__default_fn(self.temperature)) is not None:
|
|
3583
|
+
parts.append(f"temperature={s}")
|
|
3584
|
+
if (s := __dataclass__repr__default_fn(self.repeat_penalty)) is not None:
|
|
3585
|
+
parts.append(f"repeat_penalty={s}")
|
|
3586
|
+
if (s := __dataclass__repr__default_fn(self.presence_penalty)) is not None:
|
|
3587
|
+
parts.append(f"presence_penalty={s}")
|
|
3588
|
+
if (s := __dataclass__repr__default_fn(self.frequency_penalty)) is not None:
|
|
3589
|
+
parts.append(f"frequency_penalty={s}")
|
|
3590
|
+
if (s := __dataclass__repr__default_fn(self.mirostat)) is not None:
|
|
3591
|
+
parts.append(f"mirostat={s}")
|
|
3592
|
+
if (s := __dataclass__repr__default_fn(self.mirostat_tau)) is not None:
|
|
3593
|
+
parts.append(f"mirostat_tau={s}")
|
|
3594
|
+
if (s := __dataclass__repr__default_fn(self.mirostat_eta)) is not None:
|
|
3595
|
+
parts.append(f"mirostat_eta={s}")
|
|
3596
|
+
if (s := __dataclass__repr__default_fn(self.penalize_newline)) is not None:
|
|
3597
|
+
parts.append(f"penalize_newline={s}")
|
|
3598
|
+
if (s := __dataclass__repr__default_fn(self.stop)) is not None:
|
|
3599
|
+
parts.append(f"stop={s}")
|
|
3600
|
+
return (
|
|
3601
|
+
f"{self.__class__.__qualname__}("
|
|
3602
|
+
f"{', '.join(parts)}"
|
|
3603
|
+
f")"
|
|
3604
|
+
)
|
|
3605
|
+
|
|
3606
|
+
__repr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__repr__"
|
|
3607
|
+
if '__repr__' in __dataclass__cls.__dict__:
|
|
3608
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __repr__ in class {__dataclass__cls.__name__}")
|
|
3609
|
+
setattr(__dataclass__cls, '__repr__', __repr__)
|
|
3610
|
+
|
|
3611
|
+
return _process_dataclass
|
|
3612
|
+
|
|
3613
|
+
|
|
3614
|
+
@_register(
|
|
3615
|
+
plan_repr=(
|
|
3616
|
+
"Plans(tup=(CopyPlan(fields=('type', 'function')), EqPlan(fields=('type', 'function')), FrozenPlan(fields=('typ"
|
|
3617
|
+
"e', 'function'), allow_dynamic_dunder_attrs=False), HashPlan(action='add', fields=('type', 'function'), cache="
|
|
3618
|
+
"False), InitPlan(fields=(InitPlan.Field(name='type', annotation=OpRef(name='init.fields.0.annotation'), defaul"
|
|
3619
|
+
"t=OpRef(name='init.fields.0.default'), default_factory=None, init=True, override=False, field_type=FieldType.I"
|
|
3620
|
+
"NSTANCE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='function', annotation=OpRef(name='"
|
|
3621
|
+
"init.fields.1.annotation'), default=OpRef(name='init.fields.1.default'), default_factory=None, init=True, over"
|
|
3622
|
+
"ride=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None)), self_param='self', s"
|
|
3623
|
+
"td_params=(), kw_only_params=('type', 'function'), frozen=True, slots=False, post_init_params=None, init_fns=("
|
|
3624
|
+
"), validate_fns=()), ReprPlan(fields=(ReprPlan.Field(name='type', kw_only=True, fn=None), ReprPlan.Field(name="
|
|
3625
|
+
"'function', kw_only=True, fn=None)), id=False, terse=False, default_fn=OpRef(name='repr.default_fn'))))"
|
|
3626
|
+
),
|
|
3627
|
+
plan_repr_sha1='98e20371eacca6bc272118f8eb67b1dcfcf27443',
|
|
3628
|
+
op_ref_idents=(
|
|
3629
|
+
'__dataclass__init__fields__0__annotation',
|
|
3630
|
+
'__dataclass__init__fields__0__default',
|
|
3631
|
+
'__dataclass__init__fields__1__annotation',
|
|
3632
|
+
'__dataclass__init__fields__1__default',
|
|
3633
|
+
'__dataclass__repr__default_fn',
|
|
3634
|
+
),
|
|
3635
|
+
cls_names=(
|
|
3636
|
+
('ommlds.backends.ollama.protocol', 'Tool'),
|
|
3637
|
+
),
|
|
3638
|
+
)
|
|
3639
|
+
def _process_dataclass__98e20371eacca6bc272118f8eb67b1dcfcf27443():
|
|
3640
|
+
def _process_dataclass(
|
|
3641
|
+
*,
|
|
3642
|
+
__dataclass__cls,
|
|
3643
|
+
__dataclass__init__fields__0__annotation,
|
|
3644
|
+
__dataclass__init__fields__0__default,
|
|
3645
|
+
__dataclass__init__fields__1__annotation,
|
|
3646
|
+
__dataclass__init__fields__1__default,
|
|
3647
|
+
__dataclass__repr__default_fn,
|
|
3648
|
+
__dataclass__FieldFnValidationError, # noqa
|
|
3649
|
+
__dataclass__FieldTypeValidationError, # noqa
|
|
3650
|
+
__dataclass__FnValidationError, # noqa
|
|
3651
|
+
__dataclass__FrozenInstanceError=dataclasses.FrozenInstanceError, # noqa
|
|
3652
|
+
__dataclass__FunctionType=types.FunctionType, # noqa
|
|
3653
|
+
__dataclass__HAS_DEFAULT_FACTORY=dataclasses._HAS_DEFAULT_FACTORY, # noqa
|
|
3654
|
+
__dataclass__MISSING=dataclasses.MISSING, # noqa
|
|
3655
|
+
__dataclass__None=None, # noqa
|
|
3656
|
+
__dataclass__TypeError=TypeError, # noqa
|
|
3657
|
+
__dataclass___recursive_repr=reprlib.recursive_repr, # noqa
|
|
3658
|
+
__dataclass__isinstance=isinstance, # noqa
|
|
3659
|
+
__dataclass__object_setattr=object.__setattr__, # noqa
|
|
3660
|
+
__dataclass__property=property, # noqa
|
|
3661
|
+
):
|
|
3662
|
+
def __copy__(self):
|
|
3663
|
+
if self.__class__ is not __dataclass__cls:
|
|
3664
|
+
raise TypeError(self)
|
|
3665
|
+
return __dataclass__cls( # noqa
|
|
3666
|
+
type=self.type,
|
|
3667
|
+
function=self.function,
|
|
3668
|
+
)
|
|
3669
|
+
|
|
3670
|
+
__copy__.__qualname__ = f"{__dataclass__cls.__qualname__}.__copy__"
|
|
3671
|
+
if '__copy__' in __dataclass__cls.__dict__:
|
|
3672
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __copy__ in class {__dataclass__cls.__name__}")
|
|
3673
|
+
setattr(__dataclass__cls, '__copy__', __copy__)
|
|
3674
|
+
|
|
3675
|
+
def __eq__(self, other):
|
|
3676
|
+
if self is other:
|
|
3677
|
+
return True
|
|
3678
|
+
if self.__class__ is not other.__class__:
|
|
3679
|
+
return NotImplemented
|
|
3680
|
+
return (
|
|
3681
|
+
self.type == other.type and
|
|
3682
|
+
self.function == other.function
|
|
3683
|
+
)
|
|
3684
|
+
|
|
3685
|
+
__eq__.__qualname__ = f"{__dataclass__cls.__qualname__}.__eq__"
|
|
3686
|
+
if '__eq__' in __dataclass__cls.__dict__:
|
|
3687
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __eq__ in class {__dataclass__cls.__name__}")
|
|
3688
|
+
setattr(__dataclass__cls, '__eq__', __eq__)
|
|
3689
|
+
|
|
3690
|
+
__dataclass___setattr_frozen_fields = {
|
|
3691
|
+
'type',
|
|
3692
|
+
'function',
|
|
3693
|
+
}
|
|
3694
|
+
|
|
3695
|
+
def __setattr__(self, name, value):
|
|
3696
|
+
if (
|
|
3697
|
+
type(self) is __dataclass__cls
|
|
3698
|
+
or name in __dataclass___setattr_frozen_fields
|
|
3699
|
+
):
|
|
3700
|
+
raise __dataclass__FrozenInstanceError(f"cannot assign to field {name!r}")
|
|
3701
|
+
super(__dataclass__cls, self).__setattr__(name, value)
|
|
3702
|
+
|
|
3703
|
+
__setattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__setattr__"
|
|
3704
|
+
if '__setattr__' in __dataclass__cls.__dict__:
|
|
3705
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __setattr__ in class {__dataclass__cls.__name__}")
|
|
3706
|
+
setattr(__dataclass__cls, '__setattr__', __setattr__)
|
|
3707
|
+
|
|
3708
|
+
__dataclass___delattr_frozen_fields = {
|
|
3709
|
+
'type',
|
|
3710
|
+
'function',
|
|
3711
|
+
}
|
|
3712
|
+
|
|
3713
|
+
def __delattr__(self, name):
|
|
3714
|
+
if (
|
|
3715
|
+
type(self) is __dataclass__cls
|
|
3716
|
+
or name in __dataclass___delattr_frozen_fields
|
|
3717
|
+
):
|
|
3718
|
+
raise __dataclass__FrozenInstanceError(f"cannot delete field {name!r}")
|
|
3719
|
+
super(__dataclass__cls, self).__delattr__(name)
|
|
3720
|
+
|
|
3721
|
+
__delattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__delattr__"
|
|
3722
|
+
if '__delattr__' in __dataclass__cls.__dict__:
|
|
3723
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __delattr__ in class {__dataclass__cls.__name__}")
|
|
3724
|
+
setattr(__dataclass__cls, '__delattr__', __delattr__)
|
|
3725
|
+
|
|
3726
|
+
def __hash__(self):
|
|
3727
|
+
return hash((
|
|
3728
|
+
self.type,
|
|
3729
|
+
self.function,
|
|
3730
|
+
))
|
|
3731
|
+
|
|
3732
|
+
__hash__.__qualname__ = f"{__dataclass__cls.__qualname__}.__hash__"
|
|
3733
|
+
setattr(__dataclass__cls, '__hash__', __hash__)
|
|
3734
|
+
|
|
3735
|
+
def __init__(
|
|
3736
|
+
self,
|
|
3737
|
+
*,
|
|
3738
|
+
type: __dataclass__init__fields__0__annotation = __dataclass__init__fields__0__default,
|
|
3739
|
+
function: __dataclass__init__fields__1__annotation = __dataclass__init__fields__1__default,
|
|
3740
|
+
) -> __dataclass__None:
|
|
3741
|
+
__dataclass__object_setattr(self, 'type', type)
|
|
3742
|
+
__dataclass__object_setattr(self, 'function', function)
|
|
3743
|
+
|
|
3744
|
+
__init__.__qualname__ = f"{__dataclass__cls.__qualname__}.__init__"
|
|
3745
|
+
if '__init__' in __dataclass__cls.__dict__:
|
|
3746
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __init__ in class {__dataclass__cls.__name__}")
|
|
3747
|
+
setattr(__dataclass__cls, '__init__', __init__)
|
|
3748
|
+
|
|
3749
|
+
@__dataclass___recursive_repr()
|
|
3750
|
+
def __repr__(self):
|
|
3751
|
+
parts = []
|
|
3752
|
+
if (s := __dataclass__repr__default_fn(self.type)) is not None:
|
|
3753
|
+
parts.append(f"type={s}")
|
|
3754
|
+
if (s := __dataclass__repr__default_fn(self.function)) is not None:
|
|
3755
|
+
parts.append(f"function={s}")
|
|
3756
|
+
return (
|
|
3757
|
+
f"{self.__class__.__qualname__}("
|
|
3758
|
+
f"{', '.join(parts)}"
|
|
3759
|
+
f")"
|
|
3760
|
+
)
|
|
3761
|
+
|
|
3762
|
+
__repr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__repr__"
|
|
3763
|
+
if '__repr__' in __dataclass__cls.__dict__:
|
|
3764
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __repr__ in class {__dataclass__cls.__name__}")
|
|
3765
|
+
setattr(__dataclass__cls, '__repr__', __repr__)
|
|
3766
|
+
|
|
3767
|
+
return _process_dataclass
|
|
3768
|
+
|
|
3769
|
+
|
|
3770
|
+
@_register(
|
|
3771
|
+
plan_repr=(
|
|
3772
|
+
"Plans(tup=(CopyPlan(fields=('name', 'description', 'parameters')), EqPlan(fields=('name', 'description', 'para"
|
|
3773
|
+
"meters')), FrozenPlan(fields=('name', 'description', 'parameters'), allow_dynamic_dunder_attrs=False), HashPla"
|
|
3774
|
+
"n(action='add', fields=('name', 'description', 'parameters'), cache=False), InitPlan(fields=(InitPlan.Field(na"
|
|
3775
|
+
"me='name', annotation=OpRef(name='init.fields.0.annotation'), default=OpRef(name='init.fields.0.default'), def"
|
|
3776
|
+
"ault_factory=None, init=True, override=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check"
|
|
3777
|
+
"_type=None), InitPlan.Field(name='description', annotation=OpRef(name='init.fields.1.annotation'), default=OpR"
|
|
3778
|
+
"ef(name='init.fields.1.default'), default_factory=None, init=True, override=False, field_type=FieldType.INSTAN"
|
|
3779
|
+
"CE, coerce=None, validate=None, check_type=None), InitPlan.Field(name='parameters', annotation=OpRef(name='ini"
|
|
3780
|
+
"t.fields.2.annotation'), default=OpRef(name='init.fields.2.default'), default_factory=None, init=True, overrid"
|
|
3781
|
+
"e=False, field_type=FieldType.INSTANCE, coerce=None, validate=None, check_type=None)), self_param='self', std_"
|
|
3782
|
+
"params=(), kw_only_params=('name', 'description', 'parameters'), frozen=True, slots=False, post_init_params=No"
|
|
3783
|
+
"ne, init_fns=(), validate_fns=()), ReprPlan(fields=(ReprPlan.Field(name='name', kw_only=True, fn=None), ReprPl"
|
|
3784
|
+
"an.Field(name='description', kw_only=True, fn=None), ReprPlan.Field(name='parameters', kw_only=True, fn=None))"
|
|
3785
|
+
", id=False, terse=False, default_fn=OpRef(name='repr.default_fn'))))"
|
|
3786
|
+
),
|
|
3787
|
+
plan_repr_sha1='c2256e8aae1a7cdef13cab0a48a15a27471904f0',
|
|
3788
|
+
op_ref_idents=(
|
|
3789
|
+
'__dataclass__init__fields__0__annotation',
|
|
3790
|
+
'__dataclass__init__fields__0__default',
|
|
3791
|
+
'__dataclass__init__fields__1__annotation',
|
|
3792
|
+
'__dataclass__init__fields__1__default',
|
|
3793
|
+
'__dataclass__init__fields__2__annotation',
|
|
3794
|
+
'__dataclass__init__fields__2__default',
|
|
3795
|
+
'__dataclass__repr__default_fn',
|
|
3796
|
+
),
|
|
3797
|
+
cls_names=(
|
|
3798
|
+
('ommlds.backends.ollama.protocol', 'Tool.Function'),
|
|
3799
|
+
),
|
|
3800
|
+
)
|
|
3801
|
+
def _process_dataclass__c2256e8aae1a7cdef13cab0a48a15a27471904f0():
|
|
3802
|
+
def _process_dataclass(
|
|
3803
|
+
*,
|
|
3804
|
+
__dataclass__cls,
|
|
3805
|
+
__dataclass__init__fields__0__annotation,
|
|
3806
|
+
__dataclass__init__fields__0__default,
|
|
3807
|
+
__dataclass__init__fields__1__annotation,
|
|
3808
|
+
__dataclass__init__fields__1__default,
|
|
3809
|
+
__dataclass__init__fields__2__annotation,
|
|
3810
|
+
__dataclass__init__fields__2__default,
|
|
3811
|
+
__dataclass__repr__default_fn,
|
|
3812
|
+
__dataclass__FieldFnValidationError, # noqa
|
|
3813
|
+
__dataclass__FieldTypeValidationError, # noqa
|
|
3814
|
+
__dataclass__FnValidationError, # noqa
|
|
3815
|
+
__dataclass__FrozenInstanceError=dataclasses.FrozenInstanceError, # noqa
|
|
3816
|
+
__dataclass__FunctionType=types.FunctionType, # noqa
|
|
3817
|
+
__dataclass__HAS_DEFAULT_FACTORY=dataclasses._HAS_DEFAULT_FACTORY, # noqa
|
|
3818
|
+
__dataclass__MISSING=dataclasses.MISSING, # noqa
|
|
3819
|
+
__dataclass__None=None, # noqa
|
|
3820
|
+
__dataclass__TypeError=TypeError, # noqa
|
|
3821
|
+
__dataclass___recursive_repr=reprlib.recursive_repr, # noqa
|
|
3822
|
+
__dataclass__isinstance=isinstance, # noqa
|
|
3823
|
+
__dataclass__object_setattr=object.__setattr__, # noqa
|
|
3824
|
+
__dataclass__property=property, # noqa
|
|
3825
|
+
):
|
|
3826
|
+
def __copy__(self):
|
|
3827
|
+
if self.__class__ is not __dataclass__cls:
|
|
3828
|
+
raise TypeError(self)
|
|
3829
|
+
return __dataclass__cls( # noqa
|
|
3830
|
+
name=self.name,
|
|
3831
|
+
description=self.description,
|
|
3832
|
+
parameters=self.parameters,
|
|
3833
|
+
)
|
|
3834
|
+
|
|
3835
|
+
__copy__.__qualname__ = f"{__dataclass__cls.__qualname__}.__copy__"
|
|
3836
|
+
if '__copy__' in __dataclass__cls.__dict__:
|
|
3837
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __copy__ in class {__dataclass__cls.__name__}")
|
|
3838
|
+
setattr(__dataclass__cls, '__copy__', __copy__)
|
|
3839
|
+
|
|
3840
|
+
def __eq__(self, other):
|
|
3841
|
+
if self is other:
|
|
3842
|
+
return True
|
|
3843
|
+
if self.__class__ is not other.__class__:
|
|
3844
|
+
return NotImplemented
|
|
3845
|
+
return (
|
|
3846
|
+
self.name == other.name and
|
|
3847
|
+
self.description == other.description and
|
|
3848
|
+
self.parameters == other.parameters
|
|
3849
|
+
)
|
|
3850
|
+
|
|
3851
|
+
__eq__.__qualname__ = f"{__dataclass__cls.__qualname__}.__eq__"
|
|
3852
|
+
if '__eq__' in __dataclass__cls.__dict__:
|
|
3853
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __eq__ in class {__dataclass__cls.__name__}")
|
|
3854
|
+
setattr(__dataclass__cls, '__eq__', __eq__)
|
|
3855
|
+
|
|
3856
|
+
__dataclass___setattr_frozen_fields = {
|
|
3857
|
+
'name',
|
|
3858
|
+
'description',
|
|
3859
|
+
'parameters',
|
|
3860
|
+
}
|
|
3861
|
+
|
|
3862
|
+
def __setattr__(self, name, value):
|
|
3863
|
+
if (
|
|
3864
|
+
type(self) is __dataclass__cls
|
|
3865
|
+
or name in __dataclass___setattr_frozen_fields
|
|
3866
|
+
):
|
|
3867
|
+
raise __dataclass__FrozenInstanceError(f"cannot assign to field {name!r}")
|
|
3868
|
+
super(__dataclass__cls, self).__setattr__(name, value)
|
|
3869
|
+
|
|
3870
|
+
__setattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__setattr__"
|
|
3871
|
+
if '__setattr__' in __dataclass__cls.__dict__:
|
|
3872
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __setattr__ in class {__dataclass__cls.__name__}")
|
|
3873
|
+
setattr(__dataclass__cls, '__setattr__', __setattr__)
|
|
3874
|
+
|
|
3875
|
+
__dataclass___delattr_frozen_fields = {
|
|
3876
|
+
'name',
|
|
3877
|
+
'description',
|
|
3878
|
+
'parameters',
|
|
3879
|
+
}
|
|
3880
|
+
|
|
3881
|
+
def __delattr__(self, name):
|
|
3882
|
+
if (
|
|
3883
|
+
type(self) is __dataclass__cls
|
|
3884
|
+
or name in __dataclass___delattr_frozen_fields
|
|
3885
|
+
):
|
|
3886
|
+
raise __dataclass__FrozenInstanceError(f"cannot delete field {name!r}")
|
|
3887
|
+
super(__dataclass__cls, self).__delattr__(name)
|
|
3888
|
+
|
|
3889
|
+
__delattr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__delattr__"
|
|
3890
|
+
if '__delattr__' in __dataclass__cls.__dict__:
|
|
3891
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __delattr__ in class {__dataclass__cls.__name__}")
|
|
3892
|
+
setattr(__dataclass__cls, '__delattr__', __delattr__)
|
|
3893
|
+
|
|
3894
|
+
def __hash__(self):
|
|
3895
|
+
return hash((
|
|
3896
|
+
self.name,
|
|
3897
|
+
self.description,
|
|
3898
|
+
self.parameters,
|
|
3899
|
+
))
|
|
3900
|
+
|
|
3901
|
+
__hash__.__qualname__ = f"{__dataclass__cls.__qualname__}.__hash__"
|
|
3902
|
+
setattr(__dataclass__cls, '__hash__', __hash__)
|
|
3903
|
+
|
|
3904
|
+
def __init__(
|
|
3905
|
+
self,
|
|
3906
|
+
*,
|
|
3907
|
+
name: __dataclass__init__fields__0__annotation = __dataclass__init__fields__0__default,
|
|
3908
|
+
description: __dataclass__init__fields__1__annotation = __dataclass__init__fields__1__default,
|
|
3909
|
+
parameters: __dataclass__init__fields__2__annotation = __dataclass__init__fields__2__default,
|
|
3910
|
+
) -> __dataclass__None:
|
|
3911
|
+
__dataclass__object_setattr(self, 'name', name)
|
|
3912
|
+
__dataclass__object_setattr(self, 'description', description)
|
|
3913
|
+
__dataclass__object_setattr(self, 'parameters', parameters)
|
|
3914
|
+
|
|
3915
|
+
__init__.__qualname__ = f"{__dataclass__cls.__qualname__}.__init__"
|
|
3916
|
+
if '__init__' in __dataclass__cls.__dict__:
|
|
3917
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __init__ in class {__dataclass__cls.__name__}")
|
|
3918
|
+
setattr(__dataclass__cls, '__init__', __init__)
|
|
3919
|
+
|
|
3920
|
+
@__dataclass___recursive_repr()
|
|
3921
|
+
def __repr__(self):
|
|
3922
|
+
parts = []
|
|
3923
|
+
if (s := __dataclass__repr__default_fn(self.name)) is not None:
|
|
3924
|
+
parts.append(f"name={s}")
|
|
3925
|
+
if (s := __dataclass__repr__default_fn(self.description)) is not None:
|
|
3926
|
+
parts.append(f"description={s}")
|
|
3927
|
+
if (s := __dataclass__repr__default_fn(self.parameters)) is not None:
|
|
3928
|
+
parts.append(f"parameters={s}")
|
|
3929
|
+
return (
|
|
3930
|
+
f"{self.__class__.__qualname__}("
|
|
3931
|
+
f"{', '.join(parts)}"
|
|
3932
|
+
f")"
|
|
3933
|
+
)
|
|
3934
|
+
|
|
3935
|
+
__repr__.__qualname__ = f"{__dataclass__cls.__qualname__}.__repr__"
|
|
3936
|
+
if '__repr__' in __dataclass__cls.__dict__:
|
|
3937
|
+
raise __dataclass__TypeError(f"Cannot overwrite attribute __repr__ in class {__dataclass__cls.__name__}")
|
|
3938
|
+
setattr(__dataclass__cls, '__repr__', __repr__)
|
|
3939
|
+
|
|
3940
|
+
return _process_dataclass
|