Shyamnath commited on
Commit
c40c75a
·
1 Parent(s): 469eae6

Push UI dashboard and deployment files

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. Dockerfile +14 -0
  2. app.py +11 -0
  3. deploy/Dockerfile.ghcr_base +17 -0
  4. deploy/azure_resource_manager/azure_marketplace.zip +3 -0
  5. deploy/azure_resource_manager/azure_marketplace/createUiDefinition.json +15 -0
  6. deploy/azure_resource_manager/azure_marketplace/mainTemplate.json +63 -0
  7. deploy/azure_resource_manager/main.bicep +42 -0
  8. deploy/charts/litellm-helm/.helmignore +23 -0
  9. deploy/charts/litellm-helm/Chart.lock +9 -0
  10. deploy/charts/litellm-helm/Chart.yaml +37 -0
  11. deploy/charts/litellm-helm/README.md +131 -0
  12. deploy/charts/litellm-helm/charts/postgresql-14.3.1.tgz +3 -0
  13. deploy/charts/litellm-helm/charts/redis-18.19.1.tgz +3 -0
  14. deploy/charts/litellm-helm/ci/test-values.yaml +15 -0
  15. deploy/charts/litellm-helm/templates/NOTES.txt +22 -0
  16. deploy/charts/litellm-helm/templates/_helpers.tpl +84 -0
  17. deploy/charts/litellm-helm/templates/configmap-litellm.yaml +7 -0
  18. deploy/charts/litellm-helm/templates/deployment.yaml +185 -0
  19. deploy/charts/litellm-helm/templates/hpa.yaml +32 -0
  20. deploy/charts/litellm-helm/templates/ingress.yaml +61 -0
  21. deploy/charts/litellm-helm/templates/migrations-job.yaml +71 -0
  22. deploy/charts/litellm-helm/templates/secret-dbcredentials.yaml +12 -0
  23. deploy/charts/litellm-helm/templates/secret-masterkey.yaml +10 -0
  24. deploy/charts/litellm-helm/templates/service.yaml +19 -0
  25. deploy/charts/litellm-helm/templates/serviceaccount.yaml +13 -0
  26. deploy/charts/litellm-helm/templates/tests/test-connection.yaml +25 -0
  27. deploy/charts/litellm-helm/templates/tests/test-env-vars.yaml +43 -0
  28. deploy/charts/litellm-helm/tests/deployment_tests.yaml +117 -0
  29. deploy/charts/litellm-helm/tests/masterkey-secret_tests.yaml +18 -0
  30. deploy/charts/litellm-helm/values.yaml +209 -0
  31. deploy/kubernetes/service.yaml +12 -0
  32. ui/litellm-dashboard/.eslintrc.json +3 -0
  33. ui/litellm-dashboard/README.md +36 -0
  34. ui/litellm-dashboard/build_ui.sh +49 -0
  35. ui/litellm-dashboard/build_ui_custom_path.sh +55 -0
  36. ui/litellm-dashboard/next.config.mjs +11 -0
  37. ui/litellm-dashboard/out/404.html +1 -0
  38. ui/litellm-dashboard/out/_next/static/9QypG31hSXzLA6YqfGTQF/_buildManifest.js +1 -0
  39. ui/litellm-dashboard/out/_next/static/9QypG31hSXzLA6YqfGTQF/_ssgManifest.js +1 -0
  40. ui/litellm-dashboard/out/_next/static/chunks/117-1c5bfc45bfc4237d.js +0 -0
  41. ui/litellm-dashboard/out/_next/static/chunks/13b76428-ebdf3012af0e4489.js +1 -0
  42. ui/litellm-dashboard/out/_next/static/chunks/250-d4389595d5e653e0.js +1 -0
  43. ui/litellm-dashboard/out/_next/static/chunks/261-92d8946249b3296e.js +0 -0
  44. ui/litellm-dashboard/out/_next/static/chunks/3014691f-b7b79b78e27792f3.js +1 -0
  45. ui/litellm-dashboard/out/_next/static/chunks/42-014374badc35fe9b.js +0 -0
  46. ui/litellm-dashboard/out/_next/static/chunks/699-7e1943e09d25350c.js +1 -0
  47. ui/litellm-dashboard/out/_next/static/chunks/894-25933cb7e07826a8.js +0 -0
  48. ui/litellm-dashboard/out/_next/static/chunks/899-54ea329f41297bf0.js +1 -0
  49. ui/litellm-dashboard/out/_next/static/chunks/app/_not-found/page-3b0daafcbe368586.js +1 -0
  50. ui/litellm-dashboard/out/_next/static/chunks/app/layout-af8319e6c59a08da.js +1 -0
Dockerfile ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ FROM python:3.10-slim
2
+
3
+ RUN useradd -m -u 1000 user
4
+ USER user
5
+ ENV PATH="/home/user/.local/bin:$PATH"
6
+
7
+ WORKDIR /app
8
+
9
+ COPY --chown=user requirements.txt .
10
+ RUN pip install --no-cache-dir -r requirements.txt
11
+
12
+ COPY --chown=user . .
13
+
14
+ CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]
app.py ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from fastapi import FastAPI
2
+ from litellm.playground_server import add_playground_routes
3
+
4
+ app = FastAPI()
5
+
6
+ # Add LiteLLM Playground UI at `/docs`
7
+ add_playground_routes(app)
8
+
9
+ @app.get("/")
10
+ def home():
11
+ return {"message": "LiteLLM UI is running! Visit /docs"}
deploy/Dockerfile.ghcr_base ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Use the provided base image
2
+ FROM ghcr.io/berriai/litellm:main-latest
3
+
4
+ # Set the working directory to /app
5
+ WORKDIR /app
6
+
7
+ # Copy the configuration file into the container at /app
8
+ COPY config.yaml .
9
+
10
+ # Make sure your docker/entrypoint.sh is executable
11
+ RUN chmod +x docker/entrypoint.sh
12
+
13
+ # Expose the necessary port
14
+ EXPOSE 4000/tcp
15
+
16
+ # Override the CMD instruction with your desired command and arguments
17
+ CMD ["--port", "4000", "--config", "config.yaml", "--detailed_debug", "--run_gunicorn"]
deploy/azure_resource_manager/azure_marketplace.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:8707cffcbd9ed9bda625246dc3108352ed33cfd878fd3966941d5e3efd915513
3
+ size 2371
deploy/azure_resource_manager/azure_marketplace/createUiDefinition.json ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "$schema": "https://schema.management.azure.com/schemas/0.1.2-preview/CreateUIDefinition.MultiVm.json#",
3
+ "handler": "Microsoft.Azure.CreateUIDef",
4
+ "version": "0.1.2-preview",
5
+ "parameters": {
6
+ "config": {
7
+ "isWizard": false,
8
+ "basics": { }
9
+ },
10
+ "basics": [ ],
11
+ "steps": [ ],
12
+ "outputs": { },
13
+ "resourceTypes": [ ]
14
+ }
15
+ }
deploy/azure_resource_manager/azure_marketplace/mainTemplate.json ADDED
@@ -0,0 +1,63 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
3
+ "contentVersion": "1.0.0.0",
4
+ "parameters": {
5
+ "imageName": {
6
+ "type": "string",
7
+ "defaultValue": "ghcr.io/berriai/litellm:main-latest"
8
+ },
9
+ "containerName": {
10
+ "type": "string",
11
+ "defaultValue": "litellm-container"
12
+ },
13
+ "dnsLabelName": {
14
+ "type": "string",
15
+ "defaultValue": "litellm"
16
+ },
17
+ "portNumber": {
18
+ "type": "int",
19
+ "defaultValue": 4000
20
+ }
21
+ },
22
+ "resources": [
23
+ {
24
+ "type": "Microsoft.ContainerInstance/containerGroups",
25
+ "apiVersion": "2021-03-01",
26
+ "name": "[parameters('containerName')]",
27
+ "location": "[resourceGroup().location]",
28
+ "properties": {
29
+ "containers": [
30
+ {
31
+ "name": "[parameters('containerName')]",
32
+ "properties": {
33
+ "image": "[parameters('imageName')]",
34
+ "resources": {
35
+ "requests": {
36
+ "cpu": 1,
37
+ "memoryInGB": 2
38
+ }
39
+ },
40
+ "ports": [
41
+ {
42
+ "port": "[parameters('portNumber')]"
43
+ }
44
+ ]
45
+ }
46
+ }
47
+ ],
48
+ "osType": "Linux",
49
+ "restartPolicy": "Always",
50
+ "ipAddress": {
51
+ "type": "Public",
52
+ "ports": [
53
+ {
54
+ "protocol": "tcp",
55
+ "port": "[parameters('portNumber')]"
56
+ }
57
+ ],
58
+ "dnsNameLabel": "[parameters('dnsLabelName')]"
59
+ }
60
+ }
61
+ }
62
+ ]
63
+ }
deploy/azure_resource_manager/main.bicep ADDED
@@ -0,0 +1,42 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ param imageName string = 'ghcr.io/berriai/litellm:main-latest'
2
+ param containerName string = 'litellm-container'
3
+ param dnsLabelName string = 'litellm'
4
+ param portNumber int = 4000
5
+
6
+ resource containerGroupName 'Microsoft.ContainerInstance/containerGroups@2021-03-01' = {
7
+ name: containerName
8
+ location: resourceGroup().location
9
+ properties: {
10
+ containers: [
11
+ {
12
+ name: containerName
13
+ properties: {
14
+ image: imageName
15
+ resources: {
16
+ requests: {
17
+ cpu: 1
18
+ memoryInGB: 2
19
+ }
20
+ }
21
+ ports: [
22
+ {
23
+ port: portNumber
24
+ }
25
+ ]
26
+ }
27
+ }
28
+ ]
29
+ osType: 'Linux'
30
+ restartPolicy: 'Always'
31
+ ipAddress: {
32
+ type: 'Public'
33
+ ports: [
34
+ {
35
+ protocol: 'tcp'
36
+ port: portNumber
37
+ }
38
+ ]
39
+ dnsNameLabel: dnsLabelName
40
+ }
41
+ }
42
+ }
deploy/charts/litellm-helm/.helmignore ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Patterns to ignore when building packages.
2
+ # This supports shell glob matching, relative path matching, and
3
+ # negation (prefixed with !). Only one pattern per line.
4
+ .DS_Store
5
+ # Common VCS dirs
6
+ .git/
7
+ .gitignore
8
+ .bzr/
9
+ .bzrignore
10
+ .hg/
11
+ .hgignore
12
+ .svn/
13
+ # Common backup files
14
+ *.swp
15
+ *.bak
16
+ *.tmp
17
+ *.orig
18
+ *~
19
+ # Various IDEs
20
+ .project
21
+ .idea/
22
+ *.tmproj
23
+ .vscode/
deploy/charts/litellm-helm/Chart.lock ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
 
1
+ dependencies:
2
+ - name: postgresql
3
+ repository: oci://registry-1.docker.io/bitnamicharts
4
+ version: 14.3.1
5
+ - name: redis
6
+ repository: oci://registry-1.docker.io/bitnamicharts
7
+ version: 18.19.1
8
+ digest: sha256:8660fe6287f9941d08c0902f3f13731079b8cecd2a5da2fbc54e5b7aae4a6f62
9
+ generated: "2024-03-10T02:28:52.275022+05:30"
deploy/charts/litellm-helm/Chart.yaml ADDED
@@ -0,0 +1,37 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ apiVersion: v2
2
+
3
+ # We can't call ourselves just "litellm" because then we couldn't publish to the
4
+ # same OCI repository as the "litellm" OCI image
5
+ name: litellm-helm
6
+ description: Call all LLM APIs using the OpenAI format
7
+
8
+ # A chart can be either an 'application' or a 'library' chart.
9
+ #
10
+ # Application charts are a collection of templates that can be packaged into versioned archives
11
+ # to be deployed.
12
+ #
13
+ # Library charts provide useful utilities or functions for the chart developer. They're included as
14
+ # a dependency of application charts to inject those utilities and functions into the rendering
15
+ # pipeline. Library charts do not define any templates and therefore cannot be deployed.
16
+ type: application
17
+
18
+ # This is the chart version. This version number should be incremented each time you make changes
19
+ # to the chart and its templates, including the app version.
20
+ # Versions are expected to follow Semantic Versioning (https://semver.org/)
21
+ version: 0.4.3
22
+
23
+ # This is the version number of the application being deployed. This version number should be
24
+ # incremented each time you make changes to the application. Versions are not expected to
25
+ # follow Semantic Versioning. They should reflect the version the application is using.
26
+ # It is recommended to use it with quotes.
27
+ appVersion: v1.50.2
28
+
29
+ dependencies:
30
+ - name: "postgresql"
31
+ version: ">=13.3.0"
32
+ repository: oci://registry-1.docker.io/bitnamicharts
33
+ condition: db.deployStandalone
34
+ - name: redis
35
+ version: ">=18.0.0"
36
+ repository: oci://registry-1.docker.io/bitnamicharts
37
+ condition: redis.enabled
deploy/charts/litellm-helm/README.md ADDED
@@ -0,0 +1,131 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Helm Chart for LiteLLM
2
+
3
+ > [!IMPORTANT]
4
+ > This is community maintained, Please make an issue if you run into a bug
5
+ > We recommend using [Docker or Kubernetes for production deployments](https://docs.litellm.ai/docs/proxy/prod)
6
+
7
+ ## Prerequisites
8
+
9
+ - Kubernetes 1.21+
10
+ - Helm 3.8.0+
11
+
12
+ If `db.deployStandalone` is used:
13
+ - PV provisioner support in the underlying infrastructure
14
+
15
+ If `db.useStackgresOperator` is used (not yet implemented):
16
+ - The Stackgres Operator must already be installed in the Kubernetes Cluster. This chart will **not** install the operator if it is missing.
17
+
18
+ ## Parameters
19
+
20
+ ### LiteLLM Proxy Deployment Settings
21
+
22
+ | Name | Description | Value |
23
+ | ---------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----- |
24
+ | `replicaCount` | The number of LiteLLM Proxy pods to be deployed | `1` |
25
+ | `masterkeySecretName` | The name of the Kubernetes Secret that contains the Master API Key for LiteLLM. If not specified, use the generated secret name. | N/A |
26
+ | `masterkeySecretKey` | The key within the Kubernetes Secret that contains the Master API Key for LiteLLM. If not specified, use `masterkey` as the key. | N/A |
27
+ | `masterkey` | The Master API Key for LiteLLM. If not specified, a random key is generated. | N/A |
28
+ | `environmentSecrets` | An optional array of Secret object names. The keys and values in these secrets will be presented to the LiteLLM proxy pod as environment variables. See below for an example Secret object. | `[]` |
29
+ | `environmentConfigMaps` | An optional array of ConfigMap object names. The keys and values in these configmaps will be presented to the LiteLLM proxy pod as environment variables. See below for an example Secret object. | `[]` |
30
+ | `image.repository` | LiteLLM Proxy image repository | `ghcr.io/berriai/litellm` |
31
+ | `image.pullPolicy` | LiteLLM Proxy image pull policy | `IfNotPresent` |
32
+ | `image.tag` | Overrides the image tag whose default the latest version of LiteLLM at the time this chart was published. | `""` |
33
+ | `imagePullSecrets` | Registry credentials for the LiteLLM and initContainer images. | `[]` |
34
+ | `serviceAccount.create` | Whether or not to create a Kubernetes Service Account for this deployment. The default is `false` because LiteLLM has no need to access the Kubernetes API. | `false` |
35
+ | `service.type` | Kubernetes Service type (e.g. `LoadBalancer`, `ClusterIP`, etc.) | `ClusterIP` |
36
+ | `service.port` | TCP port that the Kubernetes Service will listen on. Also the TCP port within the Pod that the proxy will listen on. | `4000` |
37
+ | `ingress.*` | See [values.yaml](./values.yaml) for example settings | N/A |
38
+ | `proxy_config.*` | See [values.yaml](./values.yaml) for default settings. See [example_config_yaml](../../../litellm/proxy/example_config_yaml/) for configuration examples. | N/A |
39
+ | `extraContainers[]` | An array of additional containers to be deployed as sidecars alongside the LiteLLM Proxy. | `[]` |
40
+
41
+ #### Example `environmentSecrets` Secret
42
+
43
+ ```
44
+ apiVersion: v1
45
+ kind: Secret
46
+ metadata:
47
+ name: litellm-envsecrets
48
+ data:
49
+ AZURE_OPENAI_API_KEY: TXlTZWN1cmVLM3k=
50
+ type: Opaque
51
+ ```
52
+
53
+ ### Database Settings
54
+ | Name | Description | Value |
55
+ | ---------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----- |
56
+ | `db.useExisting` | Use an existing Postgres database. A Kubernetes Secret object must exist that contains credentials for connecting to the database. An example secret object definition is provided below. | `false` |
57
+ | `db.endpoint` | If `db.useExisting` is `true`, this is the IP, Hostname or Service Name of the Postgres server to connect to. | `localhost` |
58
+ | `db.database` | If `db.useExisting` is `true`, the name of the existing database to connect to. | `litellm` |
59
+ | `db.url` | If `db.useExisting` is `true`, the connection url of the existing database to connect to can be overwritten with this value. | `postgresql://$(DATABASE_USERNAME):$(DATABASE_PASSWORD)@$(DATABASE_HOST)/$(DATABASE_NAME)` |
60
+ | `db.secret.name` | If `db.useExisting` is `true`, the name of the Kubernetes Secret that contains credentials. | `postgres` |
61
+ | `db.secret.usernameKey` | If `db.useExisting` is `true`, the name of the key within the Kubernetes Secret that holds the username for authenticating with the Postgres instance. | `username` |
62
+ | `db.secret.passwordKey` | If `db.useExisting` is `true`, the name of the key within the Kubernetes Secret that holds the password associates with the above user. | `password` |
63
+ | `db.useStackgresOperator` | Not yet implemented. | `false` |
64
+ | `db.deployStandalone` | Deploy a standalone, single instance deployment of Postgres, using the Bitnami postgresql chart. This is useful for getting started but doesn't provide HA or (by default) data backups. | `true` |
65
+ | `postgresql.*` | If `db.deployStandalone` is `true`, configuration passed to the Bitnami postgresql chart. See the [Bitnami Documentation](https://github.com/bitnami/charts/tree/main/bitnami/postgresql) for full configuration details. See [values.yaml](./values.yaml) for the default configuration. | See [values.yaml](./values.yaml) |
66
+ | `postgresql.auth.*` | If `db.deployStandalone` is `true`, care should be taken to ensure the default `password` and `postgres-password` values are **NOT** used. | `NoTaGrEaTpAsSwOrD` |
67
+
68
+ #### Example Postgres `db.useExisting` Secret
69
+ ```yaml
70
+ apiVersion: v1
71
+ kind: Secret
72
+ metadata:
73
+ name: postgres
74
+ data:
75
+ # Password for the "postgres" user
76
+ postgres-password: <some secure password, base64 encoded>
77
+ username: litellm
78
+ password: <some secure password, base64 encoded>
79
+ type: Opaque
80
+ ```
81
+
82
+ #### Examples for `environmentSecrets` and `environemntConfigMaps`
83
+
84
+ ```yaml
85
+ # Use config map for not-secret configuration data
86
+ apiVersion: v1
87
+ kind: ConfigMap
88
+ metadata:
89
+ name: litellm-env-configmap
90
+ data:
91
+ SOME_KEY: someValue
92
+ ANOTHER_KEY: anotherValue
93
+ ```
94
+
95
+ ```yaml
96
+ # Use secrets for things which are actually secret like API keys, credentials, etc
97
+ # Base64 encode the values stored in a Kubernetes Secret: $ pbpaste | base64 | pbcopy
98
+ # The --decode flag is convenient: $ pbpaste | base64 --decode
99
+
100
+ apiVersion: v1
101
+ kind: Secret
102
+ metadata:
103
+ name: litellm-env-secret
104
+ type: Opaque
105
+ data:
106
+ SOME_PASSWORD: cDZbUGVXeU5e0ZW # base64 encoded
107
+ ANOTHER_PASSWORD: AAZbUGVXeU5e0ZB # base64 encoded
108
+ ```
109
+
110
+ Source: [GitHub Gist from troyharvey](https://gist.github.com/troyharvey/4506472732157221e04c6b15e3b3f094)
111
+
112
+ ## Accessing the Admin UI
113
+ When browsing to the URL published per the settings in `ingress.*`, you will
114
+ be prompted for **Admin Configuration**. The **Proxy Endpoint** is the internal
115
+ (from the `litellm` pod's perspective) URL published by the `<RELEASE>-litellm`
116
+ Kubernetes Service. If the deployment uses the default settings for this
117
+ service, the **Proxy Endpoint** should be set to `http://<RELEASE>-litellm:4000`.
118
+
119
+ The **Proxy Key** is the value specified for `masterkey` or, if a `masterkey`
120
+ was not provided to the helm command line, the `masterkey` is a randomly
121
+ generated string stored in the `<RELEASE>-litellm-masterkey` Kubernetes Secret.
122
+
123
+ ```bash
124
+ kubectl -n litellm get secret <RELEASE>-litellm-masterkey -o jsonpath="{.data.masterkey}"
125
+ ```
126
+
127
+ ## Admin UI Limitations
128
+ At the time of writing, the Admin UI is unable to add models. This is because
129
+ it would need to update the `config.yaml` file which is a exposed ConfigMap, and
130
+ therefore, read-only. This is a limitation of this helm chart, not the Admin UI
131
+ itself.
deploy/charts/litellm-helm/charts/postgresql-14.3.1.tgz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:3c8125526b06833df32e2f626db34aeaedb29d38f03d15349db6604027d4a167
3
+ size 72928
deploy/charts/litellm-helm/charts/redis-18.19.1.tgz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b2fa1835f673a18002ca864c54fadac3c33789b26f6c5e58e2851b0b14a8f984
3
+ size 87594
deploy/charts/litellm-helm/ci/test-values.yaml ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ fullnameOverride: ""
2
+ # Disable database deployment and configuration
3
+ db:
4
+ deployStandalone: false
5
+ useExisting: false
6
+
7
+ # Test environment variables
8
+ envVars:
9
+ DD_ENV: "dev_helm"
10
+ DD_SERVICE: "litellm"
11
+ USE_DDTRACE: "true"
12
+
13
+ # Disable migration job since we're not using a database
14
+ migrationJob:
15
+ enabled: false
deploy/charts/litellm-helm/templates/NOTES.txt ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 1. Get the application URL by running these commands:
2
+ {{- if .Values.ingress.enabled }}
3
+ {{- range $host := .Values.ingress.hosts }}
4
+ {{- range .paths }}
5
+ http{{ if $.Values.ingress.tls }}s{{ end }}://{{ $host.host }}{{ .path }}
6
+ {{- end }}
7
+ {{- end }}
8
+ {{- else if contains "NodePort" .Values.service.type }}
9
+ export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "litellm.fullname" . }})
10
+ export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
11
+ echo http://$NODE_IP:$NODE_PORT
12
+ {{- else if contains "LoadBalancer" .Values.service.type }}
13
+ NOTE: It may take a few minutes for the LoadBalancer IP to be available.
14
+ You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "litellm.fullname" . }}'
15
+ export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "litellm.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
16
+ echo http://$SERVICE_IP:{{ .Values.service.port }}
17
+ {{- else if contains "ClusterIP" .Values.service.type }}
18
+ export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "litellm.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
19
+ export CONTAINER_PORT=$(kubectl get pod --namespace {{ .Release.Namespace }} $POD_NAME -o jsonpath="{.spec.containers[0].ports[0].containerPort}")
20
+ echo "Visit http://127.0.0.1:8080 to use your application"
21
+ kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:$CONTAINER_PORT
22
+ {{- end }}
deploy/charts/litellm-helm/templates/_helpers.tpl ADDED
@@ -0,0 +1,84 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {{/*
2
+ Expand the name of the chart.
3
+ */}}
4
+ {{- define "litellm.name" -}}
5
+ {{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
6
+ {{- end }}
7
+
8
+ {{/*
9
+ Create a default fully qualified app name.
10
+ We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
11
+ If release name contains chart name it will be used as a full name.
12
+ */}}
13
+ {{- define "litellm.fullname" -}}
14
+ {{- if .Values.fullnameOverride }}
15
+ {{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}
16
+ {{- else }}
17
+ {{- $name := default .Chart.Name .Values.nameOverride }}
18
+ {{- if contains $name .Release.Name }}
19
+ {{- .Release.Name | trunc 63 | trimSuffix "-" }}
20
+ {{- else }}
21
+ {{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }}
22
+ {{- end }}
23
+ {{- end }}
24
+ {{- end }}
25
+
26
+ {{/*
27
+ Create chart name and version as used by the chart label.
28
+ */}}
29
+ {{- define "litellm.chart" -}}
30
+ {{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
31
+ {{- end }}
32
+
33
+ {{/*
34
+ Common labels
35
+ */}}
36
+ {{- define "litellm.labels" -}}
37
+ helm.sh/chart: {{ include "litellm.chart" . }}
38
+ {{ include "litellm.selectorLabels" . }}
39
+ {{- if .Chart.AppVersion }}
40
+ app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
41
+ {{- end }}
42
+ app.kubernetes.io/managed-by: {{ .Release.Service }}
43
+ {{- end }}
44
+
45
+ {{/*
46
+ Selector labels
47
+ */}}
48
+ {{- define "litellm.selectorLabels" -}}
49
+ app.kubernetes.io/name: {{ include "litellm.name" . }}
50
+ app.kubernetes.io/instance: {{ .Release.Name }}
51
+ {{- end }}
52
+
53
+ {{/*
54
+ Create the name of the service account to use
55
+ */}}
56
+ {{- define "litellm.serviceAccountName" -}}
57
+ {{- if .Values.serviceAccount.create }}
58
+ {{- default (include "litellm.fullname" .) .Values.serviceAccount.name }}
59
+ {{- else }}
60
+ {{- default "default" .Values.serviceAccount.name }}
61
+ {{- end }}
62
+ {{- end }}
63
+
64
+ {{/*
65
+ Get redis service name
66
+ */}}
67
+ {{- define "litellm.redis.serviceName" -}}
68
+ {{- if and (eq .Values.redis.architecture "standalone") .Values.redis.sentinel.enabled -}}
69
+ {{- printf "%s-%s" .Release.Name (default "redis" .Values.redis.nameOverride | trunc 63 | trimSuffix "-") -}}
70
+ {{- else -}}
71
+ {{- printf "%s-%s-master" .Release.Name (default "redis" .Values.redis.nameOverride | trunc 63 | trimSuffix "-") -}}
72
+ {{- end -}}
73
+ {{- end -}}
74
+
75
+ {{/*
76
+ Get redis service port
77
+ */}}
78
+ {{- define "litellm.redis.port" -}}
79
+ {{- if .Values.redis.sentinel.enabled -}}
80
+ {{ .Values.redis.sentinel.service.ports.sentinel }}
81
+ {{- else -}}
82
+ {{ .Values.redis.master.service.ports.redis }}
83
+ {{- end -}}
84
+ {{- end -}}
deploy/charts/litellm-helm/templates/configmap-litellm.yaml ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
 
1
+ apiVersion: v1
2
+ kind: ConfigMap
3
+ metadata:
4
+ name: {{ include "litellm.fullname" . }}-config
5
+ data:
6
+ config.yaml: |
7
+ {{ .Values.proxy_config | toYaml | indent 6 }}
deploy/charts/litellm-helm/templates/deployment.yaml ADDED
@@ -0,0 +1,185 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ apiVersion: apps/v1
2
+ kind: Deployment
3
+ metadata:
4
+ name: {{ include "litellm.fullname" . }}
5
+ labels:
6
+ {{- include "litellm.labels" . | nindent 4 }}
7
+ spec:
8
+ {{- if not .Values.autoscaling.enabled }}
9
+ replicas: {{ .Values.replicaCount }}
10
+ {{- end }}
11
+ selector:
12
+ matchLabels:
13
+ {{- include "litellm.selectorLabels" . | nindent 6 }}
14
+ template:
15
+ metadata:
16
+ annotations:
17
+ checksum/config: {{ include (print $.Template.BasePath "/configmap-litellm.yaml") . | sha256sum }}
18
+ {{- with .Values.podAnnotations }}
19
+ {{- toYaml . | nindent 8 }}
20
+ {{- end }}
21
+ labels:
22
+ {{- include "litellm.labels" . | nindent 8 }}
23
+ {{- with .Values.podLabels }}
24
+ {{- toYaml . | nindent 8 }}
25
+ {{- end }}
26
+ spec:
27
+ {{- with .Values.imagePullSecrets }}
28
+ imagePullSecrets:
29
+ {{- toYaml . | nindent 8 }}
30
+ {{- end }}
31
+ serviceAccountName: {{ include "litellm.serviceAccountName" . }}
32
+ securityContext:
33
+ {{- toYaml .Values.podSecurityContext | nindent 8 }}
34
+ containers:
35
+ - name: {{ include "litellm.name" . }}
36
+ securityContext:
37
+ {{- toYaml .Values.securityContext | nindent 12 }}
38
+ image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default (printf "main-%s" .Chart.AppVersion) }}"
39
+ imagePullPolicy: {{ .Values.image.pullPolicy }}
40
+ env:
41
+ - name: HOST
42
+ value: "{{ .Values.listen | default "0.0.0.0" }}"
43
+ - name: PORT
44
+ value: {{ .Values.service.port | quote}}
45
+ {{- if .Values.db.deployStandalone }}
46
+ - name: DATABASE_USERNAME
47
+ valueFrom:
48
+ secretKeyRef:
49
+ name: {{ include "litellm.fullname" . }}-dbcredentials
50
+ key: username
51
+ - name: DATABASE_PASSWORD
52
+ valueFrom:
53
+ secretKeyRef:
54
+ name: {{ include "litellm.fullname" . }}-dbcredentials
55
+ key: password
56
+ - name: DATABASE_HOST
57
+ value: {{ .Release.Name }}-postgresql
58
+ - name: DATABASE_NAME
59
+ value: litellm
60
+ {{- else if .Values.db.useExisting }}
61
+ - name: DATABASE_USERNAME
62
+ valueFrom:
63
+ secretKeyRef:
64
+ name: {{ .Values.db.secret.name }}
65
+ key: {{ .Values.db.secret.usernameKey }}
66
+ - name: DATABASE_PASSWORD
67
+ valueFrom:
68
+ secretKeyRef:
69
+ name: {{ .Values.db.secret.name }}
70
+ key: {{ .Values.db.secret.passwordKey }}
71
+ - name: DATABASE_HOST
72
+ value: {{ .Values.db.endpoint }}
73
+ - name: DATABASE_NAME
74
+ value: {{ .Values.db.database }}
75
+ - name: DATABASE_URL
76
+ value: {{ .Values.db.url | quote }}
77
+ {{- end }}
78
+ - name: PROXY_MASTER_KEY
79
+ valueFrom:
80
+ secretKeyRef:
81
+ name: {{ .Values.masterkeySecretName | default (printf "%s-masterkey" (include "litellm.fullname" .)) }}
82
+ key: {{ .Values.masterkeySecretKey | default "masterkey" }}
83
+ {{- if .Values.redis.enabled }}
84
+ - name: REDIS_HOST
85
+ value: {{ include "litellm.redis.serviceName" . }}
86
+ - name: REDIS_PORT
87
+ value: {{ include "litellm.redis.port" . | quote }}
88
+ - name: REDIS_PASSWORD
89
+ valueFrom:
90
+ secretKeyRef:
91
+ name: {{ include "redis.secretName" .Subcharts.redis }}
92
+ key: {{include "redis.secretPasswordKey" .Subcharts.redis }}
93
+ {{- end }}
94
+ {{- if .Values.envVars }}
95
+ {{- range $key, $val := .Values.envVars }}
96
+ - name: {{ $key }}
97
+ value: {{ $val | quote }}
98
+ {{- end }}
99
+ {{- end }}
100
+ {{- with .Values.extraEnvVars }}
101
+ {{- toYaml . | nindent 12 }}
102
+ {{- end }}
103
+ envFrom:
104
+ {{- range .Values.environmentSecrets }}
105
+ - secretRef:
106
+ name: {{ . }}
107
+ {{- end }}
108
+ {{- range .Values.environmentConfigMaps }}
109
+ - configMapRef:
110
+ name: {{ . }}
111
+ {{- end }}
112
+ args:
113
+ - --config
114
+ - /etc/litellm/config.yaml
115
+ ports:
116
+ - name: http
117
+ containerPort: {{ .Values.service.port }}
118
+ protocol: TCP
119
+ livenessProbe:
120
+ httpGet:
121
+ path: /health/liveliness
122
+ port: http
123
+ readinessProbe:
124
+ httpGet:
125
+ path: /health/readiness
126
+ port: http
127
+ # Give the container time to start up. Up to 5 minutes (10 * 30 seconds)
128
+ startupProbe:
129
+ httpGet:
130
+ path: /health/readiness
131
+ port: http
132
+ failureThreshold: 30
133
+ periodSeconds: 10
134
+ resources:
135
+ {{- toYaml .Values.resources | nindent 12 }}
136
+ volumeMounts:
137
+ - name: litellm-config
138
+ mountPath: /etc/litellm/
139
+ {{ if .Values.securityContext.readOnlyRootFilesystem }}
140
+ - name: tmp
141
+ mountPath: /tmp
142
+ - name: cache
143
+ mountPath: /.cache
144
+ - name: npm
145
+ mountPath: /.npm
146
+ {{- end }}
147
+ {{- with .Values.volumeMounts }}
148
+ {{- toYaml . | nindent 12 }}
149
+ {{- end }}
150
+ {{- with .Values.extraContainers }}
151
+ {{- toYaml . | nindent 8 }}
152
+ {{- end }}
153
+ volumes:
154
+ {{ if .Values.securityContext.readOnlyRootFilesystem }}
155
+ - name: tmp
156
+ emptyDir:
157
+ sizeLimit: 500Mi
158
+ - name: cache
159
+ emptyDir:
160
+ sizeLimit: 500Mi
161
+ - name: npm
162
+ emptyDir:
163
+ sizeLimit: 500Mi
164
+ {{- end }}
165
+ - name: litellm-config
166
+ configMap:
167
+ name: {{ include "litellm.fullname" . }}-config
168
+ items:
169
+ - key: "config.yaml"
170
+ path: "config.yaml"
171
+ {{- with .Values.volumes }}
172
+ {{- toYaml . | nindent 8 }}
173
+ {{- end }}
174
+ {{- with .Values.nodeSelector }}
175
+ nodeSelector:
176
+ {{- toYaml . | nindent 8 }}
177
+ {{- end }}
178
+ {{- with .Values.affinity }}
179
+ affinity:
180
+ {{- toYaml . | nindent 8 }}
181
+ {{- end }}
182
+ {{- with .Values.tolerations }}
183
+ tolerations:
184
+ {{- toYaml . | nindent 8 }}
185
+ {{- end }}
deploy/charts/litellm-helm/templates/hpa.yaml ADDED
@@ -0,0 +1,32 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {{- if .Values.autoscaling.enabled }}
2
+ apiVersion: autoscaling/v2
3
+ kind: HorizontalPodAutoscaler
4
+ metadata:
5
+ name: {{ include "litellm.fullname" . }}
6
+ labels:
7
+ {{- include "litellm.labels" . | nindent 4 }}
8
+ spec:
9
+ scaleTargetRef:
10
+ apiVersion: apps/v1
11
+ kind: Deployment
12
+ name: {{ include "litellm.fullname" . }}
13
+ minReplicas: {{ .Values.autoscaling.minReplicas }}
14
+ maxReplicas: {{ .Values.autoscaling.maxReplicas }}
15
+ metrics:
16
+ {{- if .Values.autoscaling.targetCPUUtilizationPercentage }}
17
+ - type: Resource
18
+ resource:
19
+ name: cpu
20
+ target:
21
+ type: Utilization
22
+ averageUtilization: {{ .Values.autoscaling.targetCPUUtilizationPercentage }}
23
+ {{- end }}
24
+ {{- if .Values.autoscaling.targetMemoryUtilizationPercentage }}
25
+ - type: Resource
26
+ resource:
27
+ name: memory
28
+ target:
29
+ type: Utilization
30
+ averageUtilization: {{ .Values.autoscaling.targetMemoryUtilizationPercentage }}
31
+ {{- end }}
32
+ {{- end }}
deploy/charts/litellm-helm/templates/ingress.yaml ADDED
@@ -0,0 +1,61 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {{- if .Values.ingress.enabled -}}
2
+ {{- $fullName := include "litellm.fullname" . -}}
3
+ {{- $svcPort := .Values.service.port -}}
4
+ {{- if and .Values.ingress.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }}
5
+ {{- if not (hasKey .Values.ingress.annotations "kubernetes.io/ingress.class") }}
6
+ {{- $_ := set .Values.ingress.annotations "kubernetes.io/ingress.class" .Values.ingress.className}}
7
+ {{- end }}
8
+ {{- end }}
9
+ {{- if semverCompare ">=1.19-0" .Capabilities.KubeVersion.GitVersion -}}
10
+ apiVersion: networking.k8s.io/v1
11
+ {{- else if semverCompare ">=1.14-0" .Capabilities.KubeVersion.GitVersion -}}
12
+ apiVersion: networking.k8s.io/v1beta1
13
+ {{- else -}}
14
+ apiVersion: extensions/v1beta1
15
+ {{- end }}
16
+ kind: Ingress
17
+ metadata:
18
+ name: {{ $fullName }}
19
+ labels:
20
+ {{- include "litellm.labels" . | nindent 4 }}
21
+ {{- with .Values.ingress.annotations }}
22
+ annotations:
23
+ {{- toYaml . | nindent 4 }}
24
+ {{- end }}
25
+ spec:
26
+ {{- if and .Values.ingress.className (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion) }}
27
+ ingressClassName: {{ .Values.ingress.className }}
28
+ {{- end }}
29
+ {{- if .Values.ingress.tls }}
30
+ tls:
31
+ {{- range .Values.ingress.tls }}
32
+ - hosts:
33
+ {{- range .hosts }}
34
+ - {{ . | quote }}
35
+ {{- end }}
36
+ secretName: {{ .secretName }}
37
+ {{- end }}
38
+ {{- end }}
39
+ rules:
40
+ {{- range .Values.ingress.hosts }}
41
+ - host: {{ .host | quote }}
42
+ http:
43
+ paths:
44
+ {{- range .paths }}
45
+ - path: {{ .path }}
46
+ {{- if and .pathType (semverCompare ">=1.18-0" $.Capabilities.KubeVersion.GitVersion) }}
47
+ pathType: {{ .pathType }}
48
+ {{- end }}
49
+ backend:
50
+ {{- if semverCompare ">=1.19-0" $.Capabilities.KubeVersion.GitVersion }}
51
+ service:
52
+ name: {{ $fullName }}
53
+ port:
54
+ number: {{ $svcPort }}
55
+ {{- else }}
56
+ serviceName: {{ $fullName }}
57
+ servicePort: {{ $svcPort }}
58
+ {{- end }}
59
+ {{- end }}
60
+ {{- end }}
61
+ {{- end }}
deploy/charts/litellm-helm/templates/migrations-job.yaml ADDED
@@ -0,0 +1,71 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {{- if .Values.migrationJob.enabled }}
2
+ # This job runs the prisma migrations for the LiteLLM DB.
3
+ apiVersion: batch/v1
4
+ kind: Job
5
+ metadata:
6
+ name: {{ include "litellm.fullname" . }}-migrations
7
+ annotations:
8
+ argocd.argoproj.io/hook: PreSync
9
+ argocd.argoproj.io/hook-delete-policy: BeforeHookCreation # delete old migration on a new deploy in case the migration needs to make updates
10
+ checksum/config: {{ toYaml .Values | sha256sum }}
11
+ spec:
12
+ template:
13
+ metadata:
14
+ annotations:
15
+ {{- with .Values.migrationJob.annotations }}
16
+ {{- toYaml . | nindent 8 }}
17
+ {{- end }}
18
+ spec:
19
+ serviceAccountName: {{ include "litellm.serviceAccountName" . }}
20
+ containers:
21
+ - name: prisma-migrations
22
+ image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default (printf "main-%s" .Chart.AppVersion) }}"
23
+ imagePullPolicy: {{ .Values.image.pullPolicy }}
24
+ securityContext:
25
+ {{- toYaml .Values.securityContext | nindent 12 }}
26
+ command: ["python", "litellm/proxy/prisma_migration.py"]
27
+ workingDir: "/app"
28
+ env:
29
+ {{- if .Values.db.useExisting }}
30
+ - name: DATABASE_USERNAME
31
+ valueFrom:
32
+ secretKeyRef:
33
+ name: {{ .Values.db.secret.name }}
34
+ key: {{ .Values.db.secret.usernameKey }}
35
+ - name: DATABASE_PASSWORD
36
+ valueFrom:
37
+ secretKeyRef:
38
+ name: {{ .Values.db.secret.name }}
39
+ key: {{ .Values.db.secret.passwordKey }}
40
+ - name: DATABASE_HOST
41
+ value: {{ .Values.db.endpoint }}
42
+ - name: DATABASE_NAME
43
+ value: {{ .Values.db.database }}
44
+ - name: DATABASE_URL
45
+ value: {{ .Values.db.url | quote }}
46
+ {{- else }}
47
+ - name: DATABASE_URL
48
+ value: postgresql://{{ .Values.postgresql.auth.username }}:{{ .Values.postgresql.auth.password }}@{{ .Release.Name }}-postgresql/{{ .Values.postgresql.auth.database }}
49
+ {{- end }}
50
+ - name: DISABLE_SCHEMA_UPDATE
51
+ value: "false" # always run the migration from the Helm PreSync hook, override the value set
52
+ {{- with .Values.volumeMounts }}
53
+ volumeMounts:
54
+ {{- toYaml . | nindent 12 }}
55
+ {{- end }}
56
+ {{- with .Values.volumes }}
57
+ volumes:
58
+ {{- toYaml . | nindent 8 }}
59
+ {{- end }}
60
+ restartPolicy: OnFailure
61
+ {{- with .Values.affinity }}
62
+ affinity:
63
+ {{- toYaml . | nindent 8 }}
64
+ {{- end }}
65
+ {{- with .Values.tolerations }}
66
+ tolerations:
67
+ {{- toYaml . | nindent 8 }}
68
+ {{- end }}
69
+ ttlSecondsAfterFinished: {{ .Values.migrationJob.ttlSecondsAfterFinished }}
70
+ backoffLimit: {{ .Values.migrationJob.backoffLimit }}
71
+ {{- end }}
deploy/charts/litellm-helm/templates/secret-dbcredentials.yaml ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {{- if .Values.db.deployStandalone -}}
2
+ apiVersion: v1
3
+ kind: Secret
4
+ metadata:
5
+ name: {{ include "litellm.fullname" . }}-dbcredentials
6
+ data:
7
+ # Password for the "postgres" user
8
+ postgres-password: {{ ( index .Values.postgresql.auth "postgres-password") | default "litellm" | b64enc }}
9
+ username: {{ .Values.postgresql.auth.username | default "litellm" | b64enc }}
10
+ password: {{ .Values.postgresql.auth.password | default "litellm" | b64enc }}
11
+ type: Opaque
12
+ {{- end -}}
deploy/charts/litellm-helm/templates/secret-masterkey.yaml ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ {{- if not .Values.masterkeySecretName }}
2
+ {{ $masterkey := (.Values.masterkey | default (randAlphaNum 17)) }}
3
+ apiVersion: v1
4
+ kind: Secret
5
+ metadata:
6
+ name: {{ include "litellm.fullname" . }}-masterkey
7
+ data:
8
+ masterkey: {{ $masterkey | b64enc }}
9
+ type: Opaque
10
+ {{- end }}
deploy/charts/litellm-helm/templates/service.yaml ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ apiVersion: v1
2
+ kind: Service
3
+ metadata:
4
+ name: {{ include "litellm.fullname" . }}
5
+ {{- with .Values.service.annotations }}
6
+ annotations:
7
+ {{- toYaml . | nindent 4 }}
8
+ {{- end }}
9
+ labels:
10
+ {{- include "litellm.labels" . | nindent 4 }}
11
+ spec:
12
+ type: {{ .Values.service.type }}
13
+ ports:
14
+ - port: {{ .Values.service.port }}
15
+ targetPort: http
16
+ protocol: TCP
17
+ name: http
18
+ selector:
19
+ {{- include "litellm.selectorLabels" . | nindent 4 }}
deploy/charts/litellm-helm/templates/serviceaccount.yaml ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {{- if .Values.serviceAccount.create -}}
2
+ apiVersion: v1
3
+ kind: ServiceAccount
4
+ metadata:
5
+ name: {{ include "litellm.serviceAccountName" . }}
6
+ labels:
7
+ {{- include "litellm.labels" . | nindent 4 }}
8
+ {{- with .Values.serviceAccount.annotations }}
9
+ annotations:
10
+ {{- toYaml . | nindent 4 }}
11
+ {{- end }}
12
+ automountServiceAccountToken: {{ .Values.serviceAccount.automount }}
13
+ {{- end }}
deploy/charts/litellm-helm/templates/tests/test-connection.yaml ADDED
@@ -0,0 +1,25 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ apiVersion: v1
2
+ kind: Pod
3
+ metadata:
4
+ name: "{{ include "litellm.fullname" . }}-test-connection"
5
+ labels:
6
+ {{- include "litellm.labels" . | nindent 4 }}
7
+ annotations:
8
+ "helm.sh/hook": test
9
+ spec:
10
+ containers:
11
+ - name: wget
12
+ image: busybox
13
+ command: ['sh', '-c']
14
+ args:
15
+ - |
16
+ # Wait for a bit to allow the service to be ready
17
+ sleep 10
18
+ # Try multiple times with a delay between attempts
19
+ for i in $(seq 1 30); do
20
+ wget -T 5 "{{ include "litellm.fullname" . }}:{{ .Values.service.port }}/health/readiness" && exit 0
21
+ echo "Attempt $i failed, waiting..."
22
+ sleep 2
23
+ done
24
+ exit 1
25
+ restartPolicy: Never
deploy/charts/litellm-helm/templates/tests/test-env-vars.yaml ADDED
@@ -0,0 +1,43 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ apiVersion: v1
2
+ kind: Pod
3
+ metadata:
4
+ name: "{{ include "litellm.fullname" . }}-env-test"
5
+ labels:
6
+ {{- include "litellm.labels" . | nindent 4 }}
7
+ annotations:
8
+ "helm.sh/hook": test
9
+ spec:
10
+ containers:
11
+ - name: test
12
+ image: busybox
13
+ command: ['sh', '-c']
14
+ args:
15
+ - |
16
+ # Test DD_ENV
17
+ if [ "$DD_ENV" != "dev_helm" ]; then
18
+ echo "❌ Environment variable DD_ENV mismatch. Expected: dev_helm, Got: $DD_ENV"
19
+ exit 1
20
+ fi
21
+ echo "✅ Environment variable DD_ENV matches expected value: $DD_ENV"
22
+
23
+ # Test DD_SERVICE
24
+ if [ "$DD_SERVICE" != "litellm" ]; then
25
+ echo "❌ Environment variable DD_SERVICE mismatch. Expected: litellm, Got: $DD_SERVICE"
26
+ exit 1
27
+ fi
28
+ echo "✅ Environment variable DD_SERVICE matches expected value: $DD_SERVICE"
29
+
30
+ # Test USE_DDTRACE
31
+ if [ "$USE_DDTRACE" != "true" ]; then
32
+ echo "❌ Environment variable USE_DDTRACE mismatch. Expected: true, Got: $USE_DDTRACE"
33
+ exit 1
34
+ fi
35
+ echo "✅ Environment variable USE_DDTRACE matches expected value: $USE_DDTRACE"
36
+ env:
37
+ - name: DD_ENV
38
+ value: {{ .Values.envVars.DD_ENV | quote }}
39
+ - name: DD_SERVICE
40
+ value: {{ .Values.envVars.DD_SERVICE | quote }}
41
+ - name: USE_DDTRACE
42
+ value: {{ .Values.envVars.USE_DDTRACE | quote }}
43
+ restartPolicy: Never
deploy/charts/litellm-helm/tests/deployment_tests.yaml ADDED
@@ -0,0 +1,117 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ suite: test deployment
2
+ templates:
3
+ - deployment.yaml
4
+ - configmap-litellm.yaml
5
+ tests:
6
+ - it: should work
7
+ template: deployment.yaml
8
+ set:
9
+ image.tag: test
10
+ asserts:
11
+ - isKind:
12
+ of: Deployment
13
+ - matchRegex:
14
+ path: metadata.name
15
+ pattern: -litellm$
16
+ - equal:
17
+ path: spec.template.spec.containers[0].image
18
+ value: ghcr.io/berriai/litellm-database:test
19
+ - it: should work with tolerations
20
+ template: deployment.yaml
21
+ set:
22
+ tolerations:
23
+ - key: node-role.kubernetes.io/master
24
+ operator: Exists
25
+ effect: NoSchedule
26
+ asserts:
27
+ - equal:
28
+ path: spec.template.spec.tolerations[0].key
29
+ value: node-role.kubernetes.io/master
30
+ - equal:
31
+ path: spec.template.spec.tolerations[0].operator
32
+ value: Exists
33
+ - it: should work with affinity
34
+ template: deployment.yaml
35
+ set:
36
+ affinity:
37
+ nodeAffinity:
38
+ requiredDuringSchedulingIgnoredDuringExecution:
39
+ nodeSelectorTerms:
40
+ - matchExpressions:
41
+ - key: topology.kubernetes.io/zone
42
+ operator: In
43
+ values:
44
+ - antarctica-east1
45
+ asserts:
46
+ - equal:
47
+ path: spec.template.spec.affinity.nodeAffinity.requiredDuringSchedulingIgnoredDuringExecution.nodeSelectorTerms[0].matchExpressions[0].key
48
+ value: topology.kubernetes.io/zone
49
+ - equal:
50
+ path: spec.template.spec.affinity.nodeAffinity.requiredDuringSchedulingIgnoredDuringExecution.nodeSelectorTerms[0].matchExpressions[0].operator
51
+ value: In
52
+ - equal:
53
+ path: spec.template.spec.affinity.nodeAffinity.requiredDuringSchedulingIgnoredDuringExecution.nodeSelectorTerms[0].matchExpressions[0].values[0]
54
+ value: antarctica-east1
55
+ - it: should work without masterkeySecretName or masterkeySecretKey
56
+ template: deployment.yaml
57
+ set:
58
+ masterkeySecretName: ""
59
+ masterkeySecretKey: ""
60
+ asserts:
61
+ - contains:
62
+ path: spec.template.spec.containers[0].env
63
+ content:
64
+ name: PROXY_MASTER_KEY
65
+ valueFrom:
66
+ secretKeyRef:
67
+ name: RELEASE-NAME-litellm-masterkey
68
+ key: masterkey
69
+ - it: should work with masterkeySecretName and masterkeySecretKey
70
+ template: deployment.yaml
71
+ set:
72
+ masterkeySecretName: my-secret
73
+ masterkeySecretKey: my-key
74
+ asserts:
75
+ - contains:
76
+ path: spec.template.spec.containers[0].env
77
+ content:
78
+ name: PROXY_MASTER_KEY
79
+ valueFrom:
80
+ secretKeyRef:
81
+ name: my-secret
82
+ key: my-key
83
+ - it: should work with extraEnvVars
84
+ template: deployment.yaml
85
+ set:
86
+ extraEnvVars:
87
+ - name: EXTRA_ENV_VAR
88
+ valueFrom:
89
+ fieldRef:
90
+ fieldPath: metadata.labels['env']
91
+ asserts:
92
+ - contains:
93
+ path: spec.template.spec.containers[0].env
94
+ content:
95
+ name: EXTRA_ENV_VAR
96
+ valueFrom:
97
+ fieldRef:
98
+ fieldPath: metadata.labels['env']
99
+ - it: should work with both extraEnvVars and envVars
100
+ template: deployment.yaml
101
+ set:
102
+ envVars:
103
+ ENV_VAR: ENV_VAR_VALUE
104
+ extraEnvVars:
105
+ - name: EXTRA_ENV_VAR
106
+ value: EXTRA_ENV_VAR_VALUE
107
+ asserts:
108
+ - contains:
109
+ path: spec.template.spec.containers[0].env
110
+ content:
111
+ name: ENV_VAR
112
+ value: ENV_VAR_VALUE
113
+ - contains:
114
+ path: spec.template.spec.containers[0].env
115
+ content:
116
+ name: EXTRA_ENV_VAR
117
+ value: EXTRA_ENV_VAR_VALUE
deploy/charts/litellm-helm/tests/masterkey-secret_tests.yaml ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ suite: test masterkey secret
2
+ templates:
3
+ - secret-masterkey.yaml
4
+ tests:
5
+ - it: should create a secret if masterkeySecretName is not set
6
+ template: secret-masterkey.yaml
7
+ set:
8
+ masterkeySecretName: ""
9
+ asserts:
10
+ - isKind:
11
+ of: Secret
12
+ - it: should not create a secret if masterkeySecretName is set
13
+ template: secret-masterkey.yaml
14
+ set:
15
+ masterkeySecretName: my-secret
16
+ asserts:
17
+ - hasDocuments:
18
+ count: 0
deploy/charts/litellm-helm/values.yaml ADDED
@@ -0,0 +1,209 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Default values for litellm.
2
+ # This is a YAML-formatted file.
3
+ # Declare variables to be passed into your templates.
4
+
5
+ replicaCount: 1
6
+
7
+ image:
8
+ # Use "ghcr.io/berriai/litellm-database" for optimized image with database
9
+ repository: ghcr.io/berriai/litellm-database
10
+ pullPolicy: Always
11
+ # Overrides the image tag whose default is the chart appVersion.
12
+ # tag: "main-latest"
13
+ tag: ""
14
+
15
+ imagePullSecrets: []
16
+ nameOverride: "litellm"
17
+ fullnameOverride: ""
18
+
19
+ serviceAccount:
20
+ # Specifies whether a service account should be created
21
+ create: false
22
+ # Automatically mount a ServiceAccount's API credentials?
23
+ automount: true
24
+ # Annotations to add to the service account
25
+ annotations: {}
26
+ # The name of the service account to use.
27
+ # If not set and create is true, a name is generated using the fullname template
28
+ name: ""
29
+
30
+ podAnnotations: {}
31
+ podLabels: {}
32
+
33
+ # At the time of writing, the litellm docker image requires write access to the
34
+ # filesystem on startup so that prisma can install some dependencies.
35
+ podSecurityContext: {}
36
+ securityContext: {}
37
+ # capabilities:
38
+ # drop:
39
+ # - ALL
40
+ # readOnlyRootFilesystem: false
41
+ # runAsNonRoot: true
42
+ # runAsUser: 1000
43
+
44
+ # A list of Kubernetes Secret objects that will be exported to the LiteLLM proxy
45
+ # pod as environment variables. These secrets can then be referenced in the
46
+ # configuration file (or "litellm" ConfigMap) with `os.environ/<Env Var Name>`
47
+ environmentSecrets: []
48
+ # - litellm-env-secret
49
+
50
+ # A list of Kubernetes ConfigMap objects that will be exported to the LiteLLM proxy
51
+ # pod as environment variables. The ConfigMap kv-pairs can then be referenced in the
52
+ # configuration file (or "litellm" ConfigMap) with `os.environ/<Env Var Name>`
53
+ environmentConfigMaps: []
54
+ # - litellm-env-configmap
55
+
56
+ service:
57
+ type: ClusterIP
58
+ port: 4000
59
+
60
+ ingress:
61
+ enabled: false
62
+ className: "nginx"
63
+ annotations: {}
64
+ # kubernetes.io/ingress.class: nginx
65
+ # kubernetes.io/tls-acme: "true"
66
+ hosts:
67
+ - host: api.example.local
68
+ paths:
69
+ - path: /
70
+ pathType: ImplementationSpecific
71
+ tls: []
72
+ # - secretName: chart-example-tls
73
+ # hosts:
74
+ # - chart-example.local
75
+
76
+ # masterkey: changeit
77
+
78
+ # if set, use this secret for the master key; otherwise, autogenerate a new one
79
+ masterkeySecretName: ""
80
+
81
+ # if set, use this secret key for the master key; otherwise, use the default key
82
+ masterkeySecretKey: ""
83
+
84
+ # The elements within proxy_config are rendered as config.yaml for the proxy
85
+ # Examples: https://github.com/BerriAI/litellm/tree/main/litellm/proxy/example_config_yaml
86
+ # Reference: https://docs.litellm.ai/docs/proxy/configs
87
+ proxy_config:
88
+ model_list:
89
+ # At least one model must exist for the proxy to start.
90
+ - model_name: gpt-3.5-turbo
91
+ litellm_params:
92
+ model: gpt-3.5-turbo
93
+ api_key: eXaMpLeOnLy
94
+ - model_name: fake-openai-endpoint
95
+ litellm_params:
96
+ model: openai/fake
97
+ api_key: fake-key
98
+ api_base: https://exampleopenaiendpoint-production.up.railway.app/
99
+ general_settings:
100
+ master_key: os.environ/PROXY_MASTER_KEY
101
+
102
+ resources: {}
103
+ # We usually recommend not to specify default resources and to leave this as a conscious
104
+ # choice for the user. This also increases chances charts run on environments with little
105
+ # resources, such as Minikube. If you do want to specify resources, uncomment the following
106
+ # lines, adjust them as necessary, and remove the curly braces after 'resources:'.
107
+ # limits:
108
+ # cpu: 100m
109
+ # memory: 128Mi
110
+ # requests:
111
+ # cpu: 100m
112
+ # memory: 128Mi
113
+
114
+ autoscaling:
115
+ enabled: false
116
+ minReplicas: 1
117
+ maxReplicas: 100
118
+ targetCPUUtilizationPercentage: 80
119
+ # targetMemoryUtilizationPercentage: 80
120
+
121
+ # Additional volumes on the output Deployment definition.
122
+ volumes: []
123
+ # - name: foo
124
+ # secret:
125
+ # secretName: mysecret
126
+ # optional: false
127
+
128
+ # Additional volumeMounts on the output Deployment definition.
129
+ volumeMounts: []
130
+ # - name: foo
131
+ # mountPath: "/etc/foo"
132
+ # readOnly: true
133
+
134
+ nodeSelector: {}
135
+
136
+ tolerations: []
137
+
138
+ affinity: {}
139
+
140
+ db:
141
+ # Use an existing postgres server/cluster
142
+ useExisting: false
143
+
144
+ # How to connect to the existing postgres server/cluster
145
+ endpoint: localhost
146
+ database: litellm
147
+ url: postgresql://$(DATABASE_USERNAME):$(DATABASE_PASSWORD)@$(DATABASE_HOST)/$(DATABASE_NAME)
148
+ secret:
149
+ name: postgres
150
+ usernameKey: username
151
+ passwordKey: password
152
+
153
+ # Use the Stackgres Helm chart to deploy an instance of a Stackgres cluster.
154
+ # The Stackgres Operator must already be installed within the target
155
+ # Kubernetes cluster.
156
+ # TODO: Stackgres deployment currently unsupported
157
+ useStackgresOperator: false
158
+
159
+ # Use the Postgres Helm chart to create a single node, stand alone postgres
160
+ # instance. See the "postgresql" top level key for additional configuration.
161
+ deployStandalone: true
162
+
163
+ # Settings for Bitnami postgresql chart (if db.deployStandalone is true, ignored
164
+ # otherwise)
165
+ postgresql:
166
+ architecture: standalone
167
+ auth:
168
+ username: litellm
169
+ database: litellm
170
+
171
+ # You should override these on the helm command line with
172
+ # `--set postgresql.auth.postgres-password=<some good password>,postgresql.auth.password=<some good password>`
173
+ password: NoTaGrEaTpAsSwOrD
174
+ postgres-password: NoTaGrEaTpAsSwOrD
175
+
176
+ # A secret is created by this chart (litellm-helm) with the credentials that
177
+ # the new Postgres instance should use.
178
+ # existingSecret: ""
179
+ # secretKeys:
180
+ # userPasswordKey: password
181
+
182
+ # requires cache: true in config file
183
+ # either enable this or pass a secret for REDIS_HOST, REDIS_PORT, REDIS_PASSWORD or REDIS_URL
184
+ # with cache: true to use existing redis instance
185
+ redis:
186
+ enabled: false
187
+ architecture: standalone
188
+
189
+ # Prisma migration job settings
190
+ migrationJob:
191
+ enabled: true # Enable or disable the schema migration Job
192
+ retries: 3 # Number of retries for the Job in case of failure
193
+ backoffLimit: 4 # Backoff limit for Job restarts
194
+ disableSchemaUpdate: false # Skip schema migrations for specific environments. When True, the job will exit with code 0.
195
+ annotations: {}
196
+ ttlSecondsAfterFinished: 120
197
+
198
+ # Additional environment variables to be added to the deployment as a map of key-value pairs
199
+ envVars: {
200
+ # USE_DDTRACE: "true"
201
+ }
202
+
203
+ # Additional environment variables to be added to the deployment as a list of k8s env vars
204
+ extraEnvVars: {
205
+ # - name: EXTRA_ENV_VAR
206
+ # value: EXTRA_ENV_VAR_VALUE
207
+ }
208
+
209
+
deploy/kubernetes/service.yaml ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ apiVersion: v1
2
+ kind: Service
3
+ metadata:
4
+ name: litellm-service
5
+ spec:
6
+ selector:
7
+ app: litellm
8
+ ports:
9
+ - protocol: TCP
10
+ port: 4000
11
+ targetPort: 4000
12
+ type: LoadBalancer
ui/litellm-dashboard/.eslintrc.json ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ {
2
+ "extends": "next/core-web-vitals"
3
+ }
ui/litellm-dashboard/README.md ADDED
@@ -0,0 +1,36 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ This is a [Next.js](https://nextjs.org/) project bootstrapped with [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app).
2
+
3
+ ## Getting Started
4
+
5
+ First, run the development server:
6
+
7
+ ```bash
8
+ npm run dev
9
+ # or
10
+ yarn dev
11
+ # or
12
+ pnpm dev
13
+ # or
14
+ bun dev
15
+ ```
16
+
17
+ Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.
18
+
19
+ You can start editing the page by modifying `app/page.tsx`. The page auto-updates as you edit the file.
20
+
21
+ This project uses [`next/font`](https://nextjs.org/docs/basic-features/font-optimization) to automatically optimize and load Inter, a custom Google Font.
22
+
23
+ ## Learn More
24
+
25
+ To learn more about Next.js, take a look at the following resources:
26
+
27
+ - [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js features and API.
28
+ - [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial.
29
+
30
+ You can check out [the Next.js GitHub repository](https://github.com/vercel/next.js/) - your feedback and contributions are welcome!
31
+
32
+ ## Deploy on Vercel
33
+
34
+ The easiest way to deploy your Next.js app is to use the [Vercel Platform](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js.
35
+
36
+ Check out our [Next.js deployment documentation](https://nextjs.org/docs/deployment) for more details.
ui/litellm-dashboard/build_ui.sh ADDED
@@ -0,0 +1,49 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/bin/bash
2
+
3
+ # Check if nvm is not installed
4
+ if ! command -v nvm &> /dev/null; then
5
+ # Install nvm
6
+ curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.38.0/install.sh | bash
7
+
8
+ # Source nvm script in the current session
9
+ export NVM_DIR="$HOME/.nvm"
10
+ [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"
11
+ fi
12
+
13
+ # Use nvm to set the required Node.js version
14
+ nvm use v18.17.0
15
+
16
+ # Check if nvm use was successful
17
+ if [ $? -ne 0 ]; then
18
+ echo "Error: Failed to switch to Node.js v18.17.0. Deployment aborted."
19
+ exit 1
20
+ fi
21
+
22
+ # print contents of ui_colors.json
23
+ echo "Contents of ui_colors.json:"
24
+ cat ui_colors.json
25
+
26
+ # Run npm build
27
+ npm run build
28
+
29
+ # Check if the build was successful
30
+ if [ $? -eq 0 ]; then
31
+ echo "Build successful. Copying files..."
32
+
33
+ # echo current dir
34
+ echo
35
+ pwd
36
+
37
+ # Specify the destination directory
38
+ destination_dir="../../litellm/proxy/_experimental/out"
39
+
40
+ # Remove existing files in the destination directory
41
+ rm -rf "$destination_dir"/*
42
+
43
+ # Copy the contents of the output directory to the specified destination
44
+ cp -r ./out/* "$destination_dir"
45
+
46
+ echo "Deployment completed."
47
+ else
48
+ echo "Build failed. Deployment aborted."
49
+ fi
ui/litellm-dashboard/build_ui_custom_path.sh ADDED
@@ -0,0 +1,55 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/bin/bash
2
+
3
+ # Check if UI_BASE_PATH argument is provided
4
+ if [ -z "$1" ]; then
5
+ echo "Error: UI_BASE_PATH argument is required."
6
+ echo "Usage: $0 <UI_BASE_PATH>"
7
+ exit 1
8
+ fi
9
+
10
+ # Set UI_BASE_PATH from the first argument
11
+ UI_BASE_PATH="$1"
12
+
13
+ # Check if nvm is not installed
14
+ if ! command -v nvm &> /dev/null; then
15
+ # Install nvm
16
+ curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.38.0/install.sh | bash
17
+
18
+ # Source nvm script in the current session
19
+ export NVM_DIR="$HOME/.nvm"
20
+ [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"
21
+ fi
22
+
23
+ # Use nvm to set the required Node.js version
24
+ nvm use v18.17.0
25
+
26
+ # Check if nvm use was successful
27
+ if [ $? -ne 0 ]; then
28
+ echo "Error: Failed to switch to Node.js v18.17.0. Deployment aborted."
29
+ exit 1
30
+ fi
31
+
32
+ # Run npm build with the environment variable
33
+ UI_BASE_PATH=$UI_BASE_PATH npm run build
34
+
35
+ # Check if the build was successful
36
+ if [ $? -eq 0 ]; then
37
+ echo "Build successful. Copying files..."
38
+
39
+ # echo current dir
40
+ echo
41
+ pwd
42
+
43
+ # Specify the destination directory
44
+ destination_dir="../../litellm/proxy/_experimental/out"
45
+
46
+ # Remove existing files in the destination directory
47
+ rm -rf "$destination_dir"/*
48
+
49
+ # Copy the contents of the output directory to the specified destination
50
+ cp -r ./out/* "$destination_dir"
51
+
52
+ echo "Deployment completed."
53
+ else
54
+ echo "Build failed. Deployment aborted."
55
+ fi
ui/litellm-dashboard/next.config.mjs ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /** @type {import('next').NextConfig} */
2
+ const nextConfig = {
3
+ output: 'export',
4
+ basePath: process.env.UI_BASE_PATH || '/ui',
5
+ };
6
+
7
+ nextConfig.experimental = {
8
+ missingSuspenseWithCSRBailout: false
9
+ }
10
+
11
+ export default nextConfig;
ui/litellm-dashboard/out/404.html ADDED
@@ -0,0 +1 @@
 
 
1
+ <!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="preload" href="/ui/_next/static/media/a34f9d1faa5f3315-s.p.woff2" as="font" crossorigin="" type="font/woff2"/><link rel="stylesheet" href="/ui/_next/static/css/86f6cc749f6b8493.css" data-precedence="next"/><link rel="stylesheet" href="/ui/_next/static/css/ec485413ca556f63.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/ui/_next/static/chunks/webpack-75a5453f51d60261.js"/><script src="/ui/_next/static/chunks/fd9d1056-205af899b895cbac.js" async=""></script><script src="/ui/_next/static/chunks/117-1c5bfc45bfc4237d.js" async=""></script><script src="/ui/_next/static/chunks/main-app-475d6efe4080647d.js" async=""></script><meta name="robots" content="noindex"/><title>404: This page could not be found.</title><title>LiteLLM Dashboard</title><meta name="description" content="LiteLLM Proxy Admin UI"/><meta name="next-size-adjust"/><script src="/ui/_next/static/chunks/polyfills-42372ed130431b0a.js" noModule=""></script></head><body class="__className_cf7686"><div style="font-family:system-ui,&quot;Segoe UI&quot;,Roboto,Helvetica,Arial,sans-serif,&quot;Apple Color Emoji&quot;,&quot;Segoe UI Emoji&quot;;height:100vh;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center"><div><style>body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}</style><h1 class="next-error-h1" style="display:inline-block;margin:0 20px 0 0;padding:0 23px 0 0;font-size:24px;font-weight:500;vertical-align:top;line-height:49px">404</h1><div style="display:inline-block"><h2 style="font-size:14px;font-weight:400;line-height:49px;margin:0">This page could not be found.</h2></div></div></div><script src="/ui/_next/static/chunks/webpack-75a5453f51d60261.js" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0]);self.__next_f.push([2,null])</script><script>self.__next_f.push([1,"1:HL[\"/ui/_next/static/media/a34f9d1faa5f3315-s.p.woff2\",\"font\",{\"crossOrigin\":\"\",\"type\":\"font/woff2\"}]\n2:HL[\"/ui/_next/static/css/86f6cc749f6b8493.css\",\"style\"]\n3:HL[\"/ui/_next/static/css/ec485413ca556f63.css\",\"style\"]\n"])</script><script>self.__next_f.push([1,"4:I[12846,[],\"\"]\n6:I[4707,[],\"\"]\n7:I[36423,[],\"\"]\nd:I[61060,[],\"\"]\n8:{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"}\n9:{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"}\na:{\"display\":\"inline-block\"}\nb:{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0}\ne:[]\n"])</script><script>self.__next_f.push([1,"0:[\"$\",\"$L4\",null,{\"buildId\":\"9QypG31hSXzLA6YqfGTQF\",\"assetPrefix\":\"/ui\",\"urlParts\":[\"\",\"_not-found\"],\"initialTree\":[\"\",{\"children\":[\"/_not-found\",{\"children\":[\"__PAGE__\",{}]}]},\"$undefined\",\"$undefined\",true],\"initialSeedData\":[\"\",{\"children\":[\"/_not-found\",{\"children\":[\"__PAGE__\",{},[[\"$L5\",[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":\"404\"}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],null],null],null]},[null,[\"$\",\"$L6\",null,{\"parallelRouterKey\":\"children\",\"segmentPath\":[\"children\",\"/_not-found\",\"children\"],\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L7\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"notFoundStyles\":\"$undefined\"}]],null]},[[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/ui/_next/static/css/86f6cc749f6b8493.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\"}],[\"$\",\"link\",\"1\",{\"rel\":\"stylesheet\",\"href\":\"/ui/_next/static/css/ec485413ca556f63.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"en\",\"children\":[\"$\",\"body\",null,{\"className\":\"__className_cf7686\",\"children\":[\"$\",\"$L6\",null,{\"parallelRouterKey\":\"children\",\"segmentPath\":[\"children\"],\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L7\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":\"$8\",\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":\"$9\",\"children\":\"404\"}],[\"$\",\"div\",null,{\"style\":\"$a\",\"children\":[\"$\",\"h2\",null,{\"style\":\"$b\",\"children\":\"This page could not be found.\"}]}]]}]}]],\"notFoundStyles\":[]}]}]}]],null],null],\"couldBeIntercepted\":false,\"initialHead\":[[\"$\",\"meta\",null,{\"name\":\"robots\",\"content\":\"noindex\"}],\"$Lc\"],\"globalErrorComponent\":\"$d\",\"missingSlots\":\"$We\"}]\n"])</script><script>self.__next_f.push([1,"c:[[\"$\",\"meta\",\"0\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}],[\"$\",\"meta\",\"1\",{\"charSet\":\"utf-8\"}],[\"$\",\"title\",\"2\",{\"children\":\"LiteLLM Dashboard\"}],[\"$\",\"meta\",\"3\",{\"name\":\"description\",\"content\":\"LiteLLM Proxy Admin UI\"}],[\"$\",\"meta\",\"4\",{\"name\":\"next-size-adjust\"}]]\n5:null\n"])</script></body></html>
ui/litellm-dashboard/out/_next/static/9QypG31hSXzLA6YqfGTQF/_buildManifest.js ADDED
@@ -0,0 +1 @@
 
 
1
+ self.__BUILD_MANIFEST={__rewrites:{afterFiles:[],beforeFiles:[],fallback:[]},"/_error":["static/chunks/pages/_error-28b803cb2479b966.js"],sortedPages:["/_app","/_error"]},self.__BUILD_MANIFEST_CB&&self.__BUILD_MANIFEST_CB();
ui/litellm-dashboard/out/_next/static/9QypG31hSXzLA6YqfGTQF/_ssgManifest.js ADDED
@@ -0,0 +1 @@
 
 
1
+ self.__SSG_MANIFEST=new Set([]);self.__SSG_MANIFEST_CB&&self.__SSG_MANIFEST_CB()
ui/litellm-dashboard/out/_next/static/chunks/117-1c5bfc45bfc4237d.js ADDED
The diff for this file is too large to render. See raw diff
 
ui/litellm-dashboard/out/_next/static/chunks/13b76428-ebdf3012af0e4489.js ADDED
@@ -0,0 +1 @@
 
 
1
+ (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[990],{77398:function(e,t,n){var s;e=n.nmd(e),s=function(){"use strict";function t(){return V.apply(null,arguments)}function n(e){return e instanceof Array||"[object Array]"===Object.prototype.toString.call(e)}function s(e){return null!=e&&"[object Object]"===Object.prototype.toString.call(e)}function i(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function r(e){var t;if(Object.getOwnPropertyNames)return 0===Object.getOwnPropertyNames(e).length;for(t in e)if(i(e,t))return!1;return!0}function a(e){return void 0===e}function o(e){return"number"==typeof e||"[object Number]"===Object.prototype.toString.call(e)}function u(e){return e instanceof Date||"[object Date]"===Object.prototype.toString.call(e)}function l(e,t){var n,s=[],i=e.length;for(n=0;n<i;++n)s.push(t(e[n],n));return s}function h(e,t){for(var n in t)i(t,n)&&(e[n]=t[n]);return i(t,"toString")&&(e.toString=t.toString),i(t,"valueOf")&&(e.valueOf=t.valueOf),e}function d(e,t,n,s){return ti(e,t,n,s,!0).utc()}function c(e){return null==e._pf&&(e._pf={empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidEra:null,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],era:null,meridiem:null,rfc2822:!1,weekdayMismatch:!1}),e._pf}function f(e){var t=null,n=!1,s=e._d&&!isNaN(e._d.getTime());return(s&&(t=c(e),n=G.call(t.parsedDateParts,function(e){return null!=e}),s=t.overflow<0&&!t.empty&&!t.invalidEra&&!t.invalidMonth&&!t.invalidWeekday&&!t.weekdayMismatch&&!t.nullInput&&!t.invalidFormat&&!t.userInvalidated&&(!t.meridiem||t.meridiem&&n),e._strict&&(s=s&&0===t.charsLeftOver&&0===t.unusedTokens.length&&void 0===t.bigHour)),null!=Object.isFrozen&&Object.isFrozen(e))?s:(e._isValid=s,e._isValid)}function m(e){var t=d(NaN);return null!=e?h(c(t),e):c(t).userInvalidated=!0,t}G=Array.prototype.some?Array.prototype.some:function(e){var t,n=Object(this),s=n.length>>>0;for(t=0;t<s;t++)if(t in n&&e.call(this,n[t],t,n))return!0;return!1};var _,y,g=t.momentProperties=[],w=!1;function p(e,t){var n,s,i,r=g.length;if(a(t._isAMomentObject)||(e._isAMomentObject=t._isAMomentObject),a(t._i)||(e._i=t._i),a(t._f)||(e._f=t._f),a(t._l)||(e._l=t._l),a(t._strict)||(e._strict=t._strict),a(t._tzm)||(e._tzm=t._tzm),a(t._isUTC)||(e._isUTC=t._isUTC),a(t._offset)||(e._offset=t._offset),a(t._pf)||(e._pf=c(t)),a(t._locale)||(e._locale=t._locale),r>0)for(n=0;n<r;n++)a(i=t[s=g[n]])||(e[s]=i);return e}function v(e){p(this,e),this._d=new Date(null!=e._d?e._d.getTime():NaN),this.isValid()||(this._d=new Date(NaN)),!1===w&&(w=!0,t.updateOffset(this),w=!1)}function k(e){return e instanceof v||null!=e&&null!=e._isAMomentObject}function M(e){!1===t.suppressDeprecationWarnings&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+e)}function D(e,n){var s=!0;return h(function(){if(null!=t.deprecationHandler&&t.deprecationHandler(null,e),s){var r,a,o,u=[],l=arguments.length;for(a=0;a<l;a++){if(r="","object"==typeof arguments[a]){for(o in r+="\n["+a+"] ",arguments[0])i(arguments[0],o)&&(r+=o+": "+arguments[0][o]+", ");r=r.slice(0,-2)}else r=arguments[a];u.push(r)}M(e+"\nArguments: "+Array.prototype.slice.call(u).join("")+"\n"+Error().stack),s=!1}return n.apply(this,arguments)},n)}var Y={};function S(e,n){null!=t.deprecationHandler&&t.deprecationHandler(e,n),Y[e]||(M(n),Y[e]=!0)}function O(e){return"undefined"!=typeof Function&&e instanceof Function||"[object Function]"===Object.prototype.toString.call(e)}function b(e,t){var n,r=h({},e);for(n in t)i(t,n)&&(s(e[n])&&s(t[n])?(r[n]={},h(r[n],e[n]),h(r[n],t[n])):null!=t[n]?r[n]=t[n]:delete r[n]);for(n in e)i(e,n)&&!i(t,n)&&s(e[n])&&(r[n]=h({},r[n]));return r}function T(e){null!=e&&this.set(e)}function x(e,t,n){var s=""+Math.abs(e);return(e>=0?n?"+":"":"-")+Math.pow(10,Math.max(0,t-s.length)).toString().substr(1)+s}t.suppressDeprecationWarnings=!1,t.deprecationHandler=null,A=Object.keys?Object.keys:function(e){var t,n=[];for(t in e)i(e,t)&&n.push(t);return n};var N=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,W=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,P={},R={};function C(e,t,n,s){var i=s;"string"==typeof s&&(i=function(){return this[s]()}),e&&(R[e]=i),t&&(R[t[0]]=function(){return x(i.apply(this,arguments),t[1],t[2])}),n&&(R[n]=function(){return this.localeData().ordinal(i.apply(this,arguments),e)})}function U(e,t){return e.isValid()?(P[t=H(t,e.localeData())]=P[t]||function(e){var t,n,s,i=e.match(N);for(n=0,s=i.length;n<s;n++)R[i[n]]?i[n]=R[i[n]]:i[n]=(t=i[n]).match(/\[[\s\S]/)?t.replace(/^\[|\]$/g,""):t.replace(/\\/g,"");return function(t){var n,r="";for(n=0;n<s;n++)r+=O(i[n])?i[n].call(t,e):i[n];return r}}(t),P[t](e)):e.localeData().invalidDate()}function H(e,t){var n=5;function s(e){return t.longDateFormat(e)||e}for(W.lastIndex=0;n>=0&&W.test(e);)e=e.replace(W,s),W.lastIndex=0,n-=1;return e}var F={D:"date",dates:"date",date:"date",d:"day",days:"day",day:"day",e:"weekday",weekdays:"weekday",weekday:"weekday",E:"isoWeekday",isoweekdays:"isoWeekday",isoweekday:"isoWeekday",DDD:"dayOfYear",dayofyears:"dayOfYear",dayofyear:"dayOfYear",h:"hour",hours:"hour",hour:"hour",ms:"millisecond",milliseconds:"millisecond",millisecond:"millisecond",m:"minute",minutes:"minute",minute:"minute",M:"month",months:"month",month:"month",Q:"quarter",quarters:"quarter",quarter:"quarter",s:"second",seconds:"second",second:"second",gg:"weekYear",weekyears:"weekYear",weekyear:"weekYear",GG:"isoWeekYear",isoweekyears:"isoWeekYear",isoweekyear:"isoWeekYear",w:"week",weeks:"week",week:"week",W:"isoWeek",isoweeks:"isoWeek",isoweek:"isoWeek",y:"year",years:"year",year:"year"};function L(e){return"string"==typeof e?F[e]||F[e.toLowerCase()]:void 0}function E(e){var t,n,s={};for(n in e)i(e,n)&&(t=L(n))&&(s[t]=e[n]);return s}var V,G,A,I,j={date:9,day:11,weekday:11,isoWeekday:11,dayOfYear:4,hour:13,millisecond:16,minute:14,month:8,quarter:7,second:15,weekYear:1,isoWeekYear:1,week:5,isoWeek:5,year:1},Z=/\d/,z=/\d\d/,$=/\d{3}/,q=/\d{4}/,B=/[+-]?\d{6}/,J=/\d\d?/,Q=/\d\d\d\d?/,X=/\d\d\d\d\d\d?/,K=/\d{1,3}/,ee=/\d{1,4}/,et=/[+-]?\d{1,6}/,en=/\d+/,es=/[+-]?\d+/,ei=/Z|[+-]\d\d:?\d\d/gi,er=/Z|[+-]\d\d(?::?\d\d)?/gi,ea=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i,eo=/^[1-9]\d?/,eu=/^([1-9]\d|\d)/;function el(e,t,n){I[e]=O(t)?t:function(e,s){return e&&n?n:t}}function eh(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function ed(e){return e<0?Math.ceil(e)||0:Math.floor(e)}function ec(e){var t=+e,n=0;return 0!==t&&isFinite(t)&&(n=ed(t)),n}I={};var ef={};function em(e,t){var n,s,i=t;for("string"==typeof e&&(e=[e]),o(t)&&(i=function(e,n){n[t]=ec(e)}),s=e.length,n=0;n<s;n++)ef[e[n]]=i}function e_(e,t){em(e,function(e,n,s,i){s._w=s._w||{},t(e,s._w,s,i)})}function ey(e){return e%4==0&&e%100!=0||e%400==0}function eg(e){return ey(e)?366:365}C("Y",0,0,function(){var e=this.year();return e<=9999?x(e,4):"+"+e}),C(0,["YY",2],0,function(){return this.year()%100}),C(0,["YYYY",4],0,"year"),C(0,["YYYYY",5],0,"year"),C(0,["YYYYYY",6,!0],0,"year"),el("Y",es),el("YY",J,z),el("YYYY",ee,q),el("YYYYY",et,B),el("YYYYYY",et,B),em(["YYYYY","YYYYYY"],0),em("YYYY",function(e,n){n[0]=2===e.length?t.parseTwoDigitYear(e):ec(e)}),em("YY",function(e,n){n[0]=t.parseTwoDigitYear(e)}),em("Y",function(e,t){t[0]=parseInt(e,10)}),t.parseTwoDigitYear=function(e){return ec(e)+(ec(e)>68?1900:2e3)};var ew=ep("FullYear",!0);function ep(e,n){return function(s){return null!=s?(ek(this,e,s),t.updateOffset(this,n),this):ev(this,e)}}function ev(e,t){if(!e.isValid())return NaN;var n=e._d,s=e._isUTC;switch(t){case"Milliseconds":return s?n.getUTCMilliseconds():n.getMilliseconds();case"Seconds":return s?n.getUTCSeconds():n.getSeconds();case"Minutes":return s?n.getUTCMinutes():n.getMinutes();case"Hours":return s?n.getUTCHours():n.getHours();case"Date":return s?n.getUTCDate():n.getDate();case"Day":return s?n.getUTCDay():n.getDay();case"Month":return s?n.getUTCMonth():n.getMonth();case"FullYear":return s?n.getUTCFullYear():n.getFullYear();default:return NaN}}function ek(e,t,n){var s,i,r,a;if(!(!e.isValid()||isNaN(n))){switch(s=e._d,i=e._isUTC,t){case"Milliseconds":return void(i?s.setUTCMilliseconds(n):s.setMilliseconds(n));case"Seconds":return void(i?s.setUTCSeconds(n):s.setSeconds(n));case"Minutes":return void(i?s.setUTCMinutes(n):s.setMinutes(n));case"Hours":return void(i?s.setUTCHours(n):s.setHours(n));case"Date":return void(i?s.setUTCDate(n):s.setDate(n));case"FullYear":break;default:return}r=e.month(),a=29!==(a=e.date())||1!==r||ey(n)?a:28,i?s.setUTCFullYear(n,r,a):s.setFullYear(n,r,a)}}function eM(e,t){if(isNaN(e)||isNaN(t))return NaN;var n=(t%12+12)%12;return e+=(t-n)/12,1===n?ey(e)?29:28:31-n%7%2}eA=Array.prototype.indexOf?Array.prototype.indexOf:function(e){var t;for(t=0;t<this.length;++t)if(this[t]===e)return t;return -1},C("M",["MM",2],"Mo",function(){return this.month()+1}),C("MMM",0,0,function(e){return this.localeData().monthsShort(this,e)}),C("MMMM",0,0,function(e){return this.localeData().months(this,e)}),el("M",J,eo),el("MM",J,z),el("MMM",function(e,t){return t.monthsShortRegex(e)}),el("MMMM",function(e,t){return t.monthsRegex(e)}),em(["M","MM"],function(e,t){t[1]=ec(e)-1}),em(["MMM","MMMM"],function(e,t,n,s){var i=n._locale.monthsParse(e,s,n._strict);null!=i?t[1]=i:c(n).invalidMonth=e});var eD="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),eY=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/;function eS(e,t,n){var s,i,r,a=e.toLocaleLowerCase();if(!this._monthsParse)for(s=0,this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[];s<12;++s)r=d([2e3,s]),this._shortMonthsParse[s]=this.monthsShort(r,"").toLocaleLowerCase(),this._longMonthsParse[s]=this.months(r,"").toLocaleLowerCase();return n?"MMM"===t?-1!==(i=eA.call(this._shortMonthsParse,a))?i:null:-1!==(i=eA.call(this._longMonthsParse,a))?i:null:"MMM"===t?-1!==(i=eA.call(this._shortMonthsParse,a))?i:-1!==(i=eA.call(this._longMonthsParse,a))?i:null:-1!==(i=eA.call(this._longMonthsParse,a))?i:-1!==(i=eA.call(this._shortMonthsParse,a))?i:null}function eO(e,t){if(!e.isValid())return e;if("string"==typeof t){if(/^\d+$/.test(t))t=ec(t);else if(!o(t=e.localeData().monthsParse(t)))return e}var n=t,s=e.date();return s=s<29?s:Math.min(s,eM(e.year(),n)),e._isUTC?e._d.setUTCMonth(n,s):e._d.setMonth(n,s),e}function eb(e){return null!=e?(eO(this,e),t.updateOffset(this,!0),this):ev(this,"Month")}function eT(){function e(e,t){return t.length-e.length}var t,n,s,i,r=[],a=[],o=[];for(t=0;t<12;t++)n=d([2e3,t]),s=eh(this.monthsShort(n,"")),i=eh(this.months(n,"")),r.push(s),a.push(i),o.push(i),o.push(s);r.sort(e),a.sort(e),o.sort(e),this._monthsRegex=RegExp("^("+o.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=RegExp("^("+a.join("|")+")","i"),this._monthsShortStrictRegex=RegExp("^("+r.join("|")+")","i")}function ex(e,t,n,s,i,r,a){var o;return e<100&&e>=0?isFinite((o=new Date(e+400,t,n,s,i,r,a)).getFullYear())&&o.setFullYear(e):o=new Date(e,t,n,s,i,r,a),o}function eN(e){var t,n;return e<100&&e>=0?(n=Array.prototype.slice.call(arguments),n[0]=e+400,isFinite((t=new Date(Date.UTC.apply(null,n))).getUTCFullYear())&&t.setUTCFullYear(e)):t=new Date(Date.UTC.apply(null,arguments)),t}function eW(e,t,n){var s=7+t-n;return-((7+eN(e,0,s).getUTCDay()-t)%7)+s-1}function eP(e,t,n,s,i){var r,a,o=1+7*(t-1)+(7+n-s)%7+eW(e,s,i);return o<=0?a=eg(r=e-1)+o:o>eg(e)?(r=e+1,a=o-eg(e)):(r=e,a=o),{year:r,dayOfYear:a}}function eR(e,t,n){var s,i,r=eW(e.year(),t,n),a=Math.floor((e.dayOfYear()-r-1)/7)+1;return a<1?s=a+eC(i=e.year()-1,t,n):a>eC(e.year(),t,n)?(s=a-eC(e.year(),t,n),i=e.year()+1):(i=e.year(),s=a),{week:s,year:i}}function eC(e,t,n){var s=eW(e,t,n),i=eW(e+1,t,n);return(eg(e)-s+i)/7}function eU(e,t){return e.slice(t,7).concat(e.slice(0,t))}C("w",["ww",2],"wo","week"),C("W",["WW",2],"Wo","isoWeek"),el("w",J,eo),el("ww",J,z),el("W",J,eo),el("WW",J,z),e_(["w","ww","W","WW"],function(e,t,n,s){t[s.substr(0,1)]=ec(e)}),C("d",0,"do","day"),C("dd",0,0,function(e){return this.localeData().weekdaysMin(this,e)}),C("ddd",0,0,function(e){return this.localeData().weekdaysShort(this,e)}),C("dddd",0,0,function(e){return this.localeData().weekdays(this,e)}),C("e",0,0,"weekday"),C("E",0,0,"isoWeekday"),el("d",J),el("e",J),el("E",J),el("dd",function(e,t){return t.weekdaysMinRegex(e)}),el("ddd",function(e,t){return t.weekdaysShortRegex(e)}),el("dddd",function(e,t){return t.weekdaysRegex(e)}),e_(["dd","ddd","dddd"],function(e,t,n,s){var i=n._locale.weekdaysParse(e,s,n._strict);null!=i?t.d=i:c(n).invalidWeekday=e}),e_(["d","e","E"],function(e,t,n,s){t[s]=ec(e)});var eH="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_");function eF(e,t,n){var s,i,r,a=e.toLocaleLowerCase();if(!this._weekdaysParse)for(s=0,this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[];s<7;++s)r=d([2e3,1]).day(s),this._minWeekdaysParse[s]=this.weekdaysMin(r,"").toLocaleLowerCase(),this._shortWeekdaysParse[s]=this.weekdaysShort(r,"").toLocaleLowerCase(),this._weekdaysParse[s]=this.weekdays(r,"").toLocaleLowerCase();return n?"dddd"===t?-1!==(i=eA.call(this._weekdaysParse,a))?i:null:"ddd"===t?-1!==(i=eA.call(this._shortWeekdaysParse,a))?i:null:-1!==(i=eA.call(this._minWeekdaysParse,a))?i:null:"dddd"===t?-1!==(i=eA.call(this._weekdaysParse,a))||-1!==(i=eA.call(this._shortWeekdaysParse,a))?i:-1!==(i=eA.call(this._minWeekdaysParse,a))?i:null:"ddd"===t?-1!==(i=eA.call(this._shortWeekdaysParse,a))||-1!==(i=eA.call(this._weekdaysParse,a))?i:-1!==(i=eA.call(this._minWeekdaysParse,a))?i:null:-1!==(i=eA.call(this._minWeekdaysParse,a))||-1!==(i=eA.call(this._weekdaysParse,a))?i:-1!==(i=eA.call(this._shortWeekdaysParse,a))?i:null}function eL(){function e(e,t){return t.length-e.length}var t,n,s,i,r,a=[],o=[],u=[],l=[];for(t=0;t<7;t++)n=d([2e3,1]).day(t),s=eh(this.weekdaysMin(n,"")),i=eh(this.weekdaysShort(n,"")),r=eh(this.weekdays(n,"")),a.push(s),o.push(i),u.push(r),l.push(s),l.push(i),l.push(r);a.sort(e),o.sort(e),u.sort(e),l.sort(e),this._weekdaysRegex=RegExp("^("+l.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=RegExp("^("+u.join("|")+")","i"),this._weekdaysShortStrictRegex=RegExp("^("+o.join("|")+")","i"),this._weekdaysMinStrictRegex=RegExp("^("+a.join("|")+")","i")}function eE(){return this.hours()%12||12}function eV(e,t){C(e,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),t)})}function eG(e,t){return t._meridiemParse}C("H",["HH",2],0,"hour"),C("h",["hh",2],0,eE),C("k",["kk",2],0,function(){return this.hours()||24}),C("hmm",0,0,function(){return""+eE.apply(this)+x(this.minutes(),2)}),C("hmmss",0,0,function(){return""+eE.apply(this)+x(this.minutes(),2)+x(this.seconds(),2)}),C("Hmm",0,0,function(){return""+this.hours()+x(this.minutes(),2)}),C("Hmmss",0,0,function(){return""+this.hours()+x(this.minutes(),2)+x(this.seconds(),2)}),eV("a",!0),eV("A",!1),el("a",eG),el("A",eG),el("H",J,eu),el("h",J,eo),el("k",J,eo),el("HH",J,z),el("hh",J,z),el("kk",J,z),el("hmm",Q),el("hmmss",X),el("Hmm",Q),el("Hmmss",X),em(["H","HH"],3),em(["k","kk"],function(e,t,n){var s=ec(e);t[3]=24===s?0:s}),em(["a","A"],function(e,t,n){n._isPm=n._locale.isPM(e),n._meridiem=e}),em(["h","hh"],function(e,t,n){t[3]=ec(e),c(n).bigHour=!0}),em("hmm",function(e,t,n){var s=e.length-2;t[3]=ec(e.substr(0,s)),t[4]=ec(e.substr(s)),c(n).bigHour=!0}),em("hmmss",function(e,t,n){var s=e.length-4,i=e.length-2;t[3]=ec(e.substr(0,s)),t[4]=ec(e.substr(s,2)),t[5]=ec(e.substr(i)),c(n).bigHour=!0}),em("Hmm",function(e,t,n){var s=e.length-2;t[3]=ec(e.substr(0,s)),t[4]=ec(e.substr(s))}),em("Hmmss",function(e,t,n){var s=e.length-4,i=e.length-2;t[3]=ec(e.substr(0,s)),t[4]=ec(e.substr(s,2)),t[5]=ec(e.substr(i))});var eA,eI,ej=ep("Hours",!0),eZ={calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},longDateFormat:{LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},invalidDate:"Invalid date",ordinal:"%d",dayOfMonthOrdinalParse:/\d{1,2}/,relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",w:"a week",ww:"%d weeks",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:eD,week:{dow:0,doy:6},weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),weekdaysShort:eH,meridiemParse:/[ap]\.?m?\.?/i},ez={},e$={};function eq(e){return e?e.toLowerCase().replace("_","-"):e}function eB(t){var n=null;if(void 0===ez[t]&&e&&e.exports&&t&&t.match("^[^/\\\\]*$"))try{n=eI._abbr,function(){var e=Error("Cannot find module 'undefined'");throw e.code="MODULE_NOT_FOUND",e}(),eJ(n)}catch(e){ez[t]=null}return ez[t]}function eJ(e,t){var n;return e&&((n=a(t)?eX(e):eQ(e,t))?eI=n:"undefined"!=typeof console&&console.warn&&console.warn("Locale "+e+" not found. Did you forget to load it?")),eI._abbr}function eQ(e,t){if(null===t)return delete ez[e],null;var n,s=eZ;if(t.abbr=e,null!=ez[e])S("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),s=ez[e]._config;else if(null!=t.parentLocale){if(null!=ez[t.parentLocale])s=ez[t.parentLocale]._config;else{if(null==(n=eB(t.parentLocale)))return e$[t.parentLocale]||(e$[t.parentLocale]=[]),e$[t.parentLocale].push({name:e,config:t}),null;s=n._config}}return ez[e]=new T(b(s,t)),e$[e]&&e$[e].forEach(function(e){eQ(e.name,e.config)}),eJ(e),ez[e]}function eX(e){var t;if(e&&e._locale&&e._locale._abbr&&(e=e._locale._abbr),!e)return eI;if(!n(e)){if(t=eB(e))return t;e=[e]}return function(e){for(var t,n,s,i,r=0;r<e.length;){for(t=(i=eq(e[r]).split("-")).length,n=(n=eq(e[r+1]))?n.split("-"):null;t>0;){if(s=eB(i.slice(0,t).join("-")))return s;if(n&&n.length>=t&&function(e,t){var n,s=Math.min(e.length,t.length);for(n=0;n<s;n+=1)if(e[n]!==t[n])return n;return s}(i,n)>=t-1)break;t--}r++}return eI}(e)}function eK(e){var t,n=e._a;return n&&-2===c(e).overflow&&(t=n[1]<0||n[1]>11?1:n[2]<1||n[2]>eM(n[0],n[1])?2:n[3]<0||n[3]>24||24===n[3]&&(0!==n[4]||0!==n[5]||0!==n[6])?3:n[4]<0||n[4]>59?4:n[5]<0||n[5]>59?5:n[6]<0||n[6]>999?6:-1,c(e)._overflowDayOfYear&&(t<0||t>2)&&(t=2),c(e)._overflowWeeks&&-1===t&&(t=7),c(e)._overflowWeekday&&-1===t&&(t=8),c(e).overflow=t),e}var e0=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,e1=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,e2=/Z|[+-]\d\d(?::?\d\d)?/,e4=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/],["YYYYMM",/\d{6}/,!1],["YYYY",/\d{4}/,!1]],e3=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],e6=/^\/?Date\((-?\d+)/i,e5=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,e7={UT:0,GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function e9(e){var t,n,s,i,r,a,o=e._i,u=e0.exec(o)||e1.exec(o),l=e4.length,h=e3.length;if(u){for(t=0,c(e).iso=!0,n=l;t<n;t++)if(e4[t][1].exec(u[1])){i=e4[t][0],s=!1!==e4[t][2];break}if(null==i){e._isValid=!1;return}if(u[3]){for(t=0,n=h;t<n;t++)if(e3[t][1].exec(u[3])){r=(u[2]||" ")+e3[t][0];break}if(null==r){e._isValid=!1;return}}if(!s&&null!=r){e._isValid=!1;return}if(u[4]){if(e2.exec(u[4]))a="Z";else{e._isValid=!1;return}}e._f=i+(r||"")+(a||""),tn(e)}else e._isValid=!1}function e8(e){var t,n,s,i,r,a,o,u,l,h=e5.exec(e._i.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s\s*/,"").replace(/\s\s*$/,""));if(h){if(n=h[4],s=h[3],i=h[2],r=h[5],a=h[6],o=h[7],u=[(t=parseInt(n,10))<=49?2e3+t:t<=999?1900+t:t,eD.indexOf(s),parseInt(i,10),parseInt(r,10),parseInt(a,10)],o&&u.push(parseInt(o,10)),(l=h[1])&&eH.indexOf(l)!==new Date(u[0],u[1],u[2]).getDay()&&(c(e).weekdayMismatch=!0,e._isValid=!1,1))return;e._a=u,e._tzm=function(e,t,n){if(e)return e7[e];if(t)return 0;var s=parseInt(n,10),i=s%100;return(s-i)/100*60+i}(h[8],h[9],h[10]),e._d=eN.apply(null,e._a),e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),c(e).rfc2822=!0}else e._isValid=!1}function te(e,t,n){return null!=e?e:null!=t?t:n}function tt(e){var n,s,i,r,a,o,u,l,h,d,f,m,_,y,g,w=[];if(!e._d){for(d=new Date(t.now()),_=e._useUTC?[d.getUTCFullYear(),d.getUTCMonth(),d.getUTCDate()]:[d.getFullYear(),d.getMonth(),d.getDate()],e._w&&null==e._a[2]&&null==e._a[1]&&(null!=(n=e._w).GG||null!=n.W||null!=n.E?(a=1,o=4,s=te(n.GG,e._a[0],eR(tr(),1,4).year),i=te(n.W,1),((r=te(n.E,1))<1||r>7)&&(l=!0)):(a=e._locale._week.dow,o=e._locale._week.doy,h=eR(tr(),a,o),s=te(n.gg,e._a[0],h.year),i=te(n.w,h.week),null!=n.d?((r=n.d)<0||r>6)&&(l=!0):null!=n.e?(r=n.e+a,(n.e<0||n.e>6)&&(l=!0)):r=a),i<1||i>eC(s,a,o)?c(e)._overflowWeeks=!0:null!=l?c(e)._overflowWeekday=!0:(u=eP(s,i,r,a,o),e._a[0]=u.year,e._dayOfYear=u.dayOfYear)),null!=e._dayOfYear&&(g=te(e._a[0],_[0]),(e._dayOfYear>eg(g)||0===e._dayOfYear)&&(c(e)._overflowDayOfYear=!0),m=eN(g,0,e._dayOfYear),e._a[1]=m.getUTCMonth(),e._a[2]=m.getUTCDate()),f=0;f<3&&null==e._a[f];++f)e._a[f]=w[f]=_[f];for(;f<7;f++)e._a[f]=w[f]=null==e._a[f]?2===f?1:0:e._a[f];24===e._a[3]&&0===e._a[4]&&0===e._a[5]&&0===e._a[6]&&(e._nextDay=!0,e._a[3]=0),e._d=(e._useUTC?eN:ex).apply(null,w),y=e._useUTC?e._d.getUTCDay():e._d.getDay(),null!=e._tzm&&e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),e._nextDay&&(e._a[3]=24),e._w&&void 0!==e._w.d&&e._w.d!==y&&(c(e).weekdayMismatch=!0)}}function tn(e){if(e._f===t.ISO_8601){e9(e);return}if(e._f===t.RFC_2822){e8(e);return}e._a=[],c(e).empty=!0;var n,s,r,a,o,u,l,h,d,f,m,_=""+e._i,y=_.length,g=0;for(o=0,m=(l=H(e._f,e._locale).match(N)||[]).length;o<m;o++)(h=l[o],(u=(_.match(i(I,h)?I[h](e._strict,e._locale):new RegExp(eh(h.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(e,t,n,s,i){return t||n||s||i}))))||[])[0])&&((d=_.substr(0,_.indexOf(u))).length>0&&c(e).unusedInput.push(d),_=_.slice(_.indexOf(u)+u.length),g+=u.length),R[h])?(u?c(e).empty=!1:c(e).unusedTokens.push(h),null!=u&&i(ef,h)&&ef[h](u,e._a,e,h)):e._strict&&!u&&c(e).unusedTokens.push(h);c(e).charsLeftOver=y-g,_.length>0&&c(e).unusedInput.push(_),e._a[3]<=12&&!0===c(e).bigHour&&e._a[3]>0&&(c(e).bigHour=void 0),c(e).parsedDateParts=e._a.slice(0),c(e).meridiem=e._meridiem,e._a[3]=(n=e._locale,s=e._a[3],null==(r=e._meridiem)?s:null!=n.meridiemHour?n.meridiemHour(s,r):(null!=n.isPM&&((a=n.isPM(r))&&s<12&&(s+=12),a||12!==s||(s=0)),s)),null!==(f=c(e).era)&&(e._a[0]=e._locale.erasConvertYear(f,e._a[0])),tt(e),eK(e)}function ts(e){var i,r=e._i,d=e._f;return(e._locale=e._locale||eX(e._l),null===r||void 0===d&&""===r)?m({nullInput:!0}):("string"==typeof r&&(e._i=r=e._locale.preparse(r)),k(r))?new v(eK(r)):(u(r)?e._d=r:n(d)?function(e){var t,n,s,i,r,a,o=!1,u=e._f.length;if(0===u){c(e).invalidFormat=!0,e._d=new Date(NaN);return}for(i=0;i<u;i++)r=0,a=!1,t=p({},e),null!=e._useUTC&&(t._useUTC=e._useUTC),t._f=e._f[i],tn(t),f(t)&&(a=!0),r+=c(t).charsLeftOver+10*c(t).unusedTokens.length,c(t).score=r,o?r<s&&(s=r,n=t):(null==s||r<s||a)&&(s=r,n=t,a&&(o=!0));h(e,n||t)}(e):d?tn(e):a(i=e._i)?e._d=new Date(t.now()):u(i)?e._d=new Date(i.valueOf()):"string"==typeof i?function(e){var n=e6.exec(e._i);if(null!==n){e._d=new Date(+n[1]);return}e9(e),!1===e._isValid&&(delete e._isValid,e8(e),!1===e._isValid&&(delete e._isValid,e._strict?e._isValid=!1:t.createFromInputFallback(e)))}(e):n(i)?(e._a=l(i.slice(0),function(e){return parseInt(e,10)}),tt(e)):s(i)?function(e){if(!e._d){var t=E(e._i),n=void 0===t.day?t.date:t.day;e._a=l([t.year,t.month,n,t.hour,t.minute,t.second,t.millisecond],function(e){return e&&parseInt(e,10)}),tt(e)}}(e):o(i)?e._d=new Date(i):t.createFromInputFallback(e),f(e)||(e._d=null),e)}function ti(e,t,i,a,o){var u,l={};return(!0===t||!1===t)&&(a=t,t=void 0),(!0===i||!1===i)&&(a=i,i=void 0),(s(e)&&r(e)||n(e)&&0===e.length)&&(e=void 0),l._isAMomentObject=!0,l._useUTC=l._isUTC=o,l._l=i,l._i=e,l._f=t,l._strict=a,(u=new v(eK(ts(l))))._nextDay&&(u.add(1,"d"),u._nextDay=void 0),u}function tr(e,t,n,s){return ti(e,t,n,s,!1)}t.createFromInputFallback=D("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",function(e){e._d=new Date(e._i+(e._useUTC?" UTC":""))}),t.ISO_8601=function(){},t.RFC_2822=function(){};var ta=D("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var e=tr.apply(null,arguments);return this.isValid()&&e.isValid()?e<this?this:e:m()}),to=D("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var e=tr.apply(null,arguments);return this.isValid()&&e.isValid()?e>this?this:e:m()});function tu(e,t){var s,i;if(1===t.length&&n(t[0])&&(t=t[0]),!t.length)return tr();for(i=1,s=t[0];i<t.length;++i)(!t[i].isValid()||t[i][e](s))&&(s=t[i]);return s}var tl=["year","quarter","month","week","day","hour","minute","second","millisecond"];function th(e){var t=E(e),n=t.year||0,s=t.quarter||0,r=t.month||0,a=t.week||t.isoWeek||0,o=t.day||0,u=t.hour||0,l=t.minute||0,h=t.second||0,d=t.millisecond||0;this._isValid=function(e){var t,n,s=!1,r=tl.length;for(t in e)if(i(e,t)&&!(-1!==eA.call(tl,t)&&(null==e[t]||!isNaN(e[t]))))return!1;for(n=0;n<r;++n)if(e[tl[n]]){if(s)return!1;parseFloat(e[tl[n]])!==ec(e[tl[n]])&&(s=!0)}return!0}(t),this._milliseconds=+d+1e3*h+6e4*l+36e5*u,this._days=+o+7*a,this._months=+r+3*s+12*n,this._data={},this._locale=eX(),this._bubble()}function td(e){return e instanceof th}function tc(e){return e<0?-1*Math.round(-1*e):Math.round(e)}function tf(e,t){C(e,0,0,function(){var e=this.utcOffset(),n="+";return e<0&&(e=-e,n="-"),n+x(~~(e/60),2)+t+x(~~e%60,2)})}tf("Z",":"),tf("ZZ",""),el("Z",er),el("ZZ",er),em(["Z","ZZ"],function(e,t,n){n._useUTC=!0,n._tzm=t_(er,e)});var tm=/([\+\-]|\d\d)/gi;function t_(e,t){var n,s,i=(t||"").match(e);return null===i?null:0===(s=+(60*(n=((i[i.length-1]||[])+"").match(tm)||["-",0,0])[1])+ec(n[2]))?0:"+"===n[0]?s:-s}function ty(e,n){var s,i;return n._isUTC?(s=n.clone(),i=(k(e)||u(e)?e.valueOf():tr(e).valueOf())-s.valueOf(),s._d.setTime(s._d.valueOf()+i),t.updateOffset(s,!1),s):tr(e).local()}function tg(e){return-Math.round(e._d.getTimezoneOffset())}function tw(){return!!this.isValid()&&this._isUTC&&0===this._offset}t.updateOffset=function(){};var tp=/^(-|\+)?(?:(\d*)[. ])?(\d+):(\d+)(?::(\d+)(\.\d*)?)?$/,tv=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function tk(e,t){var n,s,r,a,u,l,h=e,d=null;return td(e)?h={ms:e._milliseconds,d:e._days,M:e._months}:o(e)||!isNaN(+e)?(h={},t?h[t]=+e:h.milliseconds=+e):(d=tp.exec(e))?(a="-"===d[1]?-1:1,h={y:0,d:ec(d[2])*a,h:ec(d[3])*a,m:ec(d[4])*a,s:ec(d[5])*a,ms:ec(tc(1e3*d[6]))*a}):(d=tv.exec(e))?(a="-"===d[1]?-1:1,h={y:tM(d[2],a),M:tM(d[3],a),w:tM(d[4],a),d:tM(d[5],a),h:tM(d[6],a),m:tM(d[7],a),s:tM(d[8],a)}):null==h?h={}:"object"==typeof h&&("from"in h||"to"in h)&&(n=tr(h.from),s=tr(h.to),l=n.isValid()&&s.isValid()?(s=ty(s,n),n.isBefore(s)?r=tD(n,s):((r=tD(s,n)).milliseconds=-r.milliseconds,r.months=-r.months),r):{milliseconds:0,months:0},(h={}).ms=l.milliseconds,h.M=l.months),u=new th(h),td(e)&&i(e,"_locale")&&(u._locale=e._locale),td(e)&&i(e,"_isValid")&&(u._isValid=e._isValid),u}function tM(e,t){var n=e&&parseFloat(e.replace(",","."));return(isNaN(n)?0:n)*t}function tD(e,t){var n={};return n.months=t.month()-e.month()+(t.year()-e.year())*12,e.clone().add(n.months,"M").isAfter(t)&&--n.months,n.milliseconds=+t-+e.clone().add(n.months,"M"),n}function tY(e,t){return function(n,s){var i;return null===s||isNaN(+s)||(S(t,"moment()."+t+"(period, number) is deprecated. Please use moment()."+t+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),i=n,n=s,s=i),tS(this,tk(n,s),e),this}}function tS(e,n,s,i){var r=n._milliseconds,a=tc(n._days),o=tc(n._months);e.isValid()&&(i=null==i||i,o&&eO(e,ev(e,"Month")+o*s),a&&ek(e,"Date",ev(e,"Date")+a*s),r&&e._d.setTime(e._d.valueOf()+r*s),i&&t.updateOffset(e,a||o))}tk.fn=th.prototype,tk.invalid=function(){return tk(NaN)};var tO=tY(1,"add"),tb=tY(-1,"subtract");function tT(e){return"string"==typeof e||e instanceof String}function tx(e,t){if(e.date()<t.date())return-tx(t,e);var n,s=(t.year()-e.year())*12+(t.month()-e.month()),i=e.clone().add(s,"months");return n=t-i<0?(t-i)/(i-e.clone().add(s-1,"months")):(t-i)/(e.clone().add(s+1,"months")-i),-(s+n)||0}function tN(e){var t;return void 0===e?this._locale._abbr:(null!=(t=eX(e))&&(this._locale=t),this)}t.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",t.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";var tW=D("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(e){return void 0===e?this.localeData():this.locale(e)});function tP(){return this._locale}function tR(e,t,n){return e<100&&e>=0?new Date(e+400,t,n)-126227808e5:new Date(e,t,n).valueOf()}function tC(e,t,n){return e<100&&e>=0?Date.UTC(e+400,t,n)-126227808e5:Date.UTC(e,t,n)}function tU(e,t){return t.erasAbbrRegex(e)}function tH(){var e,t,n,s,i,r=[],a=[],o=[],u=[],l=this.eras();for(e=0,t=l.length;e<t;++e)n=eh(l[e].name),s=eh(l[e].abbr),i=eh(l[e].narrow),a.push(n),r.push(s),o.push(i),u.push(n),u.push(s),u.push(i);this._erasRegex=RegExp("^("+u.join("|")+")","i"),this._erasNameRegex=RegExp("^("+a.join("|")+")","i"),this._erasAbbrRegex=RegExp("^("+r.join("|")+")","i"),this._erasNarrowRegex=RegExp("^("+o.join("|")+")","i")}function tF(e,t){C(0,[e,e.length],0,t)}function tL(e,t,n,s,i){var r;return null==e?eR(this,s,i).year:(t>(r=eC(e,s,i))&&(t=r),tE.call(this,e,t,n,s,i))}function tE(e,t,n,s,i){var r=eP(e,t,n,s,i),a=eN(r.year,0,r.dayOfYear);return this.year(a.getUTCFullYear()),this.month(a.getUTCMonth()),this.date(a.getUTCDate()),this}C("N",0,0,"eraAbbr"),C("NN",0,0,"eraAbbr"),C("NNN",0,0,"eraAbbr"),C("NNNN",0,0,"eraName"),C("NNNNN",0,0,"eraNarrow"),C("y",["y",1],"yo","eraYear"),C("y",["yy",2],0,"eraYear"),C("y",["yyy",3],0,"eraYear"),C("y",["yyyy",4],0,"eraYear"),el("N",tU),el("NN",tU),el("NNN",tU),el("NNNN",function(e,t){return t.erasNameRegex(e)}),el("NNNNN",function(e,t){return t.erasNarrowRegex(e)}),em(["N","NN","NNN","NNNN","NNNNN"],function(e,t,n,s){var i=n._locale.erasParse(e,s,n._strict);i?c(n).era=i:c(n).invalidEra=e}),el("y",en),el("yy",en),el("yyy",en),el("yyyy",en),el("yo",function(e,t){return t._eraYearOrdinalRegex||en}),em(["y","yy","yyy","yyyy"],0),em(["yo"],function(e,t,n,s){var i;n._locale._eraYearOrdinalRegex&&(i=e.match(n._locale._eraYearOrdinalRegex)),n._locale.eraYearOrdinalParse?t[0]=n._locale.eraYearOrdinalParse(e,i):t[0]=parseInt(e,10)}),C(0,["gg",2],0,function(){return this.weekYear()%100}),C(0,["GG",2],0,function(){return this.isoWeekYear()%100}),tF("gggg","weekYear"),tF("ggggg","weekYear"),tF("GGGG","isoWeekYear"),tF("GGGGG","isoWeekYear"),el("G",es),el("g",es),el("GG",J,z),el("gg",J,z),el("GGGG",ee,q),el("gggg",ee,q),el("GGGGG",et,B),el("ggggg",et,B),e_(["gggg","ggggg","GGGG","GGGGG"],function(e,t,n,s){t[s.substr(0,2)]=ec(e)}),e_(["gg","GG"],function(e,n,s,i){n[i]=t.parseTwoDigitYear(e)}),C("Q",0,"Qo","quarter"),el("Q",Z),em("Q",function(e,t){t[1]=(ec(e)-1)*3}),C("D",["DD",2],"Do","date"),el("D",J,eo),el("DD",J,z),el("Do",function(e,t){return e?t._dayOfMonthOrdinalParse||t._ordinalParse:t._dayOfMonthOrdinalParseLenient}),em(["D","DD"],2),em("Do",function(e,t){t[2]=ec(e.match(J)[0])});var tV=ep("Date",!0);C("DDD",["DDDD",3],"DDDo","dayOfYear"),el("DDD",K),el("DDDD",$),em(["DDD","DDDD"],function(e,t,n){n._dayOfYear=ec(e)}),C("m",["mm",2],0,"minute"),el("m",J,eu),el("mm",J,z),em(["m","mm"],4);var tG=ep("Minutes",!1);C("s",["ss",2],0,"second"),el("s",J,eu),el("ss",J,z),em(["s","ss"],5);var tA=ep("Seconds",!1);for(C("S",0,0,function(){return~~(this.millisecond()/100)}),C(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),C(0,["SSS",3],0,"millisecond"),C(0,["SSSS",4],0,function(){return 10*this.millisecond()}),C(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),C(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),C(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),C(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),C(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),el("S",K,Z),el("SS",K,z),el("SSS",K,$),_="SSSS";_.length<=9;_+="S")el(_,en);function tI(e,t){t[6]=ec(("0."+e)*1e3)}for(_="S";_.length<=9;_+="S")em(_,tI);y=ep("Milliseconds",!1),C("z",0,0,"zoneAbbr"),C("zz",0,0,"zoneName");var tj=v.prototype;function tZ(e){return e}tj.add=tO,tj.calendar=function(e,a){if(1==arguments.length){if(arguments[0]){var l,h,d;(l=arguments[0],k(l)||u(l)||tT(l)||o(l)||(h=n(l),d=!1,h&&(d=0===l.filter(function(e){return!o(e)&&tT(l)}).length),h&&d)||function(e){var t,n,a=s(e)&&!r(e),o=!1,u=["years","year","y","months","month","M","days","day","d","dates","date","D","hours","hour","h","minutes","minute","m","seconds","second","s","milliseconds","millisecond","ms"],l=u.length;for(t=0;t<l;t+=1)n=u[t],o=o||i(e,n);return a&&o}(l)||null==l)?(e=arguments[0],a=void 0):function(e){var t,n,a=s(e)&&!r(e),o=!1,u=["sameDay","nextDay","lastDay","nextWeek","lastWeek","sameElse"];for(t=0;t<u.length;t+=1)n=u[t],o=o||i(e,n);return a&&o}(arguments[0])&&(a=arguments[0],e=void 0)}else e=void 0,a=void 0}var c=e||tr(),f=ty(c,this).startOf("day"),m=t.calendarFormat(this,f)||"sameElse",_=a&&(O(a[m])?a[m].call(this,c):a[m]);return this.format(_||this.localeData().calendar(m,this,tr(c)))},tj.clone=function(){return new v(this)},tj.diff=function(e,t,n){var s,i,r;if(!this.isValid()||!(s=ty(e,this)).isValid())return NaN;switch(i=(s.utcOffset()-this.utcOffset())*6e4,t=L(t)){case"year":r=tx(this,s)/12;break;case"month":r=tx(this,s);break;case"quarter":r=tx(this,s)/3;break;case"second":r=(this-s)/1e3;break;case"minute":r=(this-s)/6e4;break;case"hour":r=(this-s)/36e5;break;case"day":r=(this-s-i)/864e5;break;case"week":r=(this-s-i)/6048e5;break;default:r=this-s}return n?r:ed(r)},tj.endOf=function(e){var n,s;if(void 0===(e=L(e))||"millisecond"===e||!this.isValid())return this;switch(s=this._isUTC?tC:tR,e){case"year":n=s(this.year()+1,0,1)-1;break;case"quarter":n=s(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":n=s(this.year(),this.month()+1,1)-1;break;case"week":n=s(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":n=s(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":n=s(this.year(),this.month(),this.date()+1)-1;break;case"hour":n=this._d.valueOf(),n+=36e5-((n+(this._isUTC?0:6e4*this.utcOffset()))%36e5+36e5)%36e5-1;break;case"minute":n=this._d.valueOf(),n+=6e4-(n%6e4+6e4)%6e4-1;break;case"second":n=this._d.valueOf(),n+=1e3-(n%1e3+1e3)%1e3-1}return this._d.setTime(n),t.updateOffset(this,!0),this},tj.format=function(e){e||(e=this.isUtc()?t.defaultFormatUtc:t.defaultFormat);var n=U(this,e);return this.localeData().postformat(n)},tj.from=function(e,t){return this.isValid()&&(k(e)&&e.isValid()||tr(e).isValid())?tk({to:this,from:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()},tj.fromNow=function(e){return this.from(tr(),e)},tj.to=function(e,t){return this.isValid()&&(k(e)&&e.isValid()||tr(e).isValid())?tk({from:this,to:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()},tj.toNow=function(e){return this.to(tr(),e)},tj.get=function(e){return O(this[e=L(e)])?this[e]():this},tj.invalidAt=function(){return c(this).overflow},tj.isAfter=function(e,t){var n=k(e)?e:tr(e);return!!(this.isValid()&&n.isValid())&&("millisecond"===(t=L(t)||"millisecond")?this.valueOf()>n.valueOf():n.valueOf()<this.clone().startOf(t).valueOf())},tj.isBefore=function(e,t){var n=k(e)?e:tr(e);return!!(this.isValid()&&n.isValid())&&("millisecond"===(t=L(t)||"millisecond")?this.valueOf()<n.valueOf():this.clone().endOf(t).valueOf()<n.valueOf())},tj.isBetween=function(e,t,n,s){var i=k(e)?e:tr(e),r=k(t)?t:tr(t);return!!(this.isValid()&&i.isValid()&&r.isValid())&&("("===(s=s||"()")[0]?this.isAfter(i,n):!this.isBefore(i,n))&&(")"===s[1]?this.isBefore(r,n):!this.isAfter(r,n))},tj.isSame=function(e,t){var n,s=k(e)?e:tr(e);return!!(this.isValid()&&s.isValid())&&("millisecond"===(t=L(t)||"millisecond")?this.valueOf()===s.valueOf():(n=s.valueOf(),this.clone().startOf(t).valueOf()<=n&&n<=this.clone().endOf(t).valueOf()))},tj.isSameOrAfter=function(e,t){return this.isSame(e,t)||this.isAfter(e,t)},tj.isSameOrBefore=function(e,t){return this.isSame(e,t)||this.isBefore(e,t)},tj.isValid=function(){return f(this)},tj.lang=tW,tj.locale=tN,tj.localeData=tP,tj.max=to,tj.min=ta,tj.parsingFlags=function(){return h({},c(this))},tj.set=function(e,t){if("object"==typeof e){var n,s=function(e){var t,n=[];for(t in e)i(e,t)&&n.push({unit:t,priority:j[t]});return n.sort(function(e,t){return e.priority-t.priority}),n}(e=E(e)),r=s.length;for(n=0;n<r;n++)this[s[n].unit](e[s[n].unit])}else if(O(this[e=L(e)]))return this[e](t);return this},tj.startOf=function(e){var n,s;if(void 0===(e=L(e))||"millisecond"===e||!this.isValid())return this;switch(s=this._isUTC?tC:tR,e){case"year":n=s(this.year(),0,1);break;case"quarter":n=s(this.year(),this.month()-this.month()%3,1);break;case"month":n=s(this.year(),this.month(),1);break;case"week":n=s(this.year(),this.month(),this.date()-this.weekday());break;case"isoWeek":n=s(this.year(),this.month(),this.date()-(this.isoWeekday()-1));break;case"day":case"date":n=s(this.year(),this.month(),this.date());break;case"hour":n=this._d.valueOf(),n-=((n+(this._isUTC?0:6e4*this.utcOffset()))%36e5+36e5)%36e5;break;case"minute":n=this._d.valueOf(),n-=(n%6e4+6e4)%6e4;break;case"second":n=this._d.valueOf(),n-=(n%1e3+1e3)%1e3}return this._d.setTime(n),t.updateOffset(this,!0),this},tj.subtract=tb,tj.toArray=function(){return[this.year(),this.month(),this.date(),this.hour(),this.minute(),this.second(),this.millisecond()]},tj.toObject=function(){return{years:this.year(),months:this.month(),date:this.date(),hours:this.hours(),minutes:this.minutes(),seconds:this.seconds(),milliseconds:this.milliseconds()}},tj.toDate=function(){return new Date(this.valueOf())},tj.toISOString=function(e){if(!this.isValid())return null;var t=!0!==e,n=t?this.clone().utc():this;return 0>n.year()||n.year()>9999?U(n,t?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):O(Date.prototype.toISOString)?t?this.toDate().toISOString():new Date(this.valueOf()+6e4*this.utcOffset()).toISOString().replace("Z",U(n,"Z")):U(n,t?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")},tj.inspect=function(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var e,t,n,s,i="moment",r="";return this.isLocal()||(i=0===this.utcOffset()?"moment.utc":"moment.parseZone",r="Z"),e="["+i+'("]',t=0<=this.year()&&9999>=this.year()?"YYYY":"YYYYYY",n="-MM-DD[T]HH:mm:ss.SSS",s=r+'[")]',this.format(e+t+n+s)},"undefined"!=typeof Symbol&&null!=Symbol.for&&(tj[Symbol.for("nodejs.util.inspect.custom")]=function(){return"Moment<"+this.format()+">"}),tj.toJSON=function(){return this.isValid()?this.toISOString():null},tj.toString=function(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")},tj.unix=function(){return Math.floor(this.valueOf()/1e3)},tj.valueOf=function(){return this._d.valueOf()-6e4*(this._offset||0)},tj.creationData=function(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}},tj.eraName=function(){var e,t,n,s=this.localeData().eras();for(e=0,t=s.length;e<t;++e)if(n=this.clone().startOf("day").valueOf(),s[e].since<=n&&n<=s[e].until||s[e].until<=n&&n<=s[e].since)return s[e].name;return""},tj.eraNarrow=function(){var e,t,n,s=this.localeData().eras();for(e=0,t=s.length;e<t;++e)if(n=this.clone().startOf("day").valueOf(),s[e].since<=n&&n<=s[e].until||s[e].until<=n&&n<=s[e].since)return s[e].narrow;return""},tj.eraAbbr=function(){var e,t,n,s=this.localeData().eras();for(e=0,t=s.length;e<t;++e)if(n=this.clone().startOf("day").valueOf(),s[e].since<=n&&n<=s[e].until||s[e].until<=n&&n<=s[e].since)return s[e].abbr;return""},tj.eraYear=function(){var e,n,s,i,r=this.localeData().eras();for(e=0,n=r.length;e<n;++e)if(s=r[e].since<=r[e].until?1:-1,i=this.clone().startOf("day").valueOf(),r[e].since<=i&&i<=r[e].until||r[e].until<=i&&i<=r[e].since)return(this.year()-t(r[e].since).year())*s+r[e].offset;return this.year()},tj.year=ew,tj.isLeapYear=function(){return ey(this.year())},tj.weekYear=function(e){return tL.call(this,e,this.week(),this.weekday()+this.localeData()._week.dow,this.localeData()._week.dow,this.localeData()._week.doy)},tj.isoWeekYear=function(e){return tL.call(this,e,this.isoWeek(),this.isoWeekday(),1,4)},tj.quarter=tj.quarters=function(e){return null==e?Math.ceil((this.month()+1)/3):this.month((e-1)*3+this.month()%3)},tj.month=eb,tj.daysInMonth=function(){return eM(this.year(),this.month())},tj.week=tj.weeks=function(e){var t=this.localeData().week(this);return null==e?t:this.add((e-t)*7,"d")},tj.isoWeek=tj.isoWeeks=function(e){var t=eR(this,1,4).week;return null==e?t:this.add((e-t)*7,"d")},tj.weeksInYear=function(){var e=this.localeData()._week;return eC(this.year(),e.dow,e.doy)},tj.weeksInWeekYear=function(){var e=this.localeData()._week;return eC(this.weekYear(),e.dow,e.doy)},tj.isoWeeksInYear=function(){return eC(this.year(),1,4)},tj.isoWeeksInISOWeekYear=function(){return eC(this.isoWeekYear(),1,4)},tj.date=tV,tj.day=tj.days=function(e){if(!this.isValid())return null!=e?this:NaN;var t,n,s=ev(this,"Day");return null==e?s:(t=e,n=this.localeData(),e="string"!=typeof t?t:isNaN(t)?"number"==typeof(t=n.weekdaysParse(t))?t:null:parseInt(t,10),this.add(e-s,"d"))},tj.weekday=function(e){if(!this.isValid())return null!=e?this:NaN;var t=(this.day()+7-this.localeData()._week.dow)%7;return null==e?t:this.add(e-t,"d")},tj.isoWeekday=function(e){if(!this.isValid())return null!=e?this:NaN;if(null==e)return this.day()||7;var t,n=(t=this.localeData(),"string"==typeof e?t.weekdaysParse(e)%7||7:isNaN(e)?null:e);return this.day(this.day()%7?n:n-7)},tj.dayOfYear=function(e){var t=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==e?t:this.add(e-t,"d")},tj.hour=tj.hours=ej,tj.minute=tj.minutes=tG,tj.second=tj.seconds=tA,tj.millisecond=tj.milliseconds=y,tj.utcOffset=function(e,n,s){var i,r=this._offset||0;if(!this.isValid())return null!=e?this:NaN;if(null==e)return this._isUTC?r:tg(this);if("string"==typeof e){if(null===(e=t_(er,e)))return this}else 16>Math.abs(e)&&!s&&(e*=60);return!this._isUTC&&n&&(i=tg(this)),this._offset=e,this._isUTC=!0,null!=i&&this.add(i,"m"),r===e||(!n||this._changeInProgress?tS(this,tk(e-r,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,t.updateOffset(this,!0),this._changeInProgress=null)),this},tj.utc=function(e){return this.utcOffset(0,e)},tj.local=function(e){return this._isUTC&&(this.utcOffset(0,e),this._isUTC=!1,e&&this.subtract(tg(this),"m")),this},tj.parseZone=function(){if(null!=this._tzm)this.utcOffset(this._tzm,!1,!0);else if("string"==typeof this._i){var e=t_(ei,this._i);null!=e?this.utcOffset(e):this.utcOffset(0,!0)}return this},tj.hasAlignedHourOffset=function(e){return!!this.isValid()&&(e=e?tr(e).utcOffset():0,(this.utcOffset()-e)%60==0)},tj.isDST=function(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()},tj.isLocal=function(){return!!this.isValid()&&!this._isUTC},tj.isUtcOffset=function(){return!!this.isValid()&&this._isUTC},tj.isUtc=tw,tj.isUTC=tw,tj.zoneAbbr=function(){return this._isUTC?"UTC":""},tj.zoneName=function(){return this._isUTC?"Coordinated Universal Time":""},tj.dates=D("dates accessor is deprecated. Use date instead.",tV),tj.months=D("months accessor is deprecated. Use month instead",eb),tj.years=D("years accessor is deprecated. Use year instead",ew),tj.zone=D("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",function(e,t){return null!=e?("string"!=typeof e&&(e=-e),this.utcOffset(e,t),this):-this.utcOffset()}),tj.isDSTShifted=D("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",function(){if(!a(this._isDSTShifted))return this._isDSTShifted;var e,t={};return p(t,this),(t=ts(t))._a?(e=t._isUTC?d(t._a):tr(t._a),this._isDSTShifted=this.isValid()&&function(e,t,n){var s,i=Math.min(e.length,t.length),r=Math.abs(e.length-t.length),a=0;for(s=0;s<i;s++)ec(e[s])!==ec(t[s])&&a++;return a+r}(t._a,e.toArray())>0):this._isDSTShifted=!1,this._isDSTShifted});var tz=T.prototype;function t$(e,t,n,s){var i=eX(),r=d().set(s,t);return i[n](r,e)}function tq(e,t,n){if(o(e)&&(t=e,e=void 0),e=e||"",null!=t)return t$(e,t,n,"month");var s,i=[];for(s=0;s<12;s++)i[s]=t$(e,s,n,"month");return i}function tB(e,t,n,s){"boolean"==typeof e||(n=t=e,e=!1),o(t)&&(n=t,t=void 0),t=t||"";var i,r=eX(),a=e?r._week.dow:0,u=[];if(null!=n)return t$(t,(n+a)%7,s,"day");for(i=0;i<7;i++)u[i]=t$(t,(i+a)%7,s,"day");return u}tz.calendar=function(e,t,n){var s=this._calendar[e]||this._calendar.sameElse;return O(s)?s.call(t,n):s},tz.longDateFormat=function(e){var t=this._longDateFormat[e],n=this._longDateFormat[e.toUpperCase()];return t||!n?t:(this._longDateFormat[e]=n.match(N).map(function(e){return"MMMM"===e||"MM"===e||"DD"===e||"dddd"===e?e.slice(1):e}).join(""),this._longDateFormat[e])},tz.invalidDate=function(){return this._invalidDate},tz.ordinal=function(e){return this._ordinal.replace("%d",e)},tz.preparse=tZ,tz.postformat=tZ,tz.relativeTime=function(e,t,n,s){var i=this._relativeTime[n];return O(i)?i(e,t,n,s):i.replace(/%d/i,e)},tz.pastFuture=function(e,t){var n=this._relativeTime[e>0?"future":"past"];return O(n)?n(t):n.replace(/%s/i,t)},tz.set=function(e){var t,n;for(n in e)i(e,n)&&(O(t=e[n])?this[n]=t:this["_"+n]=t);this._config=e,this._dayOfMonthOrdinalParseLenient=RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)},tz.eras=function(e,n){var s,i,r,a=this._eras||eX("en")._eras;for(s=0,i=a.length;s<i;++s)switch("string"==typeof a[s].since&&(r=t(a[s].since).startOf("day"),a[s].since=r.valueOf()),typeof a[s].until){case"undefined":a[s].until=Infinity;break;case"string":r=t(a[s].until).startOf("day").valueOf(),a[s].until=r.valueOf()}return a},tz.erasParse=function(e,t,n){var s,i,r,a,o,u=this.eras();for(s=0,e=e.toUpperCase(),i=u.length;s<i;++s)if(r=u[s].name.toUpperCase(),a=u[s].abbr.toUpperCase(),o=u[s].narrow.toUpperCase(),n)switch(t){case"N":case"NN":case"NNN":if(a===e)return u[s];break;case"NNNN":if(r===e)return u[s];break;case"NNNNN":if(o===e)return u[s]}else if([r,a,o].indexOf(e)>=0)return u[s]},tz.erasConvertYear=function(e,n){var s=e.since<=e.until?1:-1;return void 0===n?t(e.since).year():t(e.since).year()+(n-e.offset)*s},tz.erasAbbrRegex=function(e){return i(this,"_erasAbbrRegex")||tH.call(this),e?this._erasAbbrRegex:this._erasRegex},tz.erasNameRegex=function(e){return i(this,"_erasNameRegex")||tH.call(this),e?this._erasNameRegex:this._erasRegex},tz.erasNarrowRegex=function(e){return i(this,"_erasNarrowRegex")||tH.call(this),e?this._erasNarrowRegex:this._erasRegex},tz.months=function(e,t){return e?n(this._months)?this._months[e.month()]:this._months[(this._months.isFormat||eY).test(t)?"format":"standalone"][e.month()]:n(this._months)?this._months:this._months.standalone},tz.monthsShort=function(e,t){return e?n(this._monthsShort)?this._monthsShort[e.month()]:this._monthsShort[eY.test(t)?"format":"standalone"][e.month()]:n(this._monthsShort)?this._monthsShort:this._monthsShort.standalone},tz.monthsParse=function(e,t,n){var s,i,r;if(this._monthsParseExact)return eS.call(this,e,t,n);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),s=0;s<12;s++)if(i=d([2e3,s]),n&&!this._longMonthsParse[s]&&(this._longMonthsParse[s]=RegExp("^"+this.months(i,"").replace(".","")+"$","i"),this._shortMonthsParse[s]=RegExp("^"+this.monthsShort(i,"").replace(".","")+"$","i")),n||this._monthsParse[s]||(r="^"+this.months(i,"")+"|^"+this.monthsShort(i,""),this._monthsParse[s]=RegExp(r.replace(".",""),"i")),n&&"MMMM"===t&&this._longMonthsParse[s].test(e)||n&&"MMM"===t&&this._shortMonthsParse[s].test(e)||!n&&this._monthsParse[s].test(e))return s},tz.monthsRegex=function(e){return this._monthsParseExact?(i(this,"_monthsRegex")||eT.call(this),e)?this._monthsStrictRegex:this._monthsRegex:(i(this,"_monthsRegex")||(this._monthsRegex=ea),this._monthsStrictRegex&&e?this._monthsStrictRegex:this._monthsRegex)},tz.monthsShortRegex=function(e){return this._monthsParseExact?(i(this,"_monthsRegex")||eT.call(this),e)?this._monthsShortStrictRegex:this._monthsShortRegex:(i(this,"_monthsShortRegex")||(this._monthsShortRegex=ea),this._monthsShortStrictRegex&&e?this._monthsShortStrictRegex:this._monthsShortRegex)},tz.week=function(e){return eR(e,this._week.dow,this._week.doy).week},tz.firstDayOfYear=function(){return this._week.doy},tz.firstDayOfWeek=function(){return this._week.dow},tz.weekdays=function(e,t){var s=n(this._weekdays)?this._weekdays:this._weekdays[e&&!0!==e&&this._weekdays.isFormat.test(t)?"format":"standalone"];return!0===e?eU(s,this._week.dow):e?s[e.day()]:s},tz.weekdaysMin=function(e){return!0===e?eU(this._weekdaysMin,this._week.dow):e?this._weekdaysMin[e.day()]:this._weekdaysMin},tz.weekdaysShort=function(e){return!0===e?eU(this._weekdaysShort,this._week.dow):e?this._weekdaysShort[e.day()]:this._weekdaysShort},tz.weekdaysParse=function(e,t,n){var s,i,r;if(this._weekdaysParseExact)return eF.call(this,e,t,n);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),s=0;s<7;s++){if(i=d([2e3,1]).day(s),n&&!this._fullWeekdaysParse[s]&&(this._fullWeekdaysParse[s]=RegExp("^"+this.weekdays(i,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[s]=RegExp("^"+this.weekdaysShort(i,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[s]=RegExp("^"+this.weekdaysMin(i,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[s]||(r="^"+this.weekdays(i,"")+"|^"+this.weekdaysShort(i,"")+"|^"+this.weekdaysMin(i,""),this._weekdaysParse[s]=RegExp(r.replace(".",""),"i")),n&&"dddd"===t&&this._fullWeekdaysParse[s].test(e)||n&&"ddd"===t&&this._shortWeekdaysParse[s].test(e))return s;if(n&&"dd"===t&&this._minWeekdaysParse[s].test(e))return s;if(!n&&this._weekdaysParse[s].test(e))return s}},tz.weekdaysRegex=function(e){return this._weekdaysParseExact?(i(this,"_weekdaysRegex")||eL.call(this),e)?this._weekdaysStrictRegex:this._weekdaysRegex:(i(this,"_weekdaysRegex")||(this._weekdaysRegex=ea),this._weekdaysStrictRegex&&e?this._weekdaysStrictRegex:this._weekdaysRegex)},tz.weekdaysShortRegex=function(e){return this._weekdaysParseExact?(i(this,"_weekdaysRegex")||eL.call(this),e)?this._weekdaysShortStrictRegex:this._weekdaysShortRegex:(i(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=ea),this._weekdaysShortStrictRegex&&e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)},tz.weekdaysMinRegex=function(e){return this._weekdaysParseExact?(i(this,"_weekdaysRegex")||eL.call(this),e)?this._weekdaysMinStrictRegex:this._weekdaysMinRegex:(i(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=ea),this._weekdaysMinStrictRegex&&e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)},tz.isPM=function(e){return"p"===(e+"").toLowerCase().charAt(0)},tz.meridiem=function(e,t,n){return e>11?n?"pm":"PM":n?"am":"AM"},eJ("en",{eras:[{since:"0001-01-01",until:Infinity,offset:1,name:"Anno Domini",narrow:"AD",abbr:"AD"},{since:"0000-12-31",until:-1/0,offset:1,name:"Before Christ",narrow:"BC",abbr:"BC"}],dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10,n=1===ec(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th";return e+n}}),t.lang=D("moment.lang is deprecated. Use moment.locale instead.",eJ),t.langData=D("moment.langData is deprecated. Use moment.localeData instead.",eX);var tJ=Math.abs;function tQ(e,t,n,s){var i=tk(t,n);return e._milliseconds+=s*i._milliseconds,e._days+=s*i._days,e._months+=s*i._months,e._bubble()}function tX(e){return e<0?Math.floor(e):Math.ceil(e)}function tK(e){return 4800*e/146097}function t0(e){return 146097*e/4800}function t1(e){return function(){return this.as(e)}}var t2=t1("ms"),t4=t1("s"),t3=t1("m"),t6=t1("h"),t5=t1("d"),t7=t1("w"),t9=t1("M"),t8=t1("Q"),ne=t1("y");function nt(e){return function(){return this.isValid()?this._data[e]:NaN}}var nn=nt("milliseconds"),ns=nt("seconds"),ni=nt("minutes"),nr=nt("hours"),na=nt("days"),no=nt("months"),nu=nt("years"),nl=Math.round,nh={ss:44,s:45,m:45,h:22,d:26,w:null,M:11};function nd(e,t,n,s,i){return i.relativeTime(t||1,!!n,e,s)}var nc=Math.abs;function nf(e){return(e>0)-(e<0)||+e}function nm(){if(!this.isValid())return this.localeData().invalidDate();var e,t,n,s,i,r,a,o,u=nc(this._milliseconds)/1e3,l=nc(this._days),h=nc(this._months),d=this.asSeconds();return d?(e=ed(u/60),t=ed(e/60),u%=60,e%=60,n=ed(h/12),h%=12,s=u?u.toFixed(3).replace(/\.?0+$/,""):"",i=d<0?"-":"",r=nf(this._months)!==nf(d)?"-":"",a=nf(this._days)!==nf(d)?"-":"",o=nf(this._milliseconds)!==nf(d)?"-":"",i+"P"+(n?r+n+"Y":"")+(h?r+h+"M":"")+(l?a+l+"D":"")+(t||e||u?"T":"")+(t?o+t+"H":"")+(e?o+e+"M":"")+(u?o+s+"S":"")):"P0D"}var n_=th.prototype;return n_.isValid=function(){return this._isValid},n_.abs=function(){var e=this._data;return this._milliseconds=tJ(this._milliseconds),this._days=tJ(this._days),this._months=tJ(this._months),e.milliseconds=tJ(e.milliseconds),e.seconds=tJ(e.seconds),e.minutes=tJ(e.minutes),e.hours=tJ(e.hours),e.months=tJ(e.months),e.years=tJ(e.years),this},n_.add=function(e,t){return tQ(this,e,t,1)},n_.subtract=function(e,t){return tQ(this,e,t,-1)},n_.as=function(e){if(!this.isValid())return NaN;var t,n,s=this._milliseconds;if("month"===(e=L(e))||"quarter"===e||"year"===e)switch(t=this._days+s/864e5,n=this._months+tK(t),e){case"month":return n;case"quarter":return n/3;case"year":return n/12}else switch(t=this._days+Math.round(t0(this._months)),e){case"week":return t/7+s/6048e5;case"day":return t+s/864e5;case"hour":return 24*t+s/36e5;case"minute":return 1440*t+s/6e4;case"second":return 86400*t+s/1e3;case"millisecond":return Math.floor(864e5*t)+s;default:throw Error("Unknown unit "+e)}},n_.asMilliseconds=t2,n_.asSeconds=t4,n_.asMinutes=t3,n_.asHours=t6,n_.asDays=t5,n_.asWeeks=t7,n_.asMonths=t9,n_.asQuarters=t8,n_.asYears=ne,n_.valueOf=t2,n_._bubble=function(){var e,t,n,s,i,r=this._milliseconds,a=this._days,o=this._months,u=this._data;return r>=0&&a>=0&&o>=0||r<=0&&a<=0&&o<=0||(r+=864e5*tX(t0(o)+a),a=0,o=0),u.milliseconds=r%1e3,e=ed(r/1e3),u.seconds=e%60,t=ed(e/60),u.minutes=t%60,n=ed(t/60),u.hours=n%24,a+=ed(n/24),o+=i=ed(tK(a)),a-=tX(t0(i)),s=ed(o/12),o%=12,u.days=a,u.months=o,u.years=s,this},n_.clone=function(){return tk(this)},n_.get=function(e){return e=L(e),this.isValid()?this[e+"s"]():NaN},n_.milliseconds=nn,n_.seconds=ns,n_.minutes=ni,n_.hours=nr,n_.days=na,n_.weeks=function(){return ed(this.days()/7)},n_.months=no,n_.years=nu,n_.humanize=function(e,t){if(!this.isValid())return this.localeData().invalidDate();var n,s,i,r,a,o,u,l,h,d,c,f,m,_=!1,y=nh;return"object"==typeof e&&(t=e,e=!1),"boolean"==typeof e&&(_=e),"object"==typeof t&&(y=Object.assign({},nh,t),null!=t.s&&null==t.ss&&(y.ss=t.s-1)),f=this.localeData(),n=!_,s=y,i=tk(this).abs(),r=nl(i.as("s")),a=nl(i.as("m")),o=nl(i.as("h")),u=nl(i.as("d")),l=nl(i.as("M")),h=nl(i.as("w")),d=nl(i.as("y")),c=r<=s.ss&&["s",r]||r<s.s&&["ss",r]||a<=1&&["m"]||a<s.m&&["mm",a]||o<=1&&["h"]||o<s.h&&["hh",o]||u<=1&&["d"]||u<s.d&&["dd",u],null!=s.w&&(c=c||h<=1&&["w"]||h<s.w&&["ww",h]),(c=c||l<=1&&["M"]||l<s.M&&["MM",l]||d<=1&&["y"]||["yy",d])[2]=n,c[3]=+this>0,c[4]=f,m=nd.apply(null,c),_&&(m=f.pastFuture(+this,m)),f.postformat(m)},n_.toISOString=nm,n_.toString=nm,n_.toJSON=nm,n_.locale=tN,n_.localeData=tP,n_.toIsoString=D("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",nm),n_.lang=tW,C("X",0,0,"unix"),C("x",0,0,"valueOf"),el("x",es),el("X",/[+-]?\d+(\.\d{1,3})?/),em("X",function(e,t,n){n._d=new Date(1e3*parseFloat(e))}),em("x",function(e,t,n){n._d=new Date(ec(e))}),t.version="2.30.1",V=tr,t.fn=tj,t.min=function(){var e=[].slice.call(arguments,0);return tu("isBefore",e)},t.max=function(){var e=[].slice.call(arguments,0);return tu("isAfter",e)},t.now=function(){return Date.now?Date.now():+new Date},t.utc=d,t.unix=function(e){return tr(1e3*e)},t.months=function(e,t){return tq(e,t,"months")},t.isDate=u,t.locale=eJ,t.invalid=m,t.duration=tk,t.isMoment=k,t.weekdays=function(e,t,n){return tB(e,t,n,"weekdays")},t.parseZone=function(){return tr.apply(null,arguments).parseZone()},t.localeData=eX,t.isDuration=td,t.monthsShort=function(e,t){return tq(e,t,"monthsShort")},t.weekdaysMin=function(e,t,n){return tB(e,t,n,"weekdaysMin")},t.defineLocale=eQ,t.updateLocale=function(e,t){if(null!=t){var n,s,i=eZ;null!=ez[e]&&null!=ez[e].parentLocale?ez[e].set(b(ez[e]._config,t)):(null!=(s=eB(e))&&(i=s._config),t=b(i,t),null==s&&(t.abbr=e),(n=new T(t)).parentLocale=ez[e],ez[e]=n),eJ(e)}else null!=ez[e]&&(null!=ez[e].parentLocale?(ez[e]=ez[e].parentLocale,e===eJ()&&eJ(e)):null!=ez[e]&&delete ez[e]);return ez[e]},t.locales=function(){return A(ez)},t.weekdaysShort=function(e,t,n){return tB(e,t,n,"weekdaysShort")},t.normalizeUnits=L,t.relativeTimeRounding=function(e){return void 0===e?nl:"function"==typeof e&&(nl=e,!0)},t.relativeTimeThreshold=function(e,t){return void 0!==nh[e]&&(void 0===t?nh[e]:(nh[e]=t,"s"===e&&(nh.ss=t-1),!0))},t.calendarFormat=function(e,t){var n=e.diff(t,"days",!0);return n<-6?"sameElse":n<-1?"lastWeek":n<0?"lastDay":n<1?"sameDay":n<2?"nextDay":n<7?"nextWeek":"sameElse"},t.prototype=tj,t.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"},t},e.exports=s()}}]);
ui/litellm-dashboard/out/_next/static/chunks/250-d4389595d5e653e0.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[250],{19250:function(e,t,o){o.d(t,{$D:function(){return eP},$I:function(){return K},AZ:function(){return H},Au:function(){return em},BL:function(){return eM},Br:function(){return b},E9:function(){return eH},EB:function(){return to},EG:function(){return e$},EY:function(){return eQ},Eb:function(){return C},FC:function(){return el},Gh:function(){return eB},H1:function(){return G},H2:function(){return n},Hx:function(){return e_},I1:function(){return j},It:function(){return v},J$:function(){return er},JO:function(){return x},K8:function(){return d},K_:function(){return eK},LY:function(){return ez},Lp:function(){return eI},N3:function(){return eb},N8:function(){return et},NL:function(){return e2},NV:function(){return f},Nc:function(){return eO},O3:function(){return eL},OD:function(){return eE},OU:function(){return ep},Of:function(){return S},Og:function(){return y},Ov:function(){return E},PT:function(){return Y},Qg:function(){return eF},RQ:function(){return _},Rg:function(){return W},Sb:function(){return eR},So:function(){return eo},TF:function(){return tn},Tj:function(){return eW},UM:function(){return te},VA:function(){return A},Vt:function(){return eq},W_:function(){return V},X:function(){return en},XB:function(){return tc},XO:function(){return k},Xd:function(){return ej},Xm:function(){return F},YU:function(){return eZ},Yo:function(){return J},Z9:function(){return z},Zr:function(){return g},a6:function(){return O},aC:function(){return tr},ao:function(){return eY},b1:function(){return eh},cq:function(){return I},cu:function(){return eG},e2:function(){return ek},eH:function(){return $},eZ:function(){return ev},fE:function(){return tt},fP:function(){return ee},g:function(){return e0},gX:function(){return ex},h3:function(){return ei},hT:function(){return eN},hy:function(){return u},ix:function(){return q},j2:function(){return ec},jA:function(){return eX},jE:function(){return eV},kK:function(){return w},kn:function(){return X},lP:function(){return h},lU:function(){return e5},lg:function(){return eC},mC:function(){return e8},mR:function(){return ea},mY:function(){return e7},m_:function(){return L},mp:function(){return eD},n$:function(){return ef},n9:function(){return e9},nd:function(){return e4},o6:function(){return Q},oC:function(){return eS},ol:function(){return U},pf:function(){return eU},qI:function(){return m},qk:function(){return e1},qm:function(){return p},r1:function(){return ta},r6:function(){return B},rs:function(){return N},s0:function(){return M},sN:function(){return eA},t$:function(){return P},t0:function(){return eT},t3:function(){return e3},tB:function(){return e6},tN:function(){return ed},u5:function(){return es},v9:function(){return eg},vh:function(){return eJ},wX:function(){return T},wd:function(){return ew},xA:function(){return ey},xX:function(){return R},zg:function(){return eu}});var a=o(20347),r=o(41021);let n=null;console.log=function(){};let c=0,s=e=>new Promise(t=>setTimeout(t,e)),i=async e=>{let t=Date.now();t-c>6e4?(e.includes("Authentication Error - Expired Key")&&(r.ZP.info("UI Session Expired. Logging out."),c=t,await s(3e3),document.cookie="token=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;",window.location.href="/"),c=t):console.log("Error suppressed to prevent spam:",e)},l="Authorization";function d(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"Authorization";console.log("setGlobalLitellmHeaderName: ".concat(e)),l=e}let h=async()=>{let e=n?"".concat(n,"/openapi.json"):"/openapi.json",t=await fetch(e);return await t.json()},p=async e=>{try{let t=n?"".concat(n,"/get/litellm_model_cost_map"):"/get/litellm_model_cost_map",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}}),a=await o.json();return console.log("received litellm model cost data: ".concat(a)),a}catch(e){throw console.error("Failed to get model cost map:",e),e}},w=async(e,t)=>{try{let o=n?"".concat(n,"/model/new"):"/model/new",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text()||"Network response was not ok";throw r.ZP.error(e),Error(e)}let c=await a.json();return console.log("API Response:",c),r.ZP.destroy(),r.ZP.success("Model ".concat(t.model_name," created successfully"),2),c}catch(e){throw console.error("Failed to create key:",e),e}},u=async e=>{try{let t=n?"".concat(n,"/model/settings"):"/model/settings",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}return await o.json()}catch(e){console.error("Failed to get model settings:",e)}},y=async(e,t)=>{console.log("model_id in model delete call: ".concat(t));try{let o=n?"".concat(n,"/model/delete"):"/model/delete",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({id:t})});if(!a.ok){let e=await a.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},f=async(e,t)=>{if(console.log("budget_id in budget delete call: ".concat(t)),null!=e)try{let o=n?"".concat(n,"/budget/delete"):"/budget/delete",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({id:t})});if(!a.ok){let e=await a.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},g=async(e,t)=>{try{console.log("Form Values in budgetCreateCall:",t),console.log("Form Values after check:",t);let o=n?"".concat(n,"/budget/new"):"/budget/new",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},m=async(e,t)=>{try{console.log("Form Values in budgetUpdateCall:",t),console.log("Form Values after check:",t);let o=n?"".concat(n,"/budget/update"):"/budget/update",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},k=async(e,t)=>{try{let o=n?"".concat(n,"/invitation/new"):"/invitation/new",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({user_id:t})});if(!a.ok){let e=await a.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},_=async e=>{try{let t=n?"".concat(n,"/alerting/settings"):"/alerting/settings",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},T=async(e,t,o)=>{try{if(console.log("Form Values in keyCreateCall:",o),o.description&&(o.metadata||(o.metadata={}),o.metadata.description=o.description,delete o.description,o.metadata=JSON.stringify(o.metadata)),o.metadata){console.log("formValues.metadata:",o.metadata);try{o.metadata=JSON.parse(o.metadata)}catch(e){throw Error("Failed to parse metadata: "+e)}}console.log("Form Values after check:",o);let a=n?"".concat(n,"/key/generate"):"/key/generate",r=await fetch(a,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({user_id:t,...o})});if(!r.ok){let e=await r.text();throw i(e),console.error("Error response from the server:",e),Error(e)}let c=await r.json();return console.log("API Response:",c),c}catch(e){throw console.error("Failed to create key:",e),e}},E=async(e,t,o)=>{try{if(console.log("Form Values in keyCreateCall:",o),o.description&&(o.metadata||(o.metadata={}),o.metadata.description=o.description,delete o.description,o.metadata=JSON.stringify(o.metadata)),o.auto_create_key=!1,o.metadata){console.log("formValues.metadata:",o.metadata);try{o.metadata=JSON.parse(o.metadata)}catch(e){throw Error("Failed to parse metadata: "+e)}}console.log("Form Values after check:",o);let a=n?"".concat(n,"/user/new"):"/user/new",r=await fetch(a,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({user_id:t,...o})});if(!r.ok){let e=await r.text();throw i(e),console.error("Error response from the server:",e),Error(e)}let c=await r.json();return console.log("API Response:",c),c}catch(e){throw console.error("Failed to create key:",e),e}},j=async(e,t)=>{try{let o=n?"".concat(n,"/key/delete"):"/key/delete";console.log("in keyDeleteCall:",t);let a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({keys:[t]})});if(!a.ok){let e=await a.text();throw i(e),Error("Network response was not ok")}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to create key:",e),e}},C=async(e,t)=>{try{let o=n?"".concat(n,"/user/delete"):"/user/delete";console.log("in userDeleteCall:",t);let a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({user_ids:t})});if(!a.ok){let e=await a.text();throw i(e),Error("Network response was not ok")}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to delete user(s):",e),e}},N=async(e,t)=>{try{let o=n?"".concat(n,"/team/delete"):"/team/delete";console.log("in teamDeleteCall:",t);let a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({team_ids:[t]})});if(!a.ok){let e=await a.text();throw i(e),Error("Network response was not ok")}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to delete key:",e),e}},S=async function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null,c=arguments.length>5&&void 0!==arguments[5]?arguments[5]:null,s=arguments.length>6&&void 0!==arguments[6]?arguments[6]:null,d=arguments.length>7&&void 0!==arguments[7]?arguments[7]:null,h=arguments.length>8&&void 0!==arguments[8]?arguments[8]:null,p=arguments.length>9&&void 0!==arguments[9]?arguments[9]:null;try{let w=n?"".concat(n,"/user/list"):"/user/list";console.log("in userListCall");let u=new URLSearchParams;if(t&&t.length>0){let e=t.join(",");u.append("user_ids",e)}o&&u.append("page",o.toString()),a&&u.append("page_size",a.toString()),r&&u.append("user_email",r),c&&u.append("role",c),s&&u.append("team",s),d&&u.append("sso_user_ids",d),h&&u.append("sort_by",h),p&&u.append("sort_order",p);let y=u.toString();y&&(w+="?".concat(y));let f=await fetch(w,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!f.ok){let e=await f.text();throw i(e),Error("Network response was not ok")}let g=await f.json();return console.log("/user/list API Response:",g),g}catch(e){throw console.error("Failed to create key:",e),e}},b=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]&&arguments[3],r=arguments.length>4?arguments[4]:void 0,c=arguments.length>5?arguments[5]:void 0,s=arguments.length>6&&void 0!==arguments[6]&&arguments[6];console.log("userInfoCall: ".concat(t,", ").concat(o,", ").concat(a,", ").concat(r,", ").concat(c,", ").concat(s));try{let d;if(a){d=n?"".concat(n,"/user/list"):"/user/list";let e=new URLSearchParams;null!=r&&e.append("page",r.toString()),null!=c&&e.append("page_size",c.toString()),d+="?".concat(e.toString())}else d=n?"".concat(n,"/user/info"):"/user/info",("Admin"!==o&&"Admin Viewer"!==o||s)&&t&&(d+="?user_id=".concat(t));console.log("Requesting user data from:",d);let h=await fetch(d,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!h.ok){let e=await h.text();throw i(e),Error("Network response was not ok")}let p=await h.json();return console.log("API Response:",p),p}catch(e){throw console.error("Failed to fetch user data:",e),e}},F=async(e,t)=>{try{let o=n?"".concat(n,"/team/info"):"/team/info";t&&(o="".concat(o,"?team_id=").concat(t)),console.log("in teamInfoCall");let a=await fetch(o,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw i(e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},x=async function(e,t){let o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;arguments.length>5&&void 0!==arguments[5]&&arguments[5],arguments.length>6&&void 0!==arguments[6]&&arguments[6],arguments.length>7&&void 0!==arguments[7]&&arguments[7],arguments.length>8&&void 0!==arguments[8]&&arguments[8];try{let c=n?"".concat(n,"/v2/team/list"):"/v2/team/list";console.log("in teamInfoCall");let s=new URLSearchParams;o&&s.append("user_id",o.toString()),t&&s.append("organization_id",t.toString()),a&&s.append("team_id",a.toString()),r&&s.append("team_alias",r.toString());let d=s.toString();d&&(c+="?".concat(d));let h=await fetch(c,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!h.ok){let e=await h.text();throw i(e),Error("Network response was not ok")}let p=await h.json();return console.log("/v2/team/list API Response:",p),p}catch(e){throw console.error("Failed to create key:",e),e}},v=async function(e,t){let o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;try{let c=n?"".concat(n,"/team/list"):"/team/list";console.log("in teamInfoCall");let s=new URLSearchParams;o&&s.append("user_id",o.toString()),t&&s.append("organization_id",t.toString()),a&&s.append("team_id",a.toString()),r&&s.append("team_alias",r.toString());let d=s.toString();d&&(c+="?".concat(d));let h=await fetch(c,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!h.ok){let e=await h.text();throw i(e),Error("Network response was not ok")}let p=await h.json();return console.log("/team/list API Response:",p),p}catch(e){throw console.error("Failed to create key:",e),e}},O=async e=>{try{let t=n?"".concat(n,"/team/available"):"/team/available";console.log("in availableTeamListCall");let o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}let a=await o.json();return console.log("/team/available_teams API Response:",a),a}catch(e){throw e}},B=async e=>{try{let t=n?"".concat(n,"/organization/list"):"/organization/list",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to create key:",e),e}},P=async(e,t)=>{try{let o=n?"".concat(n,"/organization/info"):"/organization/info";t&&(o="".concat(o,"?organization_id=").concat(t)),console.log("in teamInfoCall");let a=await fetch(o,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw i(e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},G=async(e,t)=>{try{if(console.log("Form Values in organizationCreateCall:",t),t.metadata){console.log("formValues.metadata:",t.metadata);try{t.metadata=JSON.parse(t.metadata)}catch(e){throw console.error("Failed to parse metadata:",e),Error("Failed to parse metadata: "+e)}}let o=n?"".concat(n,"/organization/new"):"/organization/new",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},A=async(e,t)=>{try{console.log("Form Values in organizationUpdateCall:",t);let o=n?"".concat(n,"/organization/update"):"/organization/update",a=await fetch(o,{method:"PATCH",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("Update Team Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},I=async(e,t)=>{try{let o=n?"".concat(n,"/organization/delete"):"/organization/delete",a=await fetch(o,{method:"DELETE",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({organization_ids:[t]})});if(!a.ok){let e=await a.text();throw i(e),Error("Error deleting organization: ".concat(e))}return await a.json()}catch(e){throw console.error("Failed to delete organization:",e),e}},J=async(e,t)=>{try{let o=n?"".concat(n,"/utils/transform_request"):"/utils/transform_request",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(t)});if(!a.ok){let e=await a.text();throw i(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to create key:",e),e}},R=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1;try{let r=n?"".concat(n,"/user/daily/activity"):"/user/daily/activity",c=new URLSearchParams;c.append("start_date",t.toISOString()),c.append("end_date",o.toISOString()),c.append("page_size","1000"),c.append("page",a.toString());let s=c.toString();s&&(r+="?".concat(s));let d=await fetch(r,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!d.ok){let e=await d.text();throw i(e),Error("Network response was not ok")}return await d.json()}catch(e){throw console.error("Failed to create key:",e),e}},z=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;try{let c=n?"".concat(n,"/tag/daily/activity"):"/tag/daily/activity",s=new URLSearchParams;s.append("start_date",t.toISOString()),s.append("end_date",o.toISOString()),s.append("page_size","1000"),s.append("page",a.toString()),r&&s.append("tags",r.join(","));let d=s.toString();d&&(c+="?".concat(d));let h=await fetch(c,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!h.ok){let e=await h.text();throw i(e),Error("Network response was not ok")}return await h.json()}catch(e){throw console.error("Failed to create key:",e),e}},U=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;try{let c=n?"".concat(n,"/team/daily/activity"):"/team/daily/activity",s=new URLSearchParams;s.append("start_date",t.toISOString()),s.append("end_date",o.toISOString()),s.append("page_size","1000"),s.append("page",a.toString()),r&&s.append("team_ids",r.join(",")),s.append("exclude_team_ids","litellm-dashboard");let d=s.toString();d&&(c+="?".concat(d));let h=await fetch(c,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!h.ok){let e=await h.text();throw i(e),Error("Network response was not ok")}return await h.json()}catch(e){throw console.error("Failed to create key:",e),e}},V=async e=>{try{let t=n?"".concat(n,"/onboarding/get_token"):"/onboarding/get_token";t+="?invite_link=".concat(e);let o=await fetch(t,{method:"GET",headers:{"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to create key:",e),e}},L=async(e,t,o,a)=>{let r=n?"".concat(n,"/onboarding/claim_token"):"/onboarding/claim_token";try{let n=await fetch(r,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({invitation_link:t,user_id:o,password:a})});if(!n.ok){let e=await n.text();throw i(e),Error("Network response was not ok")}let c=await n.json();return console.log(c),c}catch(e){throw console.error("Failed to delete key:",e),e}},M=async(e,t,o)=>{try{let a=n?"".concat(n,"/key/").concat(t,"/regenerate"):"/key/".concat(t,"/regenerate"),r=await fetch(a,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(o)});if(!r.ok){let e=await r.text();throw i(e),Error("Network response was not ok")}let c=await r.json();return console.log("Regenerate key Response:",c),c}catch(e){throw console.error("Failed to regenerate key:",e),e}},Z=!1,D=null,H=async(e,t,o)=>{try{console.log("modelInfoCall:",e,t,o);let c=n?"".concat(n,"/v2/model/info"):"/v2/model/info";a.ZL.includes(o)||(c+="?user_models_only=true");let s=await fetch(c,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!s.ok){let e=await s.text();throw e+="error shown=".concat(Z),Z||(e.includes("No model list passed")&&(e="No Models Exist. Click Add Model to get started."),r.ZP.info(e,10),Z=!0,D&&clearTimeout(D),D=setTimeout(()=>{Z=!1},1e4)),Error("Network response was not ok")}let i=await s.json();return console.log("modelInfoCall:",i),i}catch(e){throw console.error("Failed to create key:",e),e}},q=async(e,t)=>{try{let o=n?"".concat(n,"/v1/model/info"):"/v1/model/info";o+="?litellm_model_id=".concat(t);let a=await fetch(o,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok)throw await a.text(),Error("Network response was not ok");let r=await a.json();return console.log("modelInfoV1Call:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},X=async e=>{try{let t=n?"".concat(n,"/model_group/info"):"/model_group/info",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok)throw await o.text(),Error("Network response was not ok");let a=await o.json();return console.log("modelHubCall:",a),a}catch(e){throw console.error("Failed to create key:",e),e}},Y=async e=>{try{let t=n?"".concat(n,"/get/allowed_ips"):"/get/allowed_ips",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw Error("Network response was not ok: ".concat(e))}let a=await o.json();return console.log("getAllowedIPs:",a),a.data}catch(e){throw console.error("Failed to get allowed IPs:",e),e}},$=async(e,t)=>{try{let o=n?"".concat(n,"/add/allowed_ip"):"/add/allowed_ip",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({ip:t})});if(!a.ok){let e=await a.text();throw Error("Network response was not ok: ".concat(e))}let r=await a.json();return console.log("addAllowedIP:",r),r}catch(e){throw console.error("Failed to add allowed IP:",e),e}},K=async(e,t)=>{try{let o=n?"".concat(n,"/delete/allowed_ip"):"/delete/allowed_ip",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({ip:t})});if(!a.ok){let e=await a.text();throw Error("Network response was not ok: ".concat(e))}let r=await a.json();return console.log("deleteAllowedIP:",r),r}catch(e){throw console.error("Failed to delete allowed IP:",e),e}},Q=async(e,t,o,a,r,c,s,d)=>{try{let t=n?"".concat(n,"/model/metrics"):"/model/metrics";a&&(t="".concat(t,"?_selected_model_group=").concat(a,"&startTime=").concat(r,"&endTime=").concat(c,"&api_key=").concat(s,"&customer=").concat(d));let o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to create key:",e),e}},W=async(e,t,o,a)=>{try{let r=n?"".concat(n,"/model/streaming_metrics"):"/model/streaming_metrics";t&&(r="".concat(r,"?_selected_model_group=").concat(t,"&startTime=").concat(o,"&endTime=").concat(a));let c=await fetch(r,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!c.ok){let e=await c.text();throw i(e),Error("Network response was not ok")}return await c.json()}catch(e){throw console.error("Failed to create key:",e),e}},ee=async(e,t,o,a,r,c,s,d)=>{try{let t=n?"".concat(n,"/model/metrics/slow_responses"):"/model/metrics/slow_responses";a&&(t="".concat(t,"?_selected_model_group=").concat(a,"&startTime=").concat(r,"&endTime=").concat(c,"&api_key=").concat(s,"&customer=").concat(d));let o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to create key:",e),e}},et=async(e,t,o,a,r,c,s,d)=>{try{let t=n?"".concat(n,"/model/metrics/exceptions"):"/model/metrics/exceptions";a&&(t="".concat(t,"?_selected_model_group=").concat(a,"&startTime=").concat(r,"&endTime=").concat(c,"&api_key=").concat(s,"&customer=").concat(d));let o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to create key:",e),e}},eo=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]&&arguments[3],r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;console.log("in /models calls, globalLitellmHeaderName",l);try{let t=n?"".concat(n,"/models"):"/models",o=new URLSearchParams;!0===a&&o.append("return_wildcard_routes","True"),r&&o.append("team_id",r.toString()),o.toString()&&(t+="?".concat(o.toString()));let c=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!c.ok){let e=await c.text();throw i(e),Error("Network response was not ok")}return await c.json()}catch(e){throw console.error("Failed to create key:",e),e}},ea=async e=>{try{let t=n?"".concat(n,"/global/spend/teams"):"/global/spend/teams";console.log("in teamSpendLogsCall:",t);let o=await fetch("".concat(t),{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},er=async(e,t,o,a)=>{try{let r=n?"".concat(n,"/global/spend/tags"):"/global/spend/tags";t&&o&&(r="".concat(r,"?start_date=").concat(t,"&end_date=").concat(o)),a&&(r+="".concat(r,"&tags=").concat(a.join(","))),console.log("in tagsSpendLogsCall:",r);let c=await fetch("".concat(r),{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!c.ok)throw await c.text(),Error("Network response was not ok");let s=await c.json();return console.log(s),s}catch(e){throw console.error("Failed to create key:",e),e}},en=async e=>{try{let t=n?"".concat(n,"/global/spend/all_tag_names"):"/global/spend/all_tag_names";console.log("in global/spend/all_tag_names call",t);let o=await fetch("".concat(t),{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok)throw await o.text(),Error("Network response was not ok");let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},ec=async e=>{try{let t=n?"".concat(n,"/global/all_end_users"):"/global/all_end_users";console.log("in global/all_end_users call",t);let o=await fetch("".concat(t),{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok)throw await o.text(),Error("Network response was not ok");let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},es=async(e,t)=>{try{let o=n?"".concat(n,"/user/filter/ui"):"/user/filter/ui";t.get("user_email")&&(o+="?user_email=".concat(t.get("user_email"))),t.get("user_id")&&(o+="?user_id=".concat(t.get("user_id")));let a=await fetch(o,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw i(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to create key:",e),e}},ei=async(e,t,o,a,r,c,s,d,h)=>{try{let p=n?"".concat(n,"/spend/logs/ui"):"/spend/logs/ui",w=new URLSearchParams;t&&w.append("api_key",t),o&&w.append("team_id",o),a&&w.append("request_id",a),r&&w.append("start_date",r),c&&w.append("end_date",c),s&&w.append("page",s.toString()),d&&w.append("page_size",d.toString()),h&&w.append("user_id",h);let u=w.toString();u&&(p+="?".concat(u));let y=await fetch(p,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!y.ok){let e=await y.text();throw i(e),Error("Network response was not ok")}let f=await y.json();return console.log("Spend Logs Response:",f),f}catch(e){throw console.error("Failed to fetch spend logs:",e),e}},el=async e=>{try{let t=n?"".concat(n,"/global/spend/logs"):"/global/spend/logs",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},ed=async e=>{try{let t=n?"".concat(n,"/global/spend/keys?limit=5"):"/global/spend/keys?limit=5",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},eh=async(e,t,o,a)=>{try{let r=n?"".concat(n,"/global/spend/end_users"):"/global/spend/end_users",c="";c=t?JSON.stringify({api_key:t,startTime:o,endTime:a}):JSON.stringify({startTime:o,endTime:a});let s={method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:c},d=await fetch(r,s);if(!d.ok){let e=await d.text();throw i(e),Error("Network response was not ok")}let h=await d.json();return console.log(h),h}catch(e){throw console.error("Failed to create key:",e),e}},ep=async(e,t,o,a)=>{try{let r=n?"".concat(n,"/global/spend/provider"):"/global/spend/provider";o&&a&&(r+="?start_date=".concat(o,"&end_date=").concat(a)),t&&(r+="&api_key=".concat(t));let c={method:"GET",headers:{[l]:"Bearer ".concat(e)}},s=await fetch(r,c);if(!s.ok){let e=await s.text();throw i(e),Error("Network response was not ok")}let d=await s.json();return console.log(d),d}catch(e){throw console.error("Failed to fetch spend data:",e),e}},ew=async(e,t,o)=>{try{let a=n?"".concat(n,"/global/activity"):"/global/activity";t&&o&&(a+="?start_date=".concat(t,"&end_date=").concat(o));let r={method:"GET",headers:{[l]:"Bearer ".concat(e)}},c=await fetch(a,r);if(!c.ok)throw await c.text(),Error("Network response was not ok");let s=await c.json();return console.log(s),s}catch(e){throw console.error("Failed to fetch spend data:",e),e}},eu=async(e,t,o)=>{try{let a=n?"".concat(n,"/global/activity/cache_hits"):"/global/activity/cache_hits";t&&o&&(a+="?start_date=".concat(t,"&end_date=").concat(o));let r={method:"GET",headers:{[l]:"Bearer ".concat(e)}},c=await fetch(a,r);if(!c.ok)throw await c.text(),Error("Network response was not ok");let s=await c.json();return console.log(s),s}catch(e){throw console.error("Failed to fetch spend data:",e),e}},ey=async(e,t,o)=>{try{let a=n?"".concat(n,"/global/activity/model"):"/global/activity/model";t&&o&&(a+="?start_date=".concat(t,"&end_date=").concat(o));let r={method:"GET",headers:{[l]:"Bearer ".concat(e)}},c=await fetch(a,r);if(!c.ok)throw await c.text(),Error("Network response was not ok");let s=await c.json();return console.log(s),s}catch(e){throw console.error("Failed to fetch spend data:",e),e}},ef=async(e,t,o,a)=>{try{let r=n?"".concat(n,"/global/activity/exceptions"):"/global/activity/exceptions";t&&o&&(r+="?start_date=".concat(t,"&end_date=").concat(o)),a&&(r+="&model_group=".concat(a));let c={method:"GET",headers:{[l]:"Bearer ".concat(e)}},s=await fetch(r,c);if(!s.ok)throw await s.text(),Error("Network response was not ok");let i=await s.json();return console.log(i),i}catch(e){throw console.error("Failed to fetch spend data:",e),e}},eg=async(e,t,o,a)=>{try{let r=n?"".concat(n,"/global/activity/exceptions/deployment"):"/global/activity/exceptions/deployment";t&&o&&(r+="?start_date=".concat(t,"&end_date=").concat(o)),a&&(r+="&model_group=".concat(a));let c={method:"GET",headers:{[l]:"Bearer ".concat(e)}},s=await fetch(r,c);if(!s.ok)throw await s.text(),Error("Network response was not ok");let i=await s.json();return console.log(i),i}catch(e){throw console.error("Failed to fetch spend data:",e),e}},em=async e=>{try{let t=n?"".concat(n,"/global/spend/models?limit=5"):"/global/spend/models?limit=5",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},ek=async(e,t)=>{try{let o=n?"".concat(n,"/v2/key/info"):"/v2/key/info",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({keys:t})});if(!a.ok){let e=await a.text();if(e.includes("Invalid proxy server token passed"))throw Error("Invalid proxy server token passed");throw i(e),Error("Network response was not ok")}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to create key:",e),e}},e_=async(e,t,o)=>{try{console.log("Sending model connection test request:",JSON.stringify(t));let r=n?"".concat(n,"/health/test_connection"):"/health/test_connection",c=await fetch(r,{method:"POST",headers:{"Content-Type":"application/json",[l]:"Bearer ".concat(e)},body:JSON.stringify({litellm_params:t,mode:o})}),s=c.headers.get("content-type");if(!s||!s.includes("application/json")){let e=await c.text();throw console.error("Received non-JSON response:",e),Error("Received non-JSON response (".concat(c.status,": ").concat(c.statusText,"). Check network tab for details."))}let i=await c.json();if(!c.ok||"error"===i.status){if("error"===i.status);else{var a;return{status:"error",message:(null===(a=i.error)||void 0===a?void 0:a.message)||"Connection test failed: ".concat(c.status," ").concat(c.statusText)}}}return i}catch(e){throw console.error("Model connection test error:",e),e}},eT=async(e,t)=>{try{console.log("entering keyInfoV1Call");let o=n?"".concat(n,"/key/info"):"/key/info";o="".concat(o,"?key=").concat(t);let a=await fetch(o,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(console.log("response",a),!a.ok){let e=await a.text();i(e),r.ZP.error("Failed to fetch key info - "+e)}let c=await a.json();return console.log("data",c),c}catch(e){throw console.error("Failed to fetch key info:",e),e}},eE=async(e,t,o,a,r,c,s,d)=>{try{let h=n?"".concat(n,"/key/list"):"/key/list";console.log("in keyListCall");let p=new URLSearchParams;o&&p.append("team_id",o.toString()),t&&p.append("organization_id",t.toString()),a&&p.append("key_alias",a),c&&p.append("key_hash",c),r&&p.append("user_id",r.toString()),s&&p.append("page",s.toString()),d&&p.append("size",d.toString()),p.append("return_full_object","true"),p.append("include_team_keys","true");let w=p.toString();w&&(h+="?".concat(w));let u=await fetch(h,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!u.ok){let e=await u.text();throw i(e),Error("Network response was not ok")}let y=await u.json();return console.log("/team/list API Response:",y),y}catch(e){throw console.error("Failed to create key:",e),e}},ej=async(e,t)=>{try{let o=n?"".concat(n,"/user/get_users?role=").concat(t):"/user/get_users?role=".concat(t);console.log("in userGetAllUsersCall:",o);let a=await fetch(o,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw i(e),Error("Network response was not ok")}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to get requested models:",e),e}},eC=async e=>{try{let t=n?"".concat(n,"/user/available_roles"):"/user/available_roles",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok)throw await o.text(),Error("Network response was not ok");let a=await o.json();return console.log("response from user/available_role",a),a}catch(e){throw e}},eN=async(e,t)=>{try{if(console.log("Form Values in teamCreateCall:",t),t.metadata){console.log("formValues.metadata:",t.metadata);try{t.metadata=JSON.parse(t.metadata)}catch(e){throw Error("Failed to parse metadata: "+e)}}let o=n?"".concat(n,"/team/new"):"/team/new",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},eS=async(e,t)=>{try{if(console.log("Form Values in credentialCreateCall:",t),t.metadata){console.log("formValues.metadata:",t.metadata);try{t.metadata=JSON.parse(t.metadata)}catch(e){throw Error("Failed to parse metadata: "+e)}}let o=n?"".concat(n,"/credentials"):"/credentials",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},eb=async e=>{try{let t=n?"".concat(n,"/credentials"):"/credentials";console.log("in credentialListCall");let o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}let a=await o.json();return console.log("/credentials API Response:",a),a}catch(e){throw console.error("Failed to create key:",e),e}},eF=async(e,t,o)=>{try{let a=n?"".concat(n,"/credentials"):"/credentials";t?a+="/by_name/".concat(t):o&&(a+="/by_model/".concat(o)),console.log("in credentialListCall");let r=await fetch(a,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!r.ok){let e=await r.text();throw i(e),Error("Network response was not ok")}let c=await r.json();return console.log("/credentials API Response:",c),c}catch(e){throw console.error("Failed to create key:",e),e}},ex=async(e,t)=>{try{let o=n?"".concat(n,"/credentials/").concat(t):"/credentials/".concat(t);console.log("in credentialDeleteCall:",t);let a=await fetch(o,{method:"DELETE",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw i(e),Error("Network response was not ok")}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to delete key:",e),e}},ev=async(e,t,o)=>{try{if(console.log("Form Values in credentialUpdateCall:",o),o.metadata){console.log("formValues.metadata:",o.metadata);try{o.metadata=JSON.parse(o.metadata)}catch(e){throw Error("Failed to parse metadata: "+e)}}let a=n?"".concat(n,"/credentials/").concat(t):"/credentials/".concat(t),r=await fetch(a,{method:"PATCH",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...o})});if(!r.ok){let e=await r.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let c=await r.json();return console.log("API Response:",c),c}catch(e){throw console.error("Failed to create key:",e),e}},eO=async(e,t)=>{try{if(console.log("Form Values in keyUpdateCall:",t),t.model_tpm_limit){console.log("formValues.model_tpm_limit:",t.model_tpm_limit);try{t.model_tpm_limit=JSON.parse(t.model_tpm_limit)}catch(e){throw Error("Failed to parse model_tpm_limit: "+e)}}if(t.model_rpm_limit){console.log("formValues.model_rpm_limit:",t.model_rpm_limit);try{t.model_rpm_limit=JSON.parse(t.model_rpm_limit)}catch(e){throw Error("Failed to parse model_rpm_limit: "+e)}}let o=n?"".concat(n,"/key/update"):"/key/update",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("Update key Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},eB=async(e,t)=>{try{console.log("Form Values in teamUpateCall:",t);let o=n?"".concat(n,"/team/update"):"/team/update",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("Update Team Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},eP=async(e,t,o)=>{try{console.log("Form Values in modelUpateCall:",t);let a=n?"".concat(n,"/model/").concat(o,"/update"):"/model/".concat(o,"/update"),r=await fetch(a,{method:"PATCH",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!r.ok){let e=await r.text();throw i(e),console.error("Error update from the server:",e),Error("Network response was not ok")}let c=await r.json();return console.log("Update model Response:",c),c}catch(e){throw console.error("Failed to update model:",e),e}},eG=async(e,t,o)=>{try{console.log("Form Values in teamMemberAddCall:",o);let a=n?"".concat(n,"/team/member_add"):"/team/member_add",r=await fetch(a,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({team_id:t,member:o})});if(!r.ok){let e=await r.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let c=await r.json();return console.log("API Response:",c),c}catch(e){throw console.error("Failed to create key:",e),e}},eA=async(e,t,o)=>{try{console.log("Form Values in teamMemberAddCall:",o);let a=n?"".concat(n,"/team/member_update"):"/team/member_update",r=await fetch(a,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({team_id:t,role:o.role,user_id:o.user_id})});if(!r.ok){let e=await r.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let c=await r.json();return console.log("API Response:",c),c}catch(e){throw console.error("Failed to create key:",e),e}},eI=async(e,t,o)=>{try{console.log("Form Values in teamMemberAddCall:",o);let a=n?"".concat(n,"/team/member_delete"):"/team/member_delete",r=await fetch(a,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({team_id:t,...void 0!==o.user_email&&{user_email:o.user_email},...void 0!==o.user_id&&{user_id:o.user_id}})});if(!r.ok){let e=await r.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let c=await r.json();return console.log("API Response:",c),c}catch(e){throw console.error("Failed to create key:",e),e}},eJ=async(e,t,o)=>{try{console.log("Form Values in teamMemberAddCall:",o);let a=n?"".concat(n,"/organization/member_add"):"/organization/member_add",r=await fetch(a,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({organization_id:t,member:o})});if(!r.ok){let e=await r.text();throw i(e),console.error("Error response from the server:",e),Error(e)}let c=await r.json();return console.log("API Response:",c),c}catch(e){throw console.error("Failed to create organization member:",e),e}},eR=async(e,t,o)=>{try{console.log("Form Values in organizationMemberDeleteCall:",o);let a=n?"".concat(n,"/organization/member_delete"):"/organization/member_delete",r=await fetch(a,{method:"DELETE",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({organization_id:t,user_id:o})});if(!r.ok){let e=await r.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let c=await r.json();return console.log("API Response:",c),c}catch(e){throw console.error("Failed to delete organization member:",e),e}},ez=async(e,t,o)=>{try{console.log("Form Values in organizationMemberUpdateCall:",o);let a=n?"".concat(n,"/organization/member_update"):"/organization/member_update",r=await fetch(a,{method:"PATCH",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({organization_id:t,...o})});if(!r.ok){let e=await r.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let c=await r.json();return console.log("API Response:",c),c}catch(e){throw console.error("Failed to update organization member:",e),e}},eU=async(e,t,o)=>{try{console.log("Form Values in userUpdateUserCall:",t);let a=n?"".concat(n,"/user/update"):"/user/update",r={...t};null!==o&&(r.user_role=o),r=JSON.stringify(r);let c=await fetch(a,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:r});if(!c.ok){let e=await c.text();throw i(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let s=await c.json();return console.log("API Response:",s),s}catch(e){throw console.error("Failed to create key:",e),e}},eV=async(e,t)=>{try{let o=n?"".concat(n,"/health/services?service=").concat(t):"/health/services?service=".concat(t);console.log("Checking Slack Budget Alerts service health");let a=await fetch(o,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw i(e),Error(e)}let c=await a.json();return r.ZP.success("Test request to ".concat(t," made - check logs/alerts on ").concat(t," to verify")),c}catch(e){throw console.error("Failed to perform health check:",e),e}},eL=async e=>{try{let t=n?"".concat(n,"/budget/list"):"/budget/list",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},eM=async(e,t,o)=>{try{let t=n?"".concat(n,"/get/config/callbacks"):"/get/config/callbacks",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},eZ=async e=>{try{let t=n?"".concat(n,"/config/list?config_type=general_settings"):"/config/list?config_type=general_settings",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},eD=async e=>{try{let t=n?"".concat(n,"/config/pass_through_endpoint"):"/config/pass_through_endpoint",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},eH=async(e,t)=>{try{let o=n?"".concat(n,"/config/field/info?field_name=").concat(t):"/config/field/info?field_name=".concat(t),a=await fetch(o,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok)throw await a.text(),Error("Network response was not ok");return await a.json()}catch(e){throw console.error("Failed to set callbacks:",e),e}},eq=async(e,t)=>{try{let o=n?"".concat(n,"/config/pass_through_endpoint"):"/config/pass_through_endpoint",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw i(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to set callbacks:",e),e}},eX=async(e,t,o)=>{try{let a=n?"".concat(n,"/config/field/update"):"/config/field/update",c=await fetch(a,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({field_name:t,field_value:o,config_type:"general_settings"})});if(!c.ok){let e=await c.text();throw i(e),Error("Network response was not ok")}let s=await c.json();return r.ZP.success("Successfully updated value!"),s}catch(e){throw console.error("Failed to set callbacks:",e),e}},eY=async(e,t)=>{try{let o=n?"".concat(n,"/config/field/delete"):"/config/field/delete",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({field_name:t,config_type:"general_settings"})});if(!a.ok){let e=await a.text();throw i(e),Error("Network response was not ok")}let c=await a.json();return r.ZP.success("Field reset on proxy"),c}catch(e){throw console.error("Failed to get callbacks:",e),e}},e$=async(e,t)=>{try{let o=n?"".concat(n,"/config/pass_through_endpoint?endpoint_id=").concat(t):"/config/pass_through_endpoint".concat(t),a=await fetch(o,{method:"DELETE",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw i(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},eK=async(e,t)=>{try{let o=n?"".concat(n,"/config/update"):"/config/update",a=await fetch(o,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw i(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to set callbacks:",e),e}},eQ=async e=>{try{let t=n?"".concat(n,"/health"):"/health",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to call /health:",e),e}},eW=async e=>{try{let t=n?"".concat(n,"/cache/ping"):"/cache/ping",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error(e)}return await o.json()}catch(e){throw console.error("Failed to call /cache/ping:",e),e}},e0=async e=>{try{let t=n?"".concat(n,"/sso/get/ui_settings"):"/sso/get/ui_settings",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok)throw await o.text(),Error("Network response was not ok");return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},e3=async e=>{try{let t=n?"".concat(n,"/guardrails/list"):"/guardrails/list",o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}let a=await o.json();return console.log("Guardrails list response:",a),a}catch(e){throw console.error("Failed to fetch guardrails list:",e),e}},e1=async(e,t,o)=>{try{let a=n?"".concat(n,"/spend/logs/ui/").concat(t,"?start_date=").concat(encodeURIComponent(o)):"/spend/logs/ui/".concat(t,"?start_date=").concat(encodeURIComponent(o));console.log("Fetching log details from:",a);let r=await fetch(a,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!r.ok){let e=await r.text();throw i(e),Error("Network response was not ok")}let c=await r.json();return console.log("Fetched log details:",c),c}catch(e){throw console.error("Failed to fetch log details:",e),e}},e2=async e=>{try{let t=n?"".concat(n,"/get/internal_user_settings"):"/get/internal_user_settings";console.log("Fetching SSO settings from:",t);let o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}let a=await o.json();return console.log("Fetched SSO settings:",a),a}catch(e){throw console.error("Failed to fetch SSO settings:",e),e}},e4=async(e,t)=>{try{let o=n?"".concat(n,"/update/internal_user_settings"):"/update/internal_user_settings";console.log("Updating internal user settings:",t);let a=await fetch(o,{method:"PATCH",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(t)});if(!a.ok){let e=await a.text();throw i(e),Error("Network response was not ok")}let c=await a.json();return console.log("Updated internal user settings:",c),r.ZP.success("Internal user settings updated successfully"),c}catch(e){throw console.error("Failed to update internal user settings:",e),e}},e5=async e=>{try{let t=n?"".concat(n,"/mcp/tools/list"):"/mcp/tools/list";console.log("Fetching MCP tools from:",t);let o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}let a=await o.json();return console.log("Fetched MCP tools:",a),a}catch(e){throw console.error("Failed to fetch MCP tools:",e),e}},e6=async(e,t,o)=>{try{let a=n?"".concat(n,"/mcp/tools/call"):"/mcp/tools/call";console.log("Calling MCP tool:",t,"with arguments:",o);let r=await fetch(a,{method:"POST",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({name:t,arguments:o})});if(!r.ok){let e=await r.text();throw i(e),Error("Network response was not ok")}let c=await r.json();return console.log("MCP tool call response:",c),c}catch(e){throw console.error("Failed to call MCP tool:",e),e}},e7=async(e,t)=>{try{let o=n?"".concat(n,"/tag/new"):"/tag/new",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify(t)});if(!a.ok){let e=await a.text();await i(e);return}return await a.json()}catch(e){throw console.error("Error creating tag:",e),e}},e9=async(e,t)=>{try{let o=n?"".concat(n,"/tag/update"):"/tag/update",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify(t)});if(!a.ok){let e=await a.text();await i(e);return}return await a.json()}catch(e){throw console.error("Error updating tag:",e),e}},e8=async(e,t)=>{try{let o=n?"".concat(n,"/tag/info"):"/tag/info",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify({names:t})});if(!a.ok){let e=await a.text();return await i(e),{}}return await a.json()}catch(e){throw console.error("Error getting tag info:",e),e}},te=async e=>{try{let t=n?"".concat(n,"/tag/list"):"/tag/list",o=await fetch(t,{method:"GET",headers:{Authorization:"Bearer ".concat(e)}});if(!o.ok){let e=await o.text();return await i(e),{}}return await o.json()}catch(e){throw console.error("Error listing tags:",e),e}},tt=async(e,t)=>{try{let o=n?"".concat(n,"/tag/delete"):"/tag/delete",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify({name:t})});if(!a.ok){let e=await a.text();await i(e);return}return await a.json()}catch(e){throw console.error("Error deleting tag:",e),e}},to=async e=>{try{let t=n?"".concat(n,"/get/default_team_settings"):"/get/default_team_settings";console.log("Fetching default team settings from:",t);let o=await fetch(t,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw i(e),Error("Network response was not ok")}let a=await o.json();return console.log("Fetched default team settings:",a),a}catch(e){throw console.error("Failed to fetch default team settings:",e),e}},ta=async(e,t)=>{try{let o=n?"".concat(n,"/update/default_team_settings"):"/update/default_team_settings";console.log("Updating default team settings:",t);let a=await fetch(o,{method:"PATCH",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(t)});if(!a.ok){let e=await a.text();throw i(e),Error("Network response was not ok")}let c=await a.json();return console.log("Updated default team settings:",c),r.ZP.success("Default team settings updated successfully"),c}catch(e){throw console.error("Failed to update default team settings:",e),e}},tr=async(e,t)=>{try{let o=n?"".concat(n,"/team/permissions_list?team_id=").concat(t):"/team/permissions_list?team_id=".concat(t),a=await fetch(o,{method:"GET",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)}});if(!a.ok){let e=await a.text();throw i(e),Error("Network response was not ok")}let r=await a.json();return console.log("Team permissions response:",r),r}catch(e){throw console.error("Failed to get team permissions:",e),e}},tn=async(e,t,o)=>{try{let a=n?"".concat(n,"/team/permissions_update"):"/team/permissions_update",r=await fetch(a,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify({team_id:t,team_member_permissions:o})});if(!r.ok){let e=await r.text();throw i(e),Error("Network response was not ok")}let c=await r.json();return console.log("Team permissions response:",c),c}catch(e){throw console.error("Failed to update team permissions:",e),e}},tc=async(e,t)=>{try{let o=n?"".concat(n,"/spend/logs/session/ui?session_id=").concat(encodeURIComponent(t)):"/spend/logs/session/ui?session_id=".concat(encodeURIComponent(t)),a=await fetch(o,{method:"GET",headers:{[l]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw i(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to fetch session logs:",e),e}}},20347:function(e,t,o){o.d(t,{LQ:function(){return n},ZL:function(){return a},lo:function(){return r},tY:function(){return c}});let a=["Admin","Admin Viewer","proxy_admin","proxy_admin_viewer","org_admin"],r=["Internal User","Internal Viewer"],n=["Internal User","Admin"],c=e=>a.includes(e)}}]);
ui/litellm-dashboard/out/_next/static/chunks/261-92d8946249b3296e.js ADDED
The diff for this file is too large to render. See raw diff
 
ui/litellm-dashboard/out/_next/static/chunks/3014691f-b7b79b78e27792f3.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[665],{84566:function(e,t,s){s.d(t,{GH$:function(){return l}});var c=s(2265);let l=({color:e="currentColor",size:t=24,className:s,...l})=>c.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...l,className:"remixicon "+(s||"")},c.createElement("path",{d:"M12 22C6.47715 22 2 17.5228 2 12C2 6.47715 6.47715 2 12 2C17.5228 2 22 6.47715 22 12C22 17.5228 17.5228 22 12 22ZM12 20C16.4183 20 20 16.4183 20 12C20 7.58172 16.4183 4 12 4C7.58172 4 4 7.58172 4 12C4 16.4183 7.58172 20 12 20ZM11.0026 16L6.75999 11.7574L8.17421 10.3431L11.0026 13.1716L16.6595 7.51472L18.0737 8.92893L11.0026 16Z"}))}}]);
ui/litellm-dashboard/out/_next/static/chunks/42-014374badc35fe9b.js ADDED
The diff for this file is too large to render. See raw diff
 
ui/litellm-dashboard/out/_next/static/chunks/699-7e1943e09d25350c.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[699],{92699:function(e,n,t){t.d(n,{Z:function(){return k}});var s=t(57437),l=t(2265),o=t(99376),r=t(19250),a=t(20831),i=t(12514),c=t(12485),d=t(18135),m=t(35242),p=t(29706),u=t(77991),x=t(84264),h=t(96761),_=t(23639),g=t(77565),j=t(75957),y=t(51369),b=t(17906),k=e=>{var n;let{accessToken:t,publicPage:k,premiumUser:f}=e,[Z,v]=(0,l.useState)(!1),[w,N]=(0,l.useState)(null),[S,M]=(0,l.useState)(!1),[A,I]=(0,l.useState)(!1),[O,P]=(0,l.useState)(null),C=(0,o.useRouter)();(0,l.useEffect)(()=>{t&&(async()=>{try{let e=await (0,r.kn)(t);console.log("ModelHubData:",e),N(e.data),(0,r.E9)(t,"enable_public_model_hub").then(e=>{console.log("data: ".concat(JSON.stringify(e))),!0==e.field_value&&v(!0)}).catch(e=>{})}catch(e){console.error("There was an error fetching the model data",e)}})()},[t,k]);let U=e=>{P(e),M(!0)},T=async()=>{t&&(0,r.jA)(t,"enable_public_model_hub",!0).then(e=>{I(!0)})},z=()=>{M(!1),I(!1),P(null)},H=()=>{M(!1),I(!1),P(null)},E=e=>{navigator.clipboard.writeText(e)};return(0,s.jsxs)("div",{children:[k&&Z||!1==k?(0,s.jsxs)("div",{className:"w-full m-2 mt-2 p-8",children:[(0,s.jsx)("div",{className:"relative w-full"}),(0,s.jsxs)("div",{className:"flex ".concat(k?"justify-between":"items-center"),children:[(0,s.jsx)(h.Z,{className:"ml-8 text-center ",children:"Model Hub"}),!1==k?f?(0,s.jsx)(a.Z,{className:"ml-4",onClick:()=>T(),children:"✨ Make Public"}):(0,s.jsx)(a.Z,{className:"ml-4",children:(0,s.jsx)("a",{href:"https://forms.gle/W3U4PZpJGFHWtHyA9",target:"_blank",children:"✨ Make Public"})}):(0,s.jsxs)("div",{className:"flex justify-between items-center",children:[(0,s.jsx)("p",{children:"Filter by key:"}),(0,s.jsx)(x.Z,{className:"bg-gray-200 pr-2 pl-2 pt-1 pb-1 text-center",children:"/ui/model_hub?key=<YOUR_KEY>"})]})]}),(0,s.jsx)("div",{className:"grid grid-cols-1 gap-6 md:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4 pr-8",children:w&&w.map(e=>(0,s.jsxs)(i.Z,{className:"mt-5 mx-8",children:[(0,s.jsxs)("pre",{className:"flex justify-between",children:[(0,s.jsx)(h.Z,{className:"text-wrap",children:e.model_group}),(0,s.jsx)(j.Z,{title:e.model_group,children:(0,s.jsx)(_.Z,{onClick:()=>E(e.model_group),style:{cursor:"pointer",marginRight:"10px"}})})]}),(0,s.jsxs)("div",{className:"my-5",children:[(0,s.jsxs)(x.Z,{children:["Max Input Tokens:"," ",(null==e?void 0:e.max_input_tokens)?null==e?void 0:e.max_input_tokens:"Unknown"]}),(0,s.jsxs)(x.Z,{children:["Max Output Tokens:"," ",(null==e?void 0:e.max_output_tokens)?null==e?void 0:e.max_output_tokens:"Unknown"]}),(0,s.jsxs)(x.Z,{children:["Input Cost Per 1M Tokens (USD):"," ",(null==e?void 0:e.input_cost_per_token)?"$".concat((1e6*e.input_cost_per_token).toFixed(2)):"Unknown"]}),(0,s.jsxs)(x.Z,{children:["Output Cost Per 1M Tokens (USD):"," ",(null==e?void 0:e.output_cost_per_token)?"$".concat((1e6*e.output_cost_per_token).toFixed(2)):"Unknown"]})]}),(0,s.jsx)("div",{style:{marginTop:"auto",textAlign:"right"},children:(0,s.jsxs)("a",{href:"#",onClick:()=>U(e),style:{color:"#1890ff",fontSize:"smaller"},children:["View more ",(0,s.jsx)(g.Z,{})]})})]},e.model_group))})]}):(0,s.jsxs)(i.Z,{className:"mx-auto max-w-xl mt-10",children:[(0,s.jsx)(x.Z,{className:"text-xl text-center mb-2 text-black",children:"Public Model Hub not enabled."}),(0,s.jsx)("p",{className:"text-base text-center text-slate-800",children:"Ask your proxy admin to enable this on their Admin UI."})]}),(0,s.jsx)(y.Z,{title:"Public Model Hub",width:600,visible:A,footer:null,onOk:z,onCancel:H,children:(0,s.jsxs)("div",{className:"pt-5 pb-5",children:[(0,s.jsxs)("div",{className:"flex justify-between mb-4",children:[(0,s.jsx)(x.Z,{className:"text-base mr-2",children:"Shareable Link:"}),(0,s.jsx)(x.Z,{className:"max-w-sm ml-2 bg-gray-200 pr-2 pl-2 pt-1 pb-1 text-center rounded",children:"<proxy_base_url>/ui/model_hub?key=<YOUR_API_KEY>"})]}),(0,s.jsx)("div",{className:"flex justify-end",children:(0,s.jsx)(a.Z,{onClick:()=>{C.replace("/model_hub?key=".concat(t))},children:"See Page"})})]})}),(0,s.jsx)(y.Z,{title:O&&O.model_group?O.model_group:"Unknown Model",width:800,visible:S,footer:null,onOk:z,onCancel:H,children:O&&(0,s.jsxs)("div",{children:[(0,s.jsx)("p",{className:"mb-4",children:(0,s.jsx)("strong",{children:"Model Information & Usage"})}),(0,s.jsxs)(d.Z,{children:[(0,s.jsxs)(m.Z,{children:[(0,s.jsx)(c.Z,{children:"Model Information"}),(0,s.jsx)(c.Z,{children:"OpenAI Python SDK"}),(0,s.jsx)(c.Z,{children:"Supported OpenAI Params"}),(0,s.jsx)(c.Z,{children:"LlamaIndex"}),(0,s.jsx)(c.Z,{children:"Langchain Py"})]}),(0,s.jsxs)(u.Z,{children:[(0,s.jsx)(p.Z,{children:(0,s.jsxs)(x.Z,{children:[(0,s.jsx)("strong",{children:"Model Group:"}),(0,s.jsx)("pre",{children:JSON.stringify(O,null,2)})]})}),(0,s.jsx)(p.Z,{children:(0,s.jsx)(b.Z,{language:"python",children:'\nimport openai\nclient = openai.OpenAI(\n api_key="your_api_key",\n base_url="http://0.0.0.0:4000" # LiteLLM Proxy is OpenAI compatible, Read More: https://docs.litellm.ai/docs/proxy/user_keys\n)\n\nresponse = client.chat.completions.create(\n model="'.concat(O.model_group,'", # model to send to the proxy\n messages = [\n {\n "role": "user",\n "content": "this is a test request, write a short poem"\n }\n ]\n)\n\nprint(response)\n ')})}),(0,s.jsx)(p.Z,{children:(0,s.jsx)(b.Z,{language:"python",children:"".concat(null===(n=O.supported_openai_params)||void 0===n?void 0:n.map(e=>"".concat(e,"\n")).join(""))})}),(0,s.jsx)(p.Z,{children:(0,s.jsx)(b.Z,{language:"python",children:'\nimport os, dotenv\n\nfrom llama_index.llms import AzureOpenAI\nfrom llama_index.embeddings import AzureOpenAIEmbedding\nfrom llama_index import VectorStoreIndex, SimpleDirectoryReader, ServiceContext\n\nllm = AzureOpenAI(\n engine="'.concat(O.model_group,'", # model_name on litellm proxy\n temperature=0.0,\n azure_endpoint="http://0.0.0.0:4000", # litellm proxy endpoint\n api_key="sk-1234", # litellm proxy API Key\n api_version="2023-07-01-preview",\n)\n\nembed_model = AzureOpenAIEmbedding(\n deployment_name="azure-embedding-model",\n azure_endpoint="http://0.0.0.0:4000",\n api_key="sk-1234",\n api_version="2023-07-01-preview",\n)\n\n\ndocuments = SimpleDirectoryReader("llama_index_data").load_data()\nservice_context = ServiceContext.from_defaults(llm=llm, embed_model=embed_model)\nindex = VectorStoreIndex.from_documents(documents, service_context=service_context)\n\nquery_engine = index.as_query_engine()\nresponse = query_engine.query("What did the author do growing up?")\nprint(response)\n\n ')})}),(0,s.jsx)(p.Z,{children:(0,s.jsx)(b.Z,{language:"python",children:'\nfrom langchain.chat_models import ChatOpenAI\nfrom langchain.prompts.chat import (\n ChatPromptTemplate,\n HumanMessagePromptTemplate,\n SystemMessagePromptTemplate,\n)\nfrom langchain.schema import HumanMessage, SystemMessage\n\nchat = ChatOpenAI(\n openai_api_base="http://0.0.0.0:4000",\n model = "'.concat(O.model_group,'",\n temperature=0.1\n)\n\nmessages = [\n SystemMessage(\n content="You are a helpful assistant that im using to make a test request to."\n ),\n HumanMessage(\n content="test from litellm. tell me why it\'s amazing in 1 sentence"\n ),\n]\nresponse = chat(messages)\n\nprint(response)\n\n ')})})]})]})]})})]})}}}]);
ui/litellm-dashboard/out/_next/static/chunks/894-25933cb7e07826a8.js ADDED
The diff for this file is too large to render. See raw diff
 
ui/litellm-dashboard/out/_next/static/chunks/899-54ea329f41297bf0.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[899],{69262:function(e,t,n){n.d(t,{Z:function(){return u}});var r=n(5853),o=n(2265);let a=e=>{var t=(0,r._T)(e,[]);return o.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor"},t),o.createElement("path",{d:"M12 22C6.47715 22 2 17.5228 2 12C2 6.47715 6.47715 2 12 2C17.5228 2 22 6.47715 22 12C22 17.5228 17.5228 22 12 22ZM11 15V17H13V15H11ZM11 7V13H13V7H11Z"}))},l=e=>{var t=(0,r._T)(e,[]);return o.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor"},t),o.createElement("path",{d:"M1.18164 12C2.12215 6.87976 6.60812 3 12.0003 3C17.3924 3 21.8784 6.87976 22.8189 12C21.8784 17.1202 17.3924 21 12.0003 21C6.60812 21 2.12215 17.1202 1.18164 12ZM12.0003 17C14.7617 17 17.0003 14.7614 17.0003 12C17.0003 9.23858 14.7617 7 12.0003 7C9.23884 7 7.00026 9.23858 7.00026 12C7.00026 14.7614 9.23884 17 12.0003 17ZM12.0003 15C10.3434 15 9.00026 13.6569 9.00026 12C9.00026 10.3431 10.3434 9 12.0003 9C13.6571 9 15.0003 10.3431 15.0003 12C15.0003 13.6569 13.6571 15 12.0003 15Z"}))},c=e=>{var t=(0,r._T)(e,[]);return o.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor"},t),o.createElement("path",{d:"M4.52047 5.93457L1.39366 2.80777L2.80788 1.39355L22.6069 21.1925L21.1927 22.6068L17.8827 19.2968C16.1814 20.3755 14.1638 21.0002 12.0003 21.0002C6.60812 21.0002 2.12215 17.1204 1.18164 12.0002C1.61832 9.62282 2.81932 7.5129 4.52047 5.93457ZM14.7577 16.1718L13.2937 14.7078C12.902 14.8952 12.4634 15.0002 12.0003 15.0002C10.3434 15.0002 9.00026 13.657 9.00026 12.0002C9.00026 11.537 9.10522 11.0984 9.29263 10.7067L7.82866 9.24277C7.30514 10.0332 7.00026 10.9811 7.00026 12.0002C7.00026 14.7616 9.23884 17.0002 12.0003 17.0002C13.0193 17.0002 13.9672 16.6953 14.7577 16.1718ZM7.97446 3.76015C9.22127 3.26959 10.5793 3.00016 12.0003 3.00016C17.3924 3.00016 21.8784 6.87992 22.8189 12.0002C22.5067 13.6998 21.8038 15.2628 20.8068 16.5925L16.947 12.7327C16.9821 12.4936 17.0003 12.249 17.0003 12.0002C17.0003 9.23873 14.7617 7.00016 12.0003 7.00016C11.7514 7.00016 11.5068 7.01833 11.2677 7.05343L7.97446 3.76015Z"}))};var i=n(96398),s=n(97324),d=n(1153);let u=o.forwardRef((e,t)=>{let{value:n,defaultValue:u,type:m,placeholder:p="Type...",icon:f,error:g=!1,errorMessage:h,disabled:b=!1,stepper:v,makeInputClassName:y,className:x,onChange:w,onValueChange:C,autoFocus:E}=e,k=(0,r._T)(e,["value","defaultValue","type","placeholder","icon","error","errorMessage","disabled","stepper","makeInputClassName","className","onChange","onValueChange","autoFocus"]),[O,j]=(0,o.useState)(E||!1),[S,M]=(0,o.useState)(!1),I=(0,o.useCallback)(()=>M(!S),[S,M]),N=(0,o.useRef)(null),Z=(0,i.Uh)(n||u);return o.useEffect(()=>{let e=()=>j(!0),t=()=>j(!1),n=N.current;return n&&(n.addEventListener("focus",e),n.addEventListener("blur",t),E&&n.focus()),()=>{n&&(n.removeEventListener("focus",e),n.removeEventListener("blur",t))}},[E]),o.createElement(o.Fragment,null,o.createElement("div",{className:(0,s.q)(y("root"),"relative w-full flex items-center min-w-[10rem] outline-none rounded-tremor-default transition duration-100 border","shadow-tremor-input","dark:shadow-dark-tremor-input",(0,i.um)(Z,b,g),O&&(0,s.q)("ring-2","border-tremor-brand-subtle ring-tremor-brand-muted","dark:border-dark-tremor-brand-subtle dark:ring-dark-tremor-brand-muted"),x)},f?o.createElement(f,{className:(0,s.q)(y("icon"),"shrink-0 h-5 w-5 ml-2.5","text-tremor-content-subtle","dark:text-dark-tremor-content-subtle")}):null,o.createElement("input",Object.assign({ref:(0,d.lq)([N,t]),defaultValue:u,value:n,type:S?"text":m,className:(0,s.q)(y("input"),"w-full focus:outline-none focus:ring-0 border-none bg-transparent text-tremor-default rounded-tremor-default transition duration-100 py-2","text-tremor-content-emphasis","dark:text-dark-tremor-content-emphasis","[appearance:textfield] [&::-webkit-outer-spin-button]:appearance-none [&::-webkit-inner-spin-button]:appearance-none",f?"pl-2":"pl-3",g?"pr-3":"pr-4",b?"placeholder:text-tremor-content-subtle dark:placeholder:text-dark-tremor-content-subtle":"placeholder:text-tremor-content dark:placeholder:text-dark-tremor-content"),placeholder:p,disabled:b,"data-testid":"base-input",onChange:e=>{null==w||w(e),null==C||C(e.target.value)}},k)),"password"!==m||b?null:o.createElement("button",{className:(0,s.q)(y("toggleButton"),"mr-2"),type:"button",onClick:()=>I(),"aria-label":S?"Hide password":"Show Password"},S?o.createElement(c,{className:(0,s.q)("flex-none h-5 w-5 transition","text-tremor-content-subtle hover:text-tremor-content","dark:text-dark-tremor-content-subtle hover:dark:text-dark-tremor-content"),"aria-hidden":!0}):o.createElement(l,{className:(0,s.q)("flex-none h-5 w-5 transition","text-tremor-content-subtle hover:text-tremor-content","dark:text-dark-tremor-content-subtle hover:dark:text-dark-tremor-content"),"aria-hidden":!0})),g?o.createElement(a,{className:(0,s.q)(y("errorIcon"),"text-red-500 shrink-0 w-5 h-5 mr-2.5")}):null,null!=v?v:null),g&&h?o.createElement("p",{className:(0,s.q)(y("errorMessage"),"text-sm text-red-500 mt-1")},h):null)});u.displayName="BaseInput"},49566:function(e,t,n){n.d(t,{Z:function(){return i}});var r=n(5853),o=n(2265);n(97324);var a=n(1153),l=n(69262);let c=(0,a.fn)("TextInput"),i=o.forwardRef((e,t)=>{let{type:n="text"}=e,a=(0,r._T)(e,["type"]);return o.createElement(l.Z,Object.assign({ref:t,type:n,makeInputClassName:c},a))});i.displayName="TextInput"},96398:function(e,t,n){n.d(t,{Uh:function(){return s},n0:function(){return c},qg:function(){return a},sl:function(){return l},um:function(){return i}});var r=n(97324),o=n(2265);let a=e=>["string","number"].includes(typeof e)?e:e instanceof Array?e.map(a).join(""):"object"==typeof e&&e?a(e.props.children):void 0;function l(e){let t=new Map;return o.Children.map(e,e=>{var n;t.set(e.props.value,null!==(n=a(e))&&void 0!==n?n:e.props.value)}),t}function c(e,t){return o.Children.map(t,t=>{var n;if((null!==(n=a(t))&&void 0!==n?n:t.props.value).toLowerCase().includes(e.toLowerCase()))return t})}let i=function(e,t){let n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return(0,r.q)(t?"bg-tremor-background-subtle dark:bg-dark-tremor-background-subtle":"bg-tremor-background dark:bg-dark-tremor-background",!t&&"hover:bg-tremor-background-muted dark:hover:bg-dark-tremor-background-muted",e?"text-tremor-content-emphasis dark:text-dark-tremor-content-emphasis":"text-tremor-content dark:text-dark-tremor-content",t&&"text-tremor-content-subtle dark:text-dark-tremor-content-subtle",n&&"text-red-500",n?"border-red-500":"border-tremor-border dark:border-dark-tremor-border")};function s(e){return null!=e&&""!==e}},49804:function(e,t,n){n.d(t,{Z:function(){return s}});var r=n(5853),o=n(97324),a=n(1153),l=n(2265),c=n(9496);let i=(0,a.fn)("Col"),s=l.forwardRef((e,t)=>{let{numColSpan:n=1,numColSpanSm:a,numColSpanMd:s,numColSpanLg:d,children:u,className:m}=e,p=(0,r._T)(e,["numColSpan","numColSpanSm","numColSpanMd","numColSpanLg","children","className"]),f=(e,t)=>e&&Object.keys(t).includes(String(e))?t[e]:"";return l.createElement("div",Object.assign({ref:t,className:(0,o.q)(i("root"),(()=>{let e=f(n,c.PT),t=f(a,c.SP),r=f(s,c.VS),l=f(d,c._w);return(0,o.q)(e,t,r,l)})(),m)},p),u)});s.displayName="Col"},67101:function(e,t,n){n.d(t,{Z:function(){return d}});var r=n(5853),o=n(97324),a=n(1153),l=n(2265),c=n(9496);let i=(0,a.fn)("Grid"),s=(e,t)=>e&&Object.keys(t).includes(String(e))?t[e]:"",d=l.forwardRef((e,t)=>{let{numItems:n=1,numItemsSm:a,numItemsMd:d,numItemsLg:u,children:m,className:p}=e,f=(0,r._T)(e,["numItems","numItemsSm","numItemsMd","numItemsLg","children","className"]),g=s(n,c._m),h=s(a,c.LH),b=s(d,c.l5),v=s(u,c.N4),y=(0,o.q)(g,h,b,v);return l.createElement("div",Object.assign({ref:t,className:(0,o.q)(i("root"),"grid",y,p)},f),m)});d.displayName="Grid"},9496:function(e,t,n){n.d(t,{LH:function(){return o},N4:function(){return l},PT:function(){return c},SP:function(){return i},VS:function(){return s},_m:function(){return r},_w:function(){return d},l5:function(){return a}});let r={0:"grid-cols-none",1:"grid-cols-1",2:"grid-cols-2",3:"grid-cols-3",4:"grid-cols-4",5:"grid-cols-5",6:"grid-cols-6",7:"grid-cols-7",8:"grid-cols-8",9:"grid-cols-9",10:"grid-cols-10",11:"grid-cols-11",12:"grid-cols-12"},o={0:"sm:grid-cols-none",1:"sm:grid-cols-1",2:"sm:grid-cols-2",3:"sm:grid-cols-3",4:"sm:grid-cols-4",5:"sm:grid-cols-5",6:"sm:grid-cols-6",7:"sm:grid-cols-7",8:"sm:grid-cols-8",9:"sm:grid-cols-9",10:"sm:grid-cols-10",11:"sm:grid-cols-11",12:"sm:grid-cols-12"},a={0:"md:grid-cols-none",1:"md:grid-cols-1",2:"md:grid-cols-2",3:"md:grid-cols-3",4:"md:grid-cols-4",5:"md:grid-cols-5",6:"md:grid-cols-6",7:"md:grid-cols-7",8:"md:grid-cols-8",9:"md:grid-cols-9",10:"md:grid-cols-10",11:"md:grid-cols-11",12:"md:grid-cols-12"},l={0:"lg:grid-cols-none",1:"lg:grid-cols-1",2:"lg:grid-cols-2",3:"lg:grid-cols-3",4:"lg:grid-cols-4",5:"lg:grid-cols-5",6:"lg:grid-cols-6",7:"lg:grid-cols-7",8:"lg:grid-cols-8",9:"lg:grid-cols-9",10:"lg:grid-cols-10",11:"lg:grid-cols-11",12:"lg:grid-cols-12"},c={1:"col-span-1",2:"col-span-2",3:"col-span-3",4:"col-span-4",5:"col-span-5",6:"col-span-6",7:"col-span-7",8:"col-span-8",9:"col-span-9",10:"col-span-10",11:"col-span-11",12:"col-span-12",13:"col-span-13"},i={1:"sm:col-span-1",2:"sm:col-span-2",3:"sm:col-span-3",4:"sm:col-span-4",5:"sm:col-span-5",6:"sm:col-span-6",7:"sm:col-span-7",8:"sm:col-span-8",9:"sm:col-span-9",10:"sm:col-span-10",11:"sm:col-span-11",12:"sm:col-span-12",13:"sm:col-span-13"},s={1:"md:col-span-1",2:"md:col-span-2",3:"md:col-span-3",4:"md:col-span-4",5:"md:col-span-5",6:"md:col-span-6",7:"md:col-span-7",8:"md:col-span-8",9:"md:col-span-9",10:"md:col-span-10",11:"md:col-span-11",12:"md:col-span-12",13:"md:col-span-13"},d={1:"lg:col-span-1",2:"lg:col-span-2",3:"lg:col-span-3",4:"lg:col-span-4",5:"lg:col-span-5",6:"lg:col-span-6",7:"lg:col-span-7",8:"lg:col-span-8",9:"lg:col-span-9",10:"lg:col-span-10",11:"lg:col-span-11",12:"lg:col-span-12",13:"lg:col-span-13"}},94789:function(e,t,n){n.d(t,{Z:function(){return s}});var r=n(5853),o=n(2265),a=n(26898),l=n(97324),c=n(1153);let i=(0,c.fn)("Callout"),s=o.forwardRef((e,t)=>{let{title:n,icon:s,color:d,className:u,children:m}=e,p=(0,r._T)(e,["title","icon","color","className","children"]);return o.createElement("div",Object.assign({ref:t,className:(0,l.q)(i("root"),"flex flex-col overflow-hidden rounded-tremor-default text-tremor-default border-l-4 py-3 pr-3 pl-4",d?(0,l.q)((0,c.bM)(d,a.K.background).bgColor,(0,c.bM)(d,a.K.darkBorder).borderColor,(0,c.bM)(d,a.K.darkText).textColor,"dark:bg-opacity-10 bg-opacity-10"):(0,l.q)("bg-tremor-brand-faint border-tremor-brand-emphasis text-tremor-brand-emphasis","dark:bg-dark-tremor-brand-muted/70 dark:border-dark-tremor-brand-emphasis dark:text-dark-tremor-brand-emphasis"),u)},p),o.createElement("div",{className:(0,l.q)(i("header"),"flex items-start")},s?o.createElement(s,{className:(0,l.q)(i("icon"),"flex-none h-5 w-5 mr-1.5")}):null,o.createElement("h4",{className:(0,l.q)(i("title"),"font-semibold")},n)),o.createElement("p",{className:(0,l.q)(i("body"),"overflow-y-auto",m?"mt-2":"")},m))});s.displayName="Callout"},6543:function(e,t,n){n.d(t,{ZP:function(){return i},c4:function(){return a}});var r=n(2265),o=n(29961);let a=["xxl","xl","lg","md","sm","xs"],l=e=>({xs:"(max-width: ".concat(e.screenXSMax,"px)"),sm:"(min-width: ".concat(e.screenSM,"px)"),md:"(min-width: ".concat(e.screenMD,"px)"),lg:"(min-width: ".concat(e.screenLG,"px)"),xl:"(min-width: ".concat(e.screenXL,"px)"),xxl:"(min-width: ".concat(e.screenXXL,"px)")}),c=e=>{let t=[].concat(a).reverse();return t.forEach((n,r)=>{let o=n.toUpperCase(),a="screen".concat(o,"Min"),l="screen".concat(o);if(!(e[a]<=e[l]))throw Error("".concat(a,"<=").concat(l," fails : !(").concat(e[a],"<=").concat(e[l],")"));if(r<t.length-1){let n="screen".concat(o,"Max");if(!(e[l]<=e[n]))throw Error("".concat(l,"<=").concat(n," fails : !(").concat(e[l],"<=").concat(e[n],")"));let a=t[r+1].toUpperCase(),c="screen".concat(a,"Min");if(!(e[n]<=e[c]))throw Error("".concat(n,"<=").concat(c," fails : !(").concat(e[n],"<=").concat(e[c],")"))}}),e};function i(){let[,e]=(0,o.ZP)(),t=l(c(e));return r.useMemo(()=>{let e=new Map,n=-1,r={};return{matchHandlers:{},dispatch:t=>(r=t,e.forEach(e=>e(r)),e.size>=1),subscribe(t){return e.size||this.register(),n+=1,e.set(n,t),t(r),n},unsubscribe(t){e.delete(t),e.size||this.unregister()},unregister(){Object.keys(t).forEach(e=>{let n=t[e],r=this.matchHandlers[n];null==r||r.mql.removeListener(null==r?void 0:r.listener)}),e.clear()},register(){Object.keys(t).forEach(e=>{let n=t[e],o=t=>{let{matches:n}=t;this.dispatch(Object.assign(Object.assign({},r),{[e]:n}))},a=window.matchMedia(n);a.addListener(o),this.matchHandlers[n]={mql:a,listener:o},o(a)})},responsiveMap:t}},[e])}},14605:function(e,t,n){var r=n(83145),o=n(36760),a=n.n(o),l=n(47970),c=n(2265),i=n(68710),s=n(39109),d=n(4064),u=n(47713),m=n(64024);let p=[];function f(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0;return{key:"string"==typeof e?e:"".concat(t,"-").concat(r),error:e,errorStatus:n}}t.Z=e=>{let{help:t,helpStatus:n,errors:o=p,warnings:g=p,className:h,fieldId:b,onVisibleChanged:v}=e,{prefixCls:y}=c.useContext(s.Rk),x="".concat(y,"-item-explain"),w=(0,m.Z)(y),[C,E,k]=(0,u.ZP)(y,w),O=(0,c.useMemo)(()=>(0,i.Z)(y),[y]),j=(0,d.Z)(o),S=(0,d.Z)(g),M=c.useMemo(()=>null!=t?[f(t,"help",n)]:[].concat((0,r.Z)(j.map((e,t)=>f(e,"error","error",t))),(0,r.Z)(S.map((e,t)=>f(e,"warning","warning",t)))),[t,n,j,S]),I={};return b&&(I.id="".concat(b,"_help")),C(c.createElement(l.ZP,{motionDeadline:O.motionDeadline,motionName:"".concat(y,"-show-help"),visible:!!M.length,onVisibleChanged:v},e=>{let{className:t,style:n}=e;return c.createElement("div",Object.assign({},I,{className:a()(x,t,k,w,h,E),style:n,role:"alert"}),c.createElement(l.V4,Object.assign({keys:M},(0,i.Z)(y),{motionName:"".concat(y,"-show-help-item"),component:!1}),e=>{let{key:t,error:n,errorStatus:r,className:o,style:l}=e;return c.createElement("div",{key:t,className:a()(o,{["".concat(x,"-").concat(r)]:r}),style:l},n)}))}))}},86582:function(e,t,n){n.d(t,{Z:function(){return Y}});var r=n(83145),o=n(2265),a=n(36760),l=n.n(a),c=n(64834),i=n(69819),s=n(28791),d=n(19722),u=n(13613),m=n(71744),p=n(64024),f=n(39109),g=n(45287);let h=()=>{let{status:e,errors:t=[],warnings:n=[]}=(0,o.useContext)(f.aM);return{status:e,errors:t,warnings:n}};h.Context=f.aM;var b=n(53346),v=n(47713),y=n(13861),x=n(2857),w=n(27380),C=n(18694),E=n(10295),k=n(54998),O=n(14605),j=n(80669);let S=e=>{let{formItemCls:t}=e;return{"@media screen and (-ms-high-contrast: active), (-ms-high-contrast: none)":{["".concat(t,"-control")]:{display:"flex"}}}};var M=(0,j.bk)(["Form","item-item"],(e,t)=>{let{rootPrefixCls:n}=t;return[S((0,v.B4)(e,n))]}),I=e=>{let{prefixCls:t,status:n,wrapperCol:r,children:a,errors:c,warnings:i,_internalItemRender:s,extra:d,help:u,fieldId:m,marginBottom:p,onErrorVisibleChanged:g}=e,h="".concat(t,"-item"),b=o.useContext(f.q3),v=r||b.wrapperCol||{},y=l()("".concat(h,"-control"),v.className),x=o.useMemo(()=>Object.assign({},b),[b]);delete x.labelCol,delete x.wrapperCol;let w=o.createElement("div",{className:"".concat(h,"-control-input")},o.createElement("div",{className:"".concat(h,"-control-input-content")},a)),C=o.useMemo(()=>({prefixCls:t,status:n}),[t,n]),E=null!==p||c.length||i.length?o.createElement("div",{style:{display:"flex",flexWrap:"nowrap"}},o.createElement(f.Rk.Provider,{value:C},o.createElement(O.Z,{fieldId:m,errors:c,warnings:i,help:u,helpStatus:n,className:"".concat(h,"-explain-connected"),onVisibleChanged:g})),!!p&&o.createElement("div",{style:{width:0,height:p}})):null,j={};m&&(j.id="".concat(m,"_extra"));let S=d?o.createElement("div",Object.assign({},j,{className:"".concat(h,"-extra")}),d):null,I=s&&"pro_table_render"===s.mark&&s.render?s.render(e,{input:w,errorList:E,extra:S}):o.createElement(o.Fragment,null,w,E,S);return o.createElement(f.q3.Provider,{value:x},o.createElement(k.Z,Object.assign({},v,{className:y}),I),o.createElement(M,{prefixCls:t}))},N=n(1119),Z={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M623.6 316.7C593.6 290.4 554 276 512 276s-81.6 14.5-111.6 40.7C369.2 344 352 380.7 352 420v7.6c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V420c0-44.1 43.1-80 96-80s96 35.9 96 80c0 31.1-22 59.6-56.1 72.7-21.2 8.1-39.2 22.3-52.1 40.9-13.1 19-19.9 41.8-19.9 64.9V620c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8v-22.7a48.3 48.3 0 0130.9-44.8c59-22.7 97.1-74.7 97.1-132.5.1-39.3-17.1-76-48.3-103.3zM472 732a40 40 0 1080 0 40 40 0 10-80 0z"}}]},name:"question-circle",theme:"outlined"},q=n(55015),F=o.forwardRef(function(e,t){return o.createElement(q.Z,(0,N.Z)({},e,{ref:t,icon:Z}))}),P=n(13823),L=n(55274),R=n(75957),_=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)0>t.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n},T=e=>{var t;let{prefixCls:n,label:r,htmlFor:a,labelCol:c,labelAlign:i,colon:s,required:d,requiredMark:u,tooltip:m}=e,[p]=(0,L.Z)("Form"),{vertical:g,labelAlign:h,labelCol:b,labelWrap:v,colon:y}=o.useContext(f.q3);if(!r)return null;let x=c||b||{},w="".concat(n,"-item-label"),C=l()(w,"left"===(i||h)&&"".concat(w,"-left"),x.className,{["".concat(w,"-wrap")]:!!v}),E=r,O=!0===s||!1!==y&&!1!==s;O&&!g&&"string"==typeof r&&""!==r.trim()&&(E=r.replace(/[:|:]\s*$/,""));let j=m?"object"!=typeof m||o.isValidElement(m)?{title:m}:m:null;if(j){let{icon:e=o.createElement(F,null)}=j,t=_(j,["icon"]),r=o.createElement(R.Z,Object.assign({},t),o.cloneElement(e,{className:"".concat(n,"-item-tooltip"),title:"",onClick:e=>{e.preventDefault()},tabIndex:null}));E=o.createElement(o.Fragment,null,E,r)}let S="optional"===u,M="function"==typeof u;M?E=u(E,{required:!!d}):S&&!d&&(E=o.createElement(o.Fragment,null,E,o.createElement("span",{className:"".concat(n,"-item-optional"),title:""},(null==p?void 0:p.optional)||(null===(t=P.Z.Form)||void 0===t?void 0:t.optional))));let I=l()({["".concat(n,"-item-required")]:d,["".concat(n,"-item-required-mark-optional")]:S||M,["".concat(n,"-item-no-colon")]:!O});return o.createElement(k.Z,Object.assign({},x,{className:C}),o.createElement("label",{htmlFor:a,className:I,title:"string"==typeof r?r:""},E))},H=n(4064),W=n(8900),V=n(39725),z=n(54537),D=n(61935);let A={success:W.Z,warning:z.Z,error:V.Z,validating:D.Z};function B(e){let{children:t,errors:n,warnings:r,hasFeedback:a,validateStatus:c,prefixCls:i,meta:s,noStyle:d}=e,u="".concat(i,"-item"),{feedbackIcons:m}=o.useContext(f.q3),p=(0,y.lR)(n,r,s,null,!!a,c),{isFormItemInput:g,status:h,hasFeedback:b,feedbackIcon:v}=o.useContext(f.aM),x=o.useMemo(()=>{var e;let t;if(a){let c=!0!==a&&a.icons||m,i=p&&(null===(e=null==c?void 0:c({status:p,errors:n,warnings:r}))||void 0===e?void 0:e[p]),s=p&&A[p];t=!1!==i&&s?o.createElement("span",{className:l()("".concat(u,"-feedback-icon"),"".concat(u,"-feedback-icon-").concat(p))},i||o.createElement(s,null)):null}let c={status:p||"",errors:n,warnings:r,hasFeedback:!!a,feedbackIcon:t,isFormItemInput:!0};return d&&(c.status=(null!=p?p:h)||"",c.isFormItemInput=g,c.hasFeedback=!!(null!=a?a:b),c.feedbackIcon=void 0!==a?c.feedbackIcon:v),c},[p,a,d,g,h]);return o.createElement(f.aM.Provider,{value:x},t)}var X=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)0>t.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};function G(e){let{prefixCls:t,className:n,rootClassName:r,style:a,help:c,errors:i,warnings:s,validateStatus:d,meta:u,hasFeedback:m,hidden:p,children:g,fieldId:h,required:b,isRequired:v,onSubItemMetaChange:k}=e,O=X(e,["prefixCls","className","rootClassName","style","help","errors","warnings","validateStatus","meta","hasFeedback","hidden","children","fieldId","required","isRequired","onSubItemMetaChange"]),j="".concat(t,"-item"),{requiredMark:S}=o.useContext(f.q3),M=o.useRef(null),N=(0,H.Z)(i),Z=(0,H.Z)(s),q=null!=c,F=!!(q||i.length||s.length),P=!!M.current&&(0,x.Z)(M.current),[L,R]=o.useState(null);(0,w.Z)(()=>{F&&M.current&&R(parseInt(getComputedStyle(M.current).marginBottom,10))},[F,P]);let _=function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=e?N:u.errors,n=e?Z:u.warnings;return(0,y.lR)(t,n,u,"",!!m,d)}(),W=l()(j,n,r,{["".concat(j,"-with-help")]:q||N.length||Z.length,["".concat(j,"-has-feedback")]:_&&m,["".concat(j,"-has-success")]:"success"===_,["".concat(j,"-has-warning")]:"warning"===_,["".concat(j,"-has-error")]:"error"===_,["".concat(j,"-is-validating")]:"validating"===_,["".concat(j,"-hidden")]:p});return o.createElement("div",{className:W,style:a,ref:M},o.createElement(E.Z,Object.assign({className:"".concat(j,"-row")},(0,C.Z)(O,["_internalItemRender","colon","dependencies","extra","fieldKey","getValueFromEvent","getValueProps","htmlFor","id","initialValue","isListField","label","labelAlign","labelCol","labelWrap","messageVariables","name","normalize","noStyle","preserve","requiredMark","rules","shouldUpdate","trigger","tooltip","validateFirst","validateTrigger","valuePropName","wrapperCol","validateDebounce"])),o.createElement(T,Object.assign({htmlFor:h},e,{requiredMark:S,required:null!=b?b:v,prefixCls:t})),o.createElement(I,Object.assign({},e,u,{errors:N,warnings:Z,prefixCls:t,status:_,help:c,marginBottom:L,onErrorVisibleChanged:e=>{e||R(null)}}),o.createElement(f.qI.Provider,{value:k},o.createElement(B,{prefixCls:t,meta:u,errors:u.errors,warnings:u.warnings,hasFeedback:m,validateStatus:_},g)))),!!L&&o.createElement("div",{className:"".concat(j,"-margin-offset"),style:{marginBottom:-L}}))}let $=o.memo(e=>{let{children:t}=e;return t},(e,t)=>(function(e,t){let n=Object.keys(e),r=Object.keys(t);return n.length===r.length&&n.every(n=>{let r=e[n],o=t[n];return r===o||"function"==typeof r||"function"==typeof o})})(e.control,t.control)&&e.update===t.update&&e.childProps.length===t.childProps.length&&e.childProps.every((e,n)=>e===t.childProps[n]));function U(){return{errors:[],warnings:[],touched:!1,validating:!1,name:[],validated:!1}}let K=function(e){let{name:t,noStyle:n,className:a,dependencies:h,prefixCls:x,shouldUpdate:w,rules:C,children:E,required:k,label:O,messageVariables:j,trigger:S="onChange",validateTrigger:M,hidden:I,help:N}=e,{getPrefixCls:Z}=o.useContext(m.E_),{name:q}=o.useContext(f.q3),F=function(e){if("function"==typeof e)return e;let t=(0,g.Z)(e);return t.length<=1?t[0]:t}(E),P="function"==typeof F,L=o.useContext(f.qI),{validateTrigger:R}=o.useContext(c.zb),_=void 0!==M?M:R,T=null!=t,H=Z("form",x),W=(0,p.Z)(H),[V,z,D]=(0,v.ZP)(H,W);(0,u.ln)("Form.Item");let A=o.useContext(c.ZM),X=o.useRef(),[K,Y]=function(e){let[t,n]=o.useState(e),r=(0,o.useRef)(null),a=(0,o.useRef)([]),l=(0,o.useRef)(!1);return o.useEffect(()=>(l.current=!1,()=>{l.current=!0,b.Z.cancel(r.current),r.current=null}),[]),[t,function(e){l.current||(null===r.current&&(a.current=[],r.current=(0,b.Z)(()=>{r.current=null,n(e=>{let t=e;return a.current.forEach(e=>{t=e(t)}),t})})),a.current.push(e))}]}({}),[J,Q]=(0,i.Z)(()=>U()),ee=(e,t)=>{Y(n=>{let o=Object.assign({},n),a=[].concat((0,r.Z)(e.name.slice(0,-1)),(0,r.Z)(t)).join("__SPLIT__");return e.destroy?delete o[a]:o[a]=e,o})},[et,en]=o.useMemo(()=>{let e=(0,r.Z)(J.errors),t=(0,r.Z)(J.warnings);return Object.values(K).forEach(n=>{e.push.apply(e,(0,r.Z)(n.errors||[])),t.push.apply(t,(0,r.Z)(n.warnings||[]))}),[e,t]},[K,J.errors,J.warnings]),er=function(){let{itemRef:e}=o.useContext(f.q3),t=o.useRef({});return function(n,r){let o=r&&"object"==typeof r&&r.ref,a=n.join("_");return(t.current.name!==a||t.current.originRef!==o)&&(t.current.name=a,t.current.originRef=o,t.current.ref=(0,s.sQ)(e(n),o)),t.current.ref}}();function eo(t,r,c){return n&&!I?o.createElement(B,{prefixCls:H,hasFeedback:e.hasFeedback,validateStatus:e.validateStatus,meta:J,errors:et,warnings:en,noStyle:!0},t):o.createElement(G,Object.assign({key:"row"},e,{className:l()(a,D,W,z),prefixCls:H,fieldId:r,isRequired:c,errors:et,warnings:en,meta:J,onSubItemMetaChange:ee}),t)}if(!T&&!P&&!h)return V(eo(F));let ea={};return"string"==typeof O?ea.label=O:t&&(ea.label=String(t)),j&&(ea=Object.assign(Object.assign({},ea),j)),V(o.createElement(c.gN,Object.assign({},e,{messageVariables:ea,trigger:S,validateTrigger:_,onMetaChange:e=>{let t=null==A?void 0:A.getKey(e.name);if(Q(e.destroy?U():e,!0),n&&!1!==N&&L){let n=e.name;if(e.destroy)n=X.current||n;else if(void 0!==t){let[e,o]=t;n=[e].concat((0,r.Z)(o)),X.current=n}L(e,n)}}}),(n,a,l)=>{let c=(0,y.qo)(t).length&&a?a.name:[],i=(0,y.dD)(c,q),u=void 0!==k?k:!!(C&&C.some(e=>{if(e&&"object"==typeof e&&e.required&&!e.warningOnly)return!0;if("function"==typeof e){let t=e(l);return t&&t.required&&!t.warningOnly}return!1})),m=Object.assign({},n),p=null;if(Array.isArray(F)&&T)p=F;else if(P&&(!(w||h)||T));else if(!h||P||T){if((0,d.l$)(F)){let t=Object.assign(Object.assign({},F.props),m);if(t.id||(t.id=i),N||et.length>0||en.length>0||e.extra){let n=[];(N||et.length>0)&&n.push("".concat(i,"_help")),e.extra&&n.push("".concat(i,"_extra")),t["aria-describedby"]=n.join(" ")}et.length>0&&(t["aria-invalid"]="true"),u&&(t["aria-required"]="true"),(0,s.Yr)(F)&&(t.ref=er(c,F)),new Set([].concat((0,r.Z)((0,y.qo)(S)),(0,r.Z)((0,y.qo)(_)))).forEach(e=>{t[e]=function(){for(var t,n,r,o=arguments.length,a=Array(o),l=0;l<o;l++)a[l]=arguments[l];null===(t=m[e])||void 0===t||t.call.apply(t,[m].concat(a)),null===(r=(n=F.props)[e])||void 0===r||r.call.apply(r,[n].concat(a))}});let n=[t["aria-required"],t["aria-invalid"],t["aria-describedby"]];p=o.createElement($,{control:m,update:F,childProps:n},(0,d.Tm)(F,t))}else p=P&&(w||h)&&!T?F(l):F}return eo(p,i,u)}))};K.useStatus=h;var Y=K},4064:function(e,t,n){n.d(t,{Z:function(){return o}});var r=n(2265);function o(e){let[t,n]=r.useState(e);return r.useEffect(()=>{let t=setTimeout(()=>{n(e)},e.length?0:10);return()=>{clearTimeout(t)}},[e]),t}},13634:function(e,t,n){n.d(t,{Z:function(){return N}});var r=n(14605),o=n(2265),a=n(36760),l=n.n(a),c=n(64834),i=n(71744),s=n(86586),d=n(64024),u=n(33759),m=n(59189),p=n(39109);let f=e=>"object"==typeof e&&null!=e&&1===e.nodeType,g=(e,t)=>(!t||"hidden"!==e)&&"visible"!==e&&"clip"!==e,h=(e,t)=>{if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){let n=getComputedStyle(e,null);return g(n.overflowY,t)||g(n.overflowX,t)||(e=>{let t=(e=>{if(!e.ownerDocument||!e.ownerDocument.defaultView)return null;try{return e.ownerDocument.defaultView.frameElement}catch(e){return null}})(e);return!!t&&(t.clientHeight<e.scrollHeight||t.clientWidth<e.scrollWidth)})(e)}return!1},b=(e,t,n,r,o,a,l,c)=>a<e&&l>t||a>e&&l<t?0:a<=e&&c<=n||l>=t&&c>=n?a-e-r:l>t&&c<n||a<e&&c>n?l-t+o:0,v=e=>{let t=e.parentElement;return null==t?e.getRootNode().host||null:t},y=(e,t)=>{var n,r,o,a;if("undefined"==typeof document)return[];let{scrollMode:l,block:c,inline:i,boundary:s,skipOverflowHiddenElements:d}=t,u="function"==typeof s?s:e=>e!==s;if(!f(e))throw TypeError("Invalid target");let m=document.scrollingElement||document.documentElement,p=[],g=e;for(;f(g)&&u(g);){if((g=v(g))===m){p.push(g);break}null!=g&&g===document.body&&h(g)&&!h(document.documentElement)||null!=g&&h(g,d)&&p.push(g)}let y=null!=(r=null==(n=window.visualViewport)?void 0:n.width)?r:innerWidth,x=null!=(a=null==(o=window.visualViewport)?void 0:o.height)?a:innerHeight,{scrollX:w,scrollY:C}=window,{height:E,width:k,top:O,right:j,bottom:S,left:M}=e.getBoundingClientRect(),{top:I,right:N,bottom:Z,left:q}=(e=>{let t=window.getComputedStyle(e);return{top:parseFloat(t.scrollMarginTop)||0,right:parseFloat(t.scrollMarginRight)||0,bottom:parseFloat(t.scrollMarginBottom)||0,left:parseFloat(t.scrollMarginLeft)||0}})(e),F="start"===c||"nearest"===c?O-I:"end"===c?S+Z:O+E/2-I+Z,P="center"===i?M+k/2-q+N:"end"===i?j+N:M-q,L=[];for(let e=0;e<p.length;e++){let t=p[e],{height:n,width:r,top:o,right:a,bottom:s,left:d}=t.getBoundingClientRect();if("if-needed"===l&&O>=0&&M>=0&&S<=x&&j<=y&&O>=o&&S<=s&&M>=d&&j<=a)break;let u=getComputedStyle(t),f=parseInt(u.borderLeftWidth,10),g=parseInt(u.borderTopWidth,10),h=parseInt(u.borderRightWidth,10),v=parseInt(u.borderBottomWidth,10),I=0,N=0,Z="offsetWidth"in t?t.offsetWidth-t.clientWidth-f-h:0,q="offsetHeight"in t?t.offsetHeight-t.clientHeight-g-v:0,R="offsetWidth"in t?0===t.offsetWidth?0:r/t.offsetWidth:0,_="offsetHeight"in t?0===t.offsetHeight?0:n/t.offsetHeight:0;if(m===t)I="start"===c?F:"end"===c?F-x:"nearest"===c?b(C,C+x,x,g,v,C+F,C+F+E,E):F-x/2,N="start"===i?P:"center"===i?P-y/2:"end"===i?P-y:b(w,w+y,y,f,h,w+P,w+P+k,k),I=Math.max(0,I+C),N=Math.max(0,N+w);else{I="start"===c?F-o-g:"end"===c?F-s+v+q:"nearest"===c?b(o,s,n,g,v+q,F,F+E,E):F-(o+n/2)+q/2,N="start"===i?P-d-f:"center"===i?P-(d+r/2)+Z/2:"end"===i?P-a+h+Z:b(d,a,r,f,h+Z,P,P+k,k);let{scrollLeft:e,scrollTop:l}=t;I=0===_?0:Math.max(0,Math.min(l+I/_,t.scrollHeight-n/_+q)),N=0===R?0:Math.max(0,Math.min(e+N/R,t.scrollWidth-r/R+Z)),F+=l-I,P+=e-N}L.push({el:t,top:I,left:N})}return L},x=e=>!1===e?{block:"end",inline:"nearest"}:e===Object(e)&&0!==Object.keys(e).length?e:{block:"start",inline:"nearest"};var w=n(13861);function C(e){return(0,w.qo)(e).join("_")}function E(e){let[t]=(0,c.cI)(),n=o.useRef({}),r=o.useMemo(()=>null!=e?e:Object.assign(Object.assign({},t),{__INTERNAL__:{itemRef:e=>t=>{let r=C(e);t?n.current[r]=t:delete n.current[r]}},scrollToField:function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=(0,w.qo)(e),o=(0,w.dD)(n,r.__INTERNAL__.name),a=o?document.getElementById(o):null;a&&function(e,t){if(!e.isConnected||!(e=>{let t=e;for(;t&&t.parentNode;){if(t.parentNode===document)return!0;t=t.parentNode instanceof ShadowRoot?t.parentNode.host:t.parentNode}return!1})(e))return;let n=(e=>{let t=window.getComputedStyle(e);return{top:parseFloat(t.scrollMarginTop)||0,right:parseFloat(t.scrollMarginRight)||0,bottom:parseFloat(t.scrollMarginBottom)||0,left:parseFloat(t.scrollMarginLeft)||0}})(e);if("object"==typeof t&&"function"==typeof t.behavior)return t.behavior(y(e,t));let r="boolean"==typeof t||null==t?void 0:t.behavior;for(let{el:o,top:a,left:l}of y(e,x(t))){let e=a-n.top+n.bottom,t=l-n.left+n.right;o.scroll({top:e,left:t,behavior:r})}}(a,Object.assign({scrollMode:"if-needed",block:"nearest"},t))},getFieldInstance:e=>{let t=C(e);return n.current[t]}}),[e,t]);return[r]}var k=n(47713),O=n(77360),j=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)0>t.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let S=o.forwardRef((e,t)=>{let n=o.useContext(s.Z),{getPrefixCls:r,direction:a,form:f}=o.useContext(i.E_),{prefixCls:g,className:h,rootClassName:b,size:v,disabled:y=n,form:x,colon:w,labelAlign:C,labelWrap:S,labelCol:M,wrapperCol:I,hideRequiredMark:N,layout:Z="horizontal",scrollToFirstError:q,requiredMark:F,onFinishFailed:P,name:L,style:R,feedbackIcons:_,variant:T}=e,H=j(e,["prefixCls","className","rootClassName","size","disabled","form","colon","labelAlign","labelWrap","labelCol","wrapperCol","hideRequiredMark","layout","scrollToFirstError","requiredMark","onFinishFailed","name","style","feedbackIcons","variant"]),W=(0,u.Z)(v),V=o.useContext(O.Z),z=(0,o.useMemo)(()=>void 0!==F?F:!N&&(!f||void 0===f.requiredMark||f.requiredMark),[N,F,f]),D=null!=w?w:null==f?void 0:f.colon,A=r("form",g),B=(0,d.Z)(A),[X,G,$]=(0,k.ZP)(A,B),U=l()(A,"".concat(A,"-").concat(Z),{["".concat(A,"-hide-required-mark")]:!1===z,["".concat(A,"-rtl")]:"rtl"===a,["".concat(A,"-").concat(W)]:W},$,B,G,null==f?void 0:f.className,h,b),[K]=E(x),{__INTERNAL__:Y}=K;Y.name=L;let J=(0,o.useMemo)(()=>({name:L,labelAlign:C,labelCol:M,labelWrap:S,wrapperCol:I,vertical:"vertical"===Z,colon:D,requiredMark:z,itemRef:Y.itemRef,form:K,feedbackIcons:_}),[L,C,M,I,Z,D,z,K,_]);o.useImperativeHandle(t,()=>K);let Q=(e,t)=>{if(e){let n={block:"nearest"};"object"==typeof e&&(n=e),K.scrollToField(t,n)}};return X(o.createElement(p.pg.Provider,{value:T},o.createElement(s.n,{disabled:y},o.createElement(m.Z.Provider,{value:W},o.createElement(p.RV,{validateMessages:V},o.createElement(p.q3.Provider,{value:J},o.createElement(c.ZP,Object.assign({id:L},H,{name:L,onFinishFailed:e=>{if(null==P||P(e),e.errorFields.length){let t=e.errorFields[0].name;if(void 0!==q){Q(q,t);return}f&&void 0!==f.scrollToFirstError&&Q(f.scrollToFirstError,t)}},form:K,style:Object.assign(Object.assign({},null==f?void 0:f.style),R),className:U}))))))))});var M=n(86582),I=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)0>t.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};S.Item=M.Z,S.List=e=>{var{prefixCls:t,children:n}=e,r=I(e,["prefixCls","children"]);let{getPrefixCls:a}=o.useContext(i.E_),l=a("form",t),s=o.useMemo(()=>({prefixCls:l,status:"error"}),[l]);return o.createElement(c.aV,Object.assign({},r),(e,t,r)=>o.createElement(p.Rk.Provider,{value:s},n(e.map(e=>Object.assign(Object.assign({},e),{fieldKey:e.key})),t,{errors:r.errors,warnings:r.warnings})))},S.ErrorList=r.Z,S.useForm=E,S.useFormInstance=function(){let{form:e}=(0,o.useContext)(p.q3);return e},S.useWatch=c.qo,S.Provider=p.RV,S.create=()=>{};var N=S},47713:function(e,t,n){n.d(t,{ZP:function(){return x},B4:function(){return y}});var r=n(352),o=n(12918),a=n(691),l=n(63074),c=n(3104),i=n(80669),s=e=>{let{componentCls:t}=e,n="".concat(t,"-show-help"),r="".concat(t,"-show-help-item");return{[n]:{transition:"opacity ".concat(e.motionDurationSlow," ").concat(e.motionEaseInOut),"&-appear, &-enter":{opacity:0,"&-active":{opacity:1}},"&-leave":{opacity:1,"&-active":{opacity:0}},[r]:{overflow:"hidden",transition:"height ".concat(e.motionDurationSlow," ").concat(e.motionEaseInOut,",\n opacity ").concat(e.motionDurationSlow," ").concat(e.motionEaseInOut,",\n transform ").concat(e.motionDurationSlow," ").concat(e.motionEaseInOut," !important"),["&".concat(r,"-appear, &").concat(r,"-enter")]:{transform:"translateY(-5px)",opacity:0,"&-active":{transform:"translateY(0)",opacity:1}},["&".concat(r,"-leave-active")]:{transform:"translateY(-5px)"}}}}};let d=e=>({legend:{display:"block",width:"100%",marginBottom:e.marginLG,padding:0,color:e.colorTextDescription,fontSize:e.fontSizeLG,lineHeight:"inherit",border:0,borderBottom:"".concat((0,r.bf)(e.lineWidth)," ").concat(e.lineType," ").concat(e.colorBorder)},'input[type="search"]':{boxSizing:"border-box"},'input[type="radio"], input[type="checkbox"]':{lineHeight:"normal"},'input[type="file"]':{display:"block"},'input[type="range"]':{display:"block",width:"100%"},"select[multiple], select[size]":{height:"auto"},"input[type='file']:focus,\n input[type='radio']:focus,\n input[type='checkbox']:focus":{outline:0,boxShadow:"0 0 0 ".concat((0,r.bf)(e.controlOutlineWidth)," ").concat(e.controlOutline)},output:{display:"block",paddingTop:15,color:e.colorText,fontSize:e.fontSize,lineHeight:e.lineHeight}}),u=(e,t)=>{let{formItemCls:n}=e;return{[n]:{["".concat(n,"-label > label")]:{height:t},["".concat(n,"-control-input")]:{minHeight:t}}}},m=e=>{let{componentCls:t}=e;return{[e.componentCls]:Object.assign(Object.assign(Object.assign({},(0,o.Wf)(e)),d(e)),{["".concat(t,"-text")]:{display:"inline-block",paddingInlineEnd:e.paddingSM},"&-small":Object.assign({},u(e,e.controlHeightSM)),"&-large":Object.assign({},u(e,e.controlHeightLG))})}},p=e=>{let{formItemCls:t,iconCls:n,componentCls:r,rootPrefixCls:l,labelRequiredMarkColor:c,labelColor:i,labelFontSize:s,labelHeight:d,labelColonMarginInlineStart:u,labelColonMarginInlineEnd:m,itemMarginBottom:p}=e;return{[t]:Object.assign(Object.assign({},(0,o.Wf)(e)),{marginBottom:p,verticalAlign:"top","&-with-help":{transition:"none"},["&-hidden,\n &-hidden.".concat(l,"-row")]:{display:"none"},"&-has-warning":{["".concat(t,"-split")]:{color:e.colorError}},"&-has-error":{["".concat(t,"-split")]:{color:e.colorWarning}},["".concat(t,"-label")]:{flexGrow:0,overflow:"hidden",whiteSpace:"nowrap",textAlign:"end",verticalAlign:"middle","&-left":{textAlign:"start"},"&-wrap":{overflow:"unset",lineHeight:e.lineHeight,whiteSpace:"unset"},"> label":{position:"relative",display:"inline-flex",alignItems:"center",maxWidth:"100%",height:d,color:i,fontSize:s,["> ".concat(n)]:{fontSize:e.fontSize,verticalAlign:"top"},["&".concat(t,"-required:not(").concat(t,"-required-mark-optional)::before")]:{display:"inline-block",marginInlineEnd:e.marginXXS,color:c,fontSize:e.fontSize,fontFamily:"SimSun, sans-serif",lineHeight:1,content:'"*"',["".concat(r,"-hide-required-mark &")]:{display:"none"}},["".concat(t,"-optional")]:{display:"inline-block",marginInlineStart:e.marginXXS,color:e.colorTextDescription,["".concat(r,"-hide-required-mark &")]:{display:"none"}},["".concat(t,"-tooltip")]:{color:e.colorTextDescription,cursor:"help",writingMode:"horizontal-tb",marginInlineStart:e.marginXXS},"&::after":{content:'":"',position:"relative",marginBlock:0,marginInlineStart:u,marginInlineEnd:m},["&".concat(t,"-no-colon::after")]:{content:'"\\a0"'}}},["".concat(t,"-control")]:{"--ant-display":"flex",flexDirection:"column",flexGrow:1,["&:first-child:not([class^=\"'".concat(l,"-col-'\"]):not([class*=\"' ").concat(l,"-col-'\"])")]:{width:"100%"},"&-input":{position:"relative",display:"flex",alignItems:"center",minHeight:e.controlHeight,"&-content":{flex:"auto",maxWidth:"100%"}}},[t]:{"&-explain, &-extra":{clear:"both",color:e.colorTextDescription,fontSize:e.fontSize,lineHeight:e.lineHeight},"&-explain-connected":{width:"100%"},"&-extra":{minHeight:e.controlHeightSM,transition:"color ".concat(e.motionDurationMid," ").concat(e.motionEaseOut)},"&-explain":{"&-error":{color:e.colorError},"&-warning":{color:e.colorWarning}}},["&-with-help ".concat(t,"-explain")]:{height:"auto",opacity:1},["".concat(t,"-feedback-icon")]:{fontSize:e.fontSize,textAlign:"center",visibility:"visible",animationName:a.kr,animationDuration:e.motionDurationMid,animationTimingFunction:e.motionEaseOutBack,pointerEvents:"none","&-success":{color:e.colorSuccess},"&-error":{color:e.colorError},"&-warning":{color:e.colorWarning},"&-validating":{color:e.colorPrimary}}})}},f=e=>{let{componentCls:t,formItemCls:n}=e;return{["".concat(t,"-horizontal")]:{["".concat(n,"-label")]:{flexGrow:0},["".concat(n,"-control")]:{flex:"1 1 0",minWidth:0},["".concat(n,"-label[class$='-24'], ").concat(n,"-label[class*='-24 ']")]:{["& + ".concat(n,"-control")]:{minWidth:"unset"}}}}},g=e=>{let{componentCls:t,formItemCls:n}=e;return{["".concat(t,"-inline")]:{display:"flex",flexWrap:"wrap",[n]:{flex:"none",marginInlineEnd:e.margin,marginBottom:0,"&-row":{flexWrap:"nowrap"},["> ".concat(n,"-label,\n > ").concat(n,"-control")]:{display:"inline-block",verticalAlign:"top"},["> ".concat(n,"-label")]:{flex:"none"},["".concat(t,"-text")]:{display:"inline-block"},["".concat(n,"-has-feedback")]:{display:"inline-block"}}}}},h=e=>({padding:e.verticalLabelPadding,margin:e.verticalLabelMargin,whiteSpace:"initial",textAlign:"start","> label":{margin:0,"&::after":{visibility:"hidden"}}}),b=e=>{let{componentCls:t,formItemCls:n,rootPrefixCls:r}=e;return{["".concat(n," ").concat(n,"-label")]:h(e),["".concat(t,":not(").concat(t,"-inline)")]:{[n]:{flexWrap:"wrap",["".concat(n,"-label, ").concat(n,"-control")]:{['&:not([class*=" '.concat(r,'-col-xs"])')]:{flex:"0 0 100%",maxWidth:"100%"}}}}}},v=e=>{let{componentCls:t,formItemCls:n,rootPrefixCls:o}=e;return{["".concat(t,"-vertical")]:{[n]:{"&-row":{flexDirection:"column"},"&-label > label":{height:"auto"},["".concat(t,"-item-control")]:{width:"100%"}}},["".concat(t,"-vertical ").concat(n,"-label,\n .").concat(o,"-col-24").concat(n,"-label,\n .").concat(o,"-col-xl-24").concat(n,"-label")]:h(e),["@media (max-width: ".concat((0,r.bf)(e.screenXSMax),")")]:[b(e),{[t]:{[".".concat(o,"-col-xs-24").concat(n,"-label")]:h(e)}}],["@media (max-width: ".concat((0,r.bf)(e.screenSMMax),")")]:{[t]:{[".".concat(o,"-col-sm-24").concat(n,"-label")]:h(e)}},["@media (max-width: ".concat((0,r.bf)(e.screenMDMax),")")]:{[t]:{[".".concat(o,"-col-md-24").concat(n,"-label")]:h(e)}},["@media (max-width: ".concat((0,r.bf)(e.screenLGMax),")")]:{[t]:{[".".concat(o,"-col-lg-24").concat(n,"-label")]:h(e)}}}},y=(e,t)=>(0,c.TS)(e,{formItemCls:"".concat(e.componentCls,"-item"),rootPrefixCls:t});var x=(0,i.I$)("Form",(e,t)=>{let{rootPrefixCls:n}=t,r=y(e,n);return[m(r),p(r),s(r),f(r),g(r),v(r),(0,l.Z)(r),a.kr]},e=>({labelRequiredMarkColor:e.colorError,labelColor:e.colorTextHeading,labelFontSize:e.fontSize,labelHeight:e.controlHeight,labelColonMarginInlineStart:e.marginXXS/2,labelColonMarginInlineEnd:e.marginXS,itemMarginBottom:e.marginLG,verticalLabelPadding:"0 0 ".concat(e.paddingXS,"px"),verticalLabelMargin:0}),{order:-1e3})},13861:function(e,t,n){n.d(t,{dD:function(){return a},lR:function(){return l},qo:function(){return o}});let r=["parentNode"];function o(e){return void 0===e||!1===e?[]:Array.isArray(e)?e:[e]}function a(e,t){if(!e.length)return;let n=e.join("_");return t?"".concat(t,"_").concat(n):r.includes(n)?"".concat("form_item","_").concat(n):n}function l(e,t,n,r,o,a){let l=r;return void 0!==a?l=a:n.validating?l="validating":e.length?l="error":t.length?l="warning":(n.touched||o&&n.validated)&&(l="success"),l}},62807:function(e,t,n){let r=(0,n(2265).createContext)({});t.Z=r},54998:function(e,t,n){var r=n(2265),o=n(36760),a=n.n(o),l=n(71744),c=n(62807),i=n(96776),s=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)0>t.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let d=["xs","sm","md","lg","xl","xxl"],u=r.forwardRef((e,t)=>{let{getPrefixCls:n,direction:o}=r.useContext(l.E_),{gutter:u,wrap:m}=r.useContext(c.Z),{prefixCls:p,span:f,order:g,offset:h,push:b,pull:v,className:y,children:x,flex:w,style:C}=e,E=s(e,["prefixCls","span","order","offset","push","pull","className","children","flex","style"]),k=n("col",p),[O,j,S]=(0,i.cG)(k),M={};d.forEach(t=>{let n={},r=e[t];"number"==typeof r?n.span=r:"object"==typeof r&&(n=r||{}),delete E[t],M=Object.assign(Object.assign({},M),{["".concat(k,"-").concat(t,"-").concat(n.span)]:void 0!==n.span,["".concat(k,"-").concat(t,"-order-").concat(n.order)]:n.order||0===n.order,["".concat(k,"-").concat(t,"-offset-").concat(n.offset)]:n.offset||0===n.offset,["".concat(k,"-").concat(t,"-push-").concat(n.push)]:n.push||0===n.push,["".concat(k,"-").concat(t,"-pull-").concat(n.pull)]:n.pull||0===n.pull,["".concat(k,"-").concat(t,"-flex-").concat(n.flex)]:n.flex||"auto"===n.flex,["".concat(k,"-rtl")]:"rtl"===o})});let I=a()(k,{["".concat(k,"-").concat(f)]:void 0!==f,["".concat(k,"-order-").concat(g)]:g,["".concat(k,"-offset-").concat(h)]:h,["".concat(k,"-push-").concat(b)]:b,["".concat(k,"-pull-").concat(v)]:v},y,M,j,S),N={};if(u&&u[0]>0){let e=u[0]/2;N.paddingLeft=e,N.paddingRight=e}return w&&(N.flex="number"==typeof w?"".concat(w," ").concat(w," auto"):/^\d+(\.\d+)?(px|em|rem|%)$/.test(w)?"0 0 ".concat(w):w,!1!==m||N.minWidth||(N.minWidth=0)),O(r.createElement("div",Object.assign({},E,{style:Object.assign(Object.assign({},N),C),className:I,ref:t}),x))});t.Z=u},10295:function(e,t,n){var r=n(2265),o=n(36760),a=n.n(o),l=n(6543),c=n(71744),i=n(62807),s=n(96776),d=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)0>t.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};function u(e,t){let[n,o]=r.useState("string"==typeof e?e:""),a=()=>{if("string"==typeof e&&o(e),"object"==typeof e)for(let n=0;n<l.c4.length;n++){let r=l.c4[n];if(!t[r])continue;let a=e[r];if(void 0!==a){o(a);return}}};return r.useEffect(()=>{a()},[JSON.stringify(e),t]),n}let m=r.forwardRef((e,t)=>{let{prefixCls:n,justify:o,align:m,className:p,style:f,children:g,gutter:h=0,wrap:b}=e,v=d(e,["prefixCls","justify","align","className","style","children","gutter","wrap"]),{getPrefixCls:y,direction:x}=r.useContext(c.E_),[w,C]=r.useState({xs:!0,sm:!0,md:!0,lg:!0,xl:!0,xxl:!0}),[E,k]=r.useState({xs:!1,sm:!1,md:!1,lg:!1,xl:!1,xxl:!1}),O=u(m,E),j=u(o,E),S=r.useRef(h),M=(0,l.ZP)();r.useEffect(()=>{let e=M.subscribe(e=>{k(e);let t=S.current||0;(!Array.isArray(t)&&"object"==typeof t||Array.isArray(t)&&("object"==typeof t[0]||"object"==typeof t[1]))&&C(e)});return()=>M.unsubscribe(e)},[]);let I=y("row",n),[N,Z,q]=(0,s.VM)(I),F=(()=>{let e=[void 0,void 0];return(Array.isArray(h)?h:[h,void 0]).forEach((t,n)=>{if("object"==typeof t)for(let r=0;r<l.c4.length;r++){let o=l.c4[r];if(w[o]&&void 0!==t[o]){e[n]=t[o];break}}else e[n]=t}),e})(),P=a()(I,{["".concat(I,"-no-wrap")]:!1===b,["".concat(I,"-").concat(j)]:j,["".concat(I,"-").concat(O)]:O,["".concat(I,"-rtl")]:"rtl"===x},p,Z,q),L={},R=null!=F[0]&&F[0]>0?-(F[0]/2):void 0;R&&(L.marginLeft=R,L.marginRight=R),[,L.rowGap]=F;let[_,T]=F,H=r.useMemo(()=>({gutter:[_,T],wrap:b}),[_,T,b]);return N(r.createElement(i.Z.Provider,{value:H},r.createElement("div",Object.assign({},v,{className:P,style:Object.assign(Object.assign({},L),f),ref:t}),g)))});t.Z=m},96776:function(e,t,n){n.d(t,{VM:function(){return d},cG:function(){return u}});var r=n(352),o=n(80669),a=n(3104);let l=e=>{let{componentCls:t}=e;return{[t]:{position:"relative",maxWidth:"100%",minHeight:1}}},c=(e,t)=>{let{componentCls:n,gridColumns:r}=e,o={};for(let e=r;e>=0;e--)0===e?(o["".concat(n).concat(t,"-").concat(e)]={display:"none"},o["".concat(n,"-push-").concat(e)]={insetInlineStart:"auto"},o["".concat(n,"-pull-").concat(e)]={insetInlineEnd:"auto"},o["".concat(n).concat(t,"-push-").concat(e)]={insetInlineStart:"auto"},o["".concat(n).concat(t,"-pull-").concat(e)]={insetInlineEnd:"auto"},o["".concat(n).concat(t,"-offset-").concat(e)]={marginInlineStart:0},o["".concat(n).concat(t,"-order-").concat(e)]={order:0}):(o["".concat(n).concat(t,"-").concat(e)]=[{"--ant-display":"block",display:"block"},{display:"var(--ant-display)",flex:"0 0 ".concat(e/r*100,"%"),maxWidth:"".concat(e/r*100,"%")}],o["".concat(n).concat(t,"-push-").concat(e)]={insetInlineStart:"".concat(e/r*100,"%")},o["".concat(n).concat(t,"-pull-").concat(e)]={insetInlineEnd:"".concat(e/r*100,"%")},o["".concat(n).concat(t,"-offset-").concat(e)]={marginInlineStart:"".concat(e/r*100,"%")},o["".concat(n).concat(t,"-order-").concat(e)]={order:e});return o},i=(e,t)=>c(e,t),s=(e,t,n)=>({["@media (min-width: ".concat((0,r.bf)(t),")")]:Object.assign({},i(e,n))}),d=(0,o.I$)("Grid",e=>{let{componentCls:t}=e;return{[t]:{display:"flex",flexFlow:"row wrap",minWidth:0,"&::before, &::after":{display:"flex"},"&-no-wrap":{flexWrap:"nowrap"},"&-start":{justifyContent:"flex-start"},"&-center":{justifyContent:"center"},"&-end":{justifyContent:"flex-end"},"&-space-between":{justifyContent:"space-between"},"&-space-around":{justifyContent:"space-around"},"&-space-evenly":{justifyContent:"space-evenly"},"&-top":{alignItems:"flex-start"},"&-middle":{alignItems:"center"},"&-bottom":{alignItems:"flex-end"}}}},()=>({})),u=(0,o.I$)("Grid",e=>{let t=(0,a.TS)(e,{gridColumns:24}),n={"-sm":t.screenSMMin,"-md":t.screenMDMin,"-lg":t.screenLGMin,"-xl":t.screenXLMin,"-xxl":t.screenXXLMin};return[l(t),i(t,""),i(t,"-xs"),Object.keys(n).map(e=>s(t,n[e],e)).reduce((e,t)=>Object.assign(Object.assign({},e),t),{})]},()=>({}))},63074:function(e,t){t.Z=e=>({[e.componentCls]:{["".concat(e.antCls,"-motion-collapse-legacy")]:{overflow:"hidden","&-active":{transition:"height ".concat(e.motionDurationMid," ").concat(e.motionEaseInOut,",\n opacity ").concat(e.motionDurationMid," ").concat(e.motionEaseInOut," !important")}},["".concat(e.antCls,"-motion-collapse")]:{overflow:"hidden",transition:"height ".concat(e.motionDurationMid," ").concat(e.motionEaseInOut,",\n opacity ").concat(e.motionDurationMid," ").concat(e.motionEaseInOut," !important")}}})},14474:function(e,t,n){n.d(t,{o:function(){return o}});class r extends Error{}function o(e,t){let n;if("string"!=typeof e)throw new r("Invalid token specified: must be a string");t||(t={});let o=!0===t.header?0:1,a=e.split(".")[o];if("string"!=typeof a)throw new r(`Invalid token specified: missing part #${o+1}`);try{n=function(e){let t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw Error("base64 string is not of the correct length")}try{var n;return n=t,decodeURIComponent(atob(n).replace(/(.)/g,(e,t)=>{let n=t.charCodeAt(0).toString(16).toUpperCase();return n.length<2&&(n="0"+n),"%"+n}))}catch(e){return atob(t)}}(a)}catch(e){throw new r(`Invalid token specified: invalid base64 for part #${o+1} (${e.message})`)}try{return JSON.parse(n)}catch(e){throw new r(`Invalid token specified: invalid json for part #${o+1} (${e.message})`)}}r.prototype.name="InvalidTokenError"}}]);
ui/litellm-dashboard/out/_next/static/chunks/app/_not-found/page-3b0daafcbe368586.js ADDED
@@ -0,0 +1 @@
 
 
1
+ (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[409],{67589:function(e,t,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/_not-found/page",function(){return n(83634)}])},83634:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return s}}),n(47043);let i=n(57437);n(2265);let o={fontFamily:'system-ui,"Segoe UI",Roboto,Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"',height:"100vh",textAlign:"center",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center"},l={display:"inline-block"},r={display:"inline-block",margin:"0 20px 0 0",padding:"0 23px 0 0",fontSize:24,fontWeight:500,verticalAlign:"top",lineHeight:"49px"},d={fontSize:14,fontWeight:400,lineHeight:"49px",margin:0};function s(){return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("title",{children:"404: This page could not be found."}),(0,i.jsx)("div",{style:o,children:(0,i.jsxs)("div",{children:[(0,i.jsx)("style",{dangerouslySetInnerHTML:{__html:"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}),(0,i.jsx)("h1",{className:"next-error-h1",style:r,children:"404"}),(0,i.jsx)("div",{style:l,children:(0,i.jsx)("h2",{style:d,children:"This page could not be found."})})]})})]})}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)}},function(e){e.O(0,[971,117,744],function(){return e(e.s=67589)}),_N_E=e.O()}]);
ui/litellm-dashboard/out/_next/static/chunks/app/layout-af8319e6c59a08da.js ADDED
@@ -0,0 +1 @@
 
 
1
+ (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[185],{6580:function(n,e,t){Promise.resolve().then(t.t.bind(t,39974,23)),Promise.resolve().then(t.t.bind(t,2778,23))},2778:function(){},39974:function(n){n.exports={style:{fontFamily:"'__Inter_cf7686', '__Inter_Fallback_cf7686'",fontStyle:"normal"},className:"__className_cf7686"}}},function(n){n.O(0,[919,986,971,117,744],function(){return n(n.s=6580)}),_N_E=n.O()}]);