diff --git a/docs/cli/miactl/20_setup.md b/docs/cli/miactl/20_setup.md index 6e95c9818b..64dd3d1bf2 100644 --- a/docs/cli/miactl/20_setup.md +++ b/docs/cli/miactl/20_setup.md @@ -38,13 +38,13 @@ If you have [Golang] installed with a version >= 1.13 in your system and you hav install `miactl` like this: ```sh -go install github.com/mia-platform/miactl/cmd/miactl@v0.12.2 +go install github.com/mia-platform/miactl/cmd/miactl@v0.13.0 ``` Or like this if the `install` command is not available ```sh -go get -u github.com/mia-platform/miactl/cmd/miactl@0.12.2 +go get -u github.com/mia-platform/miactl/cmd/miactl@0.13.0 ``` #### Binary Download @@ -53,11 +53,11 @@ You can install `miactl` with the use of `curl` or `wget` and downloading the la choosing the correct platform and operating system: ```sh -curl -fsSL https://github.com/mia-platform/miactl/releases/download/v0.12.2/miactl-linux-amd64 -o /tmp/miactl +curl -fsSL https://github.com/mia-platform/miactl/releases/download/v0.13.0/miactl-linux-amd64 -o /tmp/miactl ``` ```sh -wget -q https://github.com/mia-platform/miactl/releases/download/v0.12.2/miactl-linux-amd64 -O /tmp/miactl +wget -q https://github.com/mia-platform/miactl/releases/download/v0.13.0/miactl-linux-amd64 -O /tmp/miactl ``` After you have downloaded the file you can validate it against the checksum you can find at this [url] running the @@ -85,7 +85,7 @@ sudo mv /tmp/miactl /usr/local/bin If you want to run the cli in its environment or you want to test the cli you can use the Docker image: ```sh -docker run ghcr.io/mia-platform/miactl:v0.12.2 miactl +docker run ghcr.io/mia-platform/miactl:v0.13.0 miactl ``` ### Windows @@ -184,7 +184,7 @@ only via APIs. [Homebrew]: https://brew.sh "The Missing Package Manager for macOS (or Linux)" [Golang]: https://go.dev "Build simple, secure, scalable systems with Go" -[url]: https://github.com/mia-platform/miactl/releases/download/v0.12.2/checksums.txt "miactl checksums" +[url]: https://github.com/mia-platform/miactl/releases/download/v0.13.0/checksums.txt "miactl checksums" [`bash-completion`]: https://github.com/scop/bash-completion "Programmable completion functions for bash" [`oh-my-zsh`]: https://ohmyz.sh "Oh My Zsh is a delightful, open source, community-driven framework for managing your Zsh configuration" diff --git a/docs/cli/miactl/30_commands.md b/docs/cli/miactl/30_commands.md index 4d94e2f9e5..fca6d862be 100644 --- a/docs/cli/miactl/30_commands.md +++ b/docs/cli/miactl/30_commands.md @@ -47,6 +47,7 @@ miactl context set CONTEXT [flags] Available flags for the command: +- `--auth-name`, to set the name of the authentication to use (discover more on the [dedicated documentation section](#auth)) - `--endpoint`, to set the Console endpoint - `--certificate-authority`, to provide the path to a custom CA certificate - `--insecure-skip-tls-verify`, to disallow the check the validity of the certificate of the remote endpoint @@ -54,6 +55,11 @@ Available flags for the command: - `--project-id`, to set the ID of the desired Project - `--environment`, to set the environment scope for the command + +:::warning +If you want to use `miactl` with a _Service Account_, **remember to specify** the `--auth-name` flag, otherwise _miactl_ will try to perform a _User Login_, opening the browser for authentication the user. +::: + ### use The `context use` subcommand allows you to select an existing context as the current one. @@ -566,6 +572,180 @@ Available flags for the command: - `--no-semver`, to force the deploy without `semver` - `--revision`, to specify the revision of the commit to deploy +## extensions + +The `extensions` command allows you to manage Company extensions. + +Available subcommands are the following ones: + +```sh + list List registered extensions + apply Create or update an extension + activate Activate an extension + deactivate Deactivate an extension + delete Delete extension +``` + +### list + +The `extensions list` command helps you gathering available extension in your Company + +Usage: + +```sh +miactl extensions list [flags] +``` + +Available flags for the command: + +- `--company-id` to set the ID of the desired Company + +### apply + +The `extensions apply` command can be used to register new extensions or update an existing one. + +It accepts an Extension Manifest either in `yaml` or `json` format + +
+Example JSON Manifest + +```json +{ + "name": "Extension 1", + "description": "My extension 1", + "entry": "https://example.com/", + "contexts": [ + "project" + ], + "routes": [ + { + "id": "extension-1", + "parentId": "workloads", + "locationId": "runtime", + "renderType": "menu", + "labelIntl": { + "en": "SomeLabel", + "it": "SomeLabelInItalian" + }, + "destinationPath": "/", + "order": 200.0, + "icon": { + "name": "PiHardDrives" + } + } + ] +} +``` + +
+ +
+Example YAML Manifest + +```yaml +name: "Extension 1" +description: "My extension 1" +entry: "https://example.com/" +contexts: + - project +routes: + - id: "extension-1" + parentId: "workloads" + locationId: "runtime" + labelIntl: + en: "SomeLabel" + it: "SomeLabelInItalian" + destinationPath: "/" + renderType: "menu" + order: 200 + icon: + name: "PiHardDrives" +``` + +
+ +Usage: + +```sh +miactl extensions apply [flags] +``` + +Available flags for the command: + +- `--company-id` to set the ID of the desired Company +- `--file-path` (`-f`) **required** to specify the path to the extension manifest +- `--extension-id` to set the ID of the extension Company, required for updating an existing extension. + +:::tip +In order to specify whether a create or an update is needed you have to use the `--extension-id` +flag or specify the `extensionId` property in the manifest file. + +You can get the **extension id** by using the [extensions list](#list-5) command or +in the apply response after creating the extension. +::: + +### activate + +The `extensions activate` command can be used to activate an existing extension. + +:::tip +Please note that, based on provided `contexts`, an extension can be activated for the whole Company or for specific Projects. + +By using the `routes.locationId` option, you can specify where the extension is available, therefore +you can create an extension shown on the Project runtime and activate it for the whole Company context. +Such extension will be visible by all the Projects. + +For further information checkout the [official documentation](../../console/console-extensibility/extension-activation). +::: + +Usage: + +```sh +miactl extensions activate [flags] +``` + +Available flags for the command: + +- `--company-id` to set the ID of the desired Company +- `--project-id` to set the ID of the desired project, if specified, the extension will be activated only for this project only +- `--extension-id` **required** to set the ID of the extension + +### deactivate + +The `extensions deactivate` command can be used to deactivate an existing extension. + +:::tip +Please note that if an extension has been activated on the whole Company it can't be deactivated on a specific Project; +you have to deactivate on the whole Company and activate it on the desired Projects. +::: + +Usage: + +```sh +miactl extensions deactivate [flags] +``` + +Available flags for the command: + +- `--company-id` to set the ID of the desired Company +- `--project-id` to set the ID of the desired project, if specified, the extension will be deactivated only for this project only +- `--extension-id` **required** to set the ID of the extension. + +### delete + +The `extensions delete` command can be used to delete an existing extension. + +Usage: + +```sh +miactl extensions delete [flags] +``` + +Available flags for the command: + +- `--company-id` to set the ID of the desired Company +- `--extension-id` **required** to set the ID of the extension, required for updating an existing extension. + ## runtime ### environment list @@ -701,7 +881,7 @@ View and manage Marketplace items All the subcommands inherit the following flags: -``` +```sh --auth-name string the name of the miactl auth to use --certificate-authority string path to a cert file for the certificate authority for the selected endpoint --company-id string the ID of the Company diff --git a/docs/cli/miactl/40_examples.md b/docs/cli/miactl/40_examples.md index 80d59b742b..7edba75c8d 100644 --- a/docs/cli/miactl/40_examples.md +++ b/docs/cli/miactl/40_examples.md @@ -79,3 +79,66 @@ You can customize the way your Project is deployed: ```sh miactl deploy development --no-semver --revision tags/v1.0.0 ``` + +## Deploy Project using a service account from a CD pipeline + +The commands are the same used above in the [Deploy Project](#deploy-project) section, but you need to use a _Service Account_ for that. +If you don't know how to create a _Service Account_, read the [dedicated documentation](../../development_suite/identity-and-access-management/manage-service-accounts). + +The _Service Account_ can be created with [two different authentication methods](../../development_suite/identity-and-access-management/manage-service-accounts#adding-a-service-account): +* _Client Secret Basic_: the service account authenticates by presenting its `client_id` and `client_secret`; +* _Private Key JWT_: the service account authenticates by signing a `JWT` (JSON Web Token) using its private key. + + +After creating the _Service Account_, the first step to setup the `miactl` is **create an auth context**. +With an _auth context_ you can choose how to be authenticated with the Mia-Platform APIs in all your different contexts you create with the `miactl`. + +Based on the authentication method of your _Service Account_, you can create the auth context with the following command: + +* _Client Secret Basic_: + ```sh + miactl context auth --client-id --client-secret + ``` + +* _Private Key JWT_: + ```sh + miactl context auth --jwt-json + ``` + +Now you can create the context you want use the `miactl` to. + +:::warning +Remember to specify the auth context to be used with the `---auth-name` flag, otherwise the `miactl` will try to perform a user authentication through the default browser. +::: + +```sh +miactl context set --endpoint https://console.private --company-id --project-id --auth-name +``` + +After that, just set the context as the used one: + +```sh +miactl context use +``` + +and deploy the pipeline: + +```sh +miactl deploy development --no-semver --revision main +``` + +Finally, you can group the commands above and run them inside a pipeline, e.g. a GitLab pipeline: + +```yaml +# Insert that after your pipeline stages +delivery: + stage: deploy + image: ghcr.io/mia-platform/miactl:v0.13.0 + + script: + - miactl version + - miactl context auth deployer-sa --client-id sa-client-id --client-secret sa-super-secret + - miactl context set my-private-console --endpoint https://console.private --company-id id-of-my-company --project-id id-of-my-project --auth-name deployer-sa + - miactl use my-private-console + - miactl deploy DEV --no-semver --deploy-type smart_deploy --revision main +``` diff --git a/docs/cli/miactl/changelog.md b/docs/cli/miactl/changelog.md index a9b04d9dcb..8cf15b8f3f 100644 --- a/docs/cli/miactl/changelog.md +++ b/docs/cli/miactl/changelog.md @@ -15,6 +15,26 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [0.13.0] - 2024-06-26 + +### Added + +- `extensions list` command +- `extensions apply` command +- `extensions delete` command +- `extensions activate` command +- `extensions deactivate` command +- `context use` autocomplete contexts with tab + +### Changed + +- update go version to 1.22.3 +- update logr to v1.4.2 +- update oauth2 to v0.20.0 +- update sync to v0.7.0 +- update text to v0.15.0 +- introduced Printer interface with Table implementation + ## [0.12.2] - 2024-03-07 ## Changed @@ -253,7 +273,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - create cli sdk - create cli renderer -[unreleased]: https://github.com/mia-platform/miactl/compare/v0.12.2...HEAD +[unreleased]: https://github.com/mia-platform/miactl/compare/v0.13.0...HEAD +[0.13.0]: https://github.com/mia-platform/miactl/compare/v0.12.2...v0.13.0 [0.12.2]: https://github.com/mia-platform/miactl/compare/v0.12.1...v0.12.2 [0.12.1]: https://github.com/mia-platform/miactl/compare/v0.12.0...v0.12.1 [0.12.0]: https://github.com/mia-platform/miactl/compare/v0.11.0...v0.12.0 diff --git a/docs/infrastructure/self-hosted/installation-chart/.cspell.json b/docs/infrastructure/self-hosted/installation-chart/.cspell.json index 4ebe7ec5c5..900673fa63 100644 --- a/docs/infrastructure/self-hosted/installation-chart/.cspell.json +++ b/docs/infrastructure/self-hosted/installation-chart/.cspell.json @@ -20,7 +20,8 @@ "urandom", "CTYPE", "uuidgen", - "micro-lc" + "micro-lc", + "microlc" ], "flagWords": [], "ignorePaths": [], diff --git a/docs/infrastructure/self-hosted/installation-chart/helm-values/10_installation-chart-example.md b/docs/infrastructure/self-hosted/installation-chart/helm-values/10_installation-chart-example.md index 0d59d5060c..3ecc487425 100644 --- a/docs/infrastructure/self-hosted/installation-chart/helm-values/10_installation-chart-example.md +++ b/docs/infrastructure/self-hosted/installation-chart/helm-values/10_installation-chart-example.md @@ -118,6 +118,11 @@ configurations: keyRing: "" keyName: "" privateKey: "" + assistant: + enabled: true + keys: + llm: "" + embeddings: "" apiGateway: deploy: diff --git a/docs/infrastructure/self-hosted/installation-chart/helm-values/20_general-settings.md b/docs/infrastructure/self-hosted/installation-chart/helm-values/20_general-settings.md index 5acada450a..1183c73745 100644 --- a/docs/infrastructure/self-hosted/installation-chart/helm-values/20_general-settings.md +++ b/docs/infrastructure/self-hosted/installation-chart/helm-values/20_general-settings.md @@ -138,9 +138,7 @@ mia-console: | `configurations.enableFastData` | boolean | Enables Fast Data configurator | `true` | ✅ | | `configurations.enableDebugArea` | boolean | Enables debug area in Console | `true` | ✅ | | `configurations.enableMergeConfiguration` | boolean | Enables Merge Configuration | `true` | ✅ | -| `configurations.enableClustersAndEnvironmentsManagement` | boolean | Enables Clusters and Environments management | `true` | ✅ | | `configurations.projectTemplateArchiveUrl` | string | New project template url | | ✅ | -| `configurations.enableRuntimeServiceClusterSelection` | boolean | Enable selection from supported runtime providers during cluster setup, if you disable it you will have to manually fill all the required information | `true` | ✅ | | `configurations.enableBackofficeConfigurator` | boolean | Enable Backoffice Configurator | `true` | ✅ | | `configurations.enableFlowManager` | boolean | Enable Flow Manager | `true` | ✅ | diff --git a/docs/infrastructure/self-hosted/installation-chart/helm-values/75_assistant.md b/docs/infrastructure/self-hosted/installation-chart/helm-values/75_assistant.md new file mode 100644 index 0000000000..c7cffb1dd0 --- /dev/null +++ b/docs/infrastructure/self-hosted/installation-chart/helm-values/75_assistant.md @@ -0,0 +1,104 @@ +--- +id: assistant +title: Mia-Assistant +sidebar_label: Assistant +--- + + + +Mia-Platform Console includes *Mia Assistant*, an AI-based application that can be interrogated on anything included in the official [Mia-Platform Documentation](https://docs.mia-platform.eu). + +## MongoDB configuration + +Mia-Assistant relies on a MongoDB vector store collection, that is automatically populated during deployment. + +However, the Helm Chart is not yet capable of creating the vector store collection and the necessary indexes for it to work; so you have to manually create a collection named `assistant-documents` and configure an [Atlas Vector Search index](https://www.mongodb.com/docs/atlas/atlas-vector-search/tutorials/vector-search-quick-start/) on it. + +:::info +Please mind that Atlas Vector Search indexes are available only on MongoDB Atlas instance with version 6.0.11, 7.0.2 or higher. + +Unfortunately, MongoDB's Vector Search indexes are not available on previous versions or on MongoDB Entreprise Server edition. If you don't meet these requirements, unfortunately the service will not work. + +Please refer to the official MongoDB official documentation to have more information regarding this. +::: + +You can create the index in two ways: + +- with a script with the official MongoDB drivers that connects to MongoDB and prepare the embeddings for you, [as explained in the MongoDB official documentation](https://www.mongodb.com/docs/atlas/atlas-vector-search/vector-search-type/#procedure) +- manually, connecting to your MongoDB Atlas cluster and creating the index from the Atlas web application, [as explained in this guide](https://mongodb-developer.github.io/search-lab/docs/vector-search/create-index) + +It is important that the index have this structure: + +```json +{ + "fields": [ + { + "numDimensions": 1536, + "path": "embedding", + "similarity": "euclidean", + "type": "vector" + }, + { + "path": "__STATE__", + "type": "filter" + } + ] +} +``` + +:::caution +The structure of the index is mandatory, otherwise the documents cannot be extracted from the collection. +::: + +### OpenAI Configuration + +The Mia-Assistant service can be configured via Helm Chart using the `.assistant` value. + +:::info +At the moment, the only supported models are the ones developed by [OpenAI](https://platform.openai.com/docs/models/overview). +::: + +The Helm Chart will require including the API key for both the embedding model and the large language model used. For OpenAI models, these two API keys are the same and can be created from the [OpenAI API keys page](https://platform.openai.com/api-keys). After logging in with the credentials of your company, you can create the API Key that must be included in the `assistant` object inside the Helm chart and that will be used by the Mia-Assistant service. + +The service is already configured to use the following models: + +- [`text-embedding-3-small`](https://platform.openai.com/docs/guides/embeddings) as Embedding model +- [`gpt-3.5-turbo`](https://platform.openai.com/docs/models/gpt-3-5-turbo) as Large Language Model (LLM) + +:::info +Please note that using these models has a cost, which is detailed on the [Pricing](https://openai.com/api/pricing/) page of the OpenAI documentation. + +When registering with OpenAI, you also have to set up a billing plan in order to use OpenAI services with the Mia-Assistant. +::: + +## Mia-Assistant Configuration + +The configuration regarding the Assistant is included inside the `assistant` object, which is composed by: + +| Name | Type | Description | Default | Optional | +|:----:|:----:|:-----------:|:-------:|:--------:| +| `enabled` | boolean | If set to `true`, the Mia-Assistant will be enabled | `false` | ✅ | +| `keys.llm` | string | The API key for the Large Language Model | | ❌ | +| `keys.embeddings` | string | The API key for the Embedding Model | | ❌ | + + +Please mind that, without `key.llm` and `key.embeddings` correctly populated, the service will crash at its startup. + +Using OpenAI, the API key for embeddings and LLM are the same, so the same value should be included in both properties. + +### Example + +```yaml +mia-console: + configurations: + ... + assistant: + enabled: true + keys: + llm: "" + embeddings: "" +``` diff --git a/docs/infrastructure/self-hosted/installation-chart/helm-values/80_whitelabeling.md b/docs/infrastructure/self-hosted/installation-chart/helm-values/80_whitelabeling.md new file mode 100644 index 0000000000..d5ee9cc87c --- /dev/null +++ b/docs/infrastructure/self-hosted/installation-chart/helm-values/80_whitelabeling.md @@ -0,0 +1,77 @@ +--- +id: whitelabeling +title: Console Website Whitelabeling +sidebar_label: Whitelabeling +--- + + + +Some of Mia-Platform logos shown on the frontend can be customized with your own logos and custom images configurations, allowing for a more personalized experience for your users. + +## Configuration + +The configuration is set under the `staticImages` object, which accepts the following values: + +| Name | Type | Description | Default | Optional | +| :--------------------: | :----: | :------------------------------------------------: | :-----: | :------: | +| `loginPageLogo` | object | The logo shown on the login page | | ✅ | +| `loginPageBackground` | object | The background image shown on the login page | | ✅ | +| `favicon` | object | The favicon of the Console Website | | ✅ | +| `extendedSidebarLogo` | object | The logo shown on the sidebar when it is extended | | ✅ | +| `collapsedSidebarLogo` | object | The logo shown on the sidebar when it is collapsed | | ✅ | + +Each of the above values is an object containing these keys: + +| Name | Type | Description | Default | Optional | +| :-------------: | :----: | :-----------------------------: | :-----: | :------: | +| `fileExtension` | string | The file extension of the image | | ❌ | +| `fileContents` | string | The base64 encoded image | | ❌ | + + +### Examples + +```yaml +mia-console: + configurations: + staticImages: + loginPageLogo: + fileExtension: "png" + fileContents: + favicon: + fileExtension: "png" + fileContents: +``` + +The base64 encoded image can be generated with a command like: + +```sh +cat image.png | base64 +``` + +Then you can paste the output in the `fileContents` field. + +### Images specifications + + +#### Image sizes + +Given the 1MB limit of the Helm values, **we suggest keeping the images as small as possible**, in the order of a few KBs. +SVG images are preferred, usually smaller than PNG or JPEG images while maintaining good quality. + +#### Image format + +The images should be in a format that is supported by the browser, such as PNG, JPEG, or SVG. + +For each asset type, we suggest the following proportions and sizes: + +- `favicon`: a square of at least 16x16 pixels. +- `loginPageLogo`: an image with a reasonable size, the proportions are not strictly defined, but we suggest a minimum size of 200 pixels for each dimension. +- `loginPageBackground`: an image that covers the whole login page background. The [`background-style: cover`](https://developer.mozilla.org/en-US/docs/Web/CSS/background-size#cover) CSS property is used, so take into account that it might be cropped when its proportions don't match with the user's screen. In case you need a uniform color background, we suggest to use an SVG image with a single color. +- `extendedSidebarLogo`: an image with a reasonable size, the proportions are not strictly defined, but we suggest a minimum size of 200 pixels for each dimension. We suggest a rectangular image whose left side perfectly match the `collapsedSidebarLogo` image, so that when expanding and reducing the sidebar the two images are swapped without any visual glitch. +- `collapsedSidebarLogo`: an image with a reasonable size, the proportions are not strictly defined, but we suggest a minimum size of 200 pixels for each dimension. We suggest a square image that perfectly match the `extendedSidebarLogo` image left side, so that when expanding and reducing the sidebar the two images are swapped without any visual glitch. + +None of the above images are required, in case they are not defined the default Mia-Platform images will be used. For this reason, we suggest to define each one of them to have a consistent look and feel of the Console Website with your brand. diff --git a/docs/microfrontend-composer/back-kit/60_components/160_confirmation_modal.md b/docs/microfrontend-composer/back-kit/60_components/160_confirmation_modal.md index eb141a8def..a4dd9abe3f 100644 --- a/docs/microfrontend-composer/back-kit/60_components/160_confirmation_modal.md +++ b/docs/microfrontend-composer/back-kit/60_components/160_confirmation_modal.md @@ -39,8 +39,8 @@ The Confirmation Modal becomes visible upon listening to a [require-confirm] eve - `title`: the title of the modal. - `content`: the text content of the modal. -- `okText`: the text content of the "Cancel" button. -- `cancelText`: the text content of the "Confirm" button. +- `okText`: the text content of the "Confirm" button. +- `cancelText`: the text content of the "Cancel" button. - `onOk`: the callback to execute on confirm. Note: this key cannot be set through configuration. Use `configOk` key instead. - `onCancel`: the callback to execute on cancel. Note: this key cannot be set through configuration. Use `configCancel` key instead. - `configOk`: a "tag"-"properties" pair to mount a custom component in place of the default confirmation button. Usually, mounted components are instances of the [Button][bk-button] component. diff --git a/docs/microfrontend-composer/back-kit/70_events.md b/docs/microfrontend-composer/back-kit/70_events.md index 65e2bce26a..c736dc4cbd 100644 --- a/docs/microfrontend-composer/back-kit/70_events.md +++ b/docs/microfrontend-composer/back-kit/70_events.md @@ -709,7 +709,7 @@ raised when the import button is clicked sends user configuration payload to perform import -- Label: `import-user-config` +- Label: `import-data/user-config` - Payload: ```typescript diff --git a/docs/microfrontend-composer/back-kit/changelog.md b/docs/microfrontend-composer/back-kit/changelog.md index 0d715eadcf..b26283c030 100644 --- a/docs/microfrontend-composer/back-kit/changelog.md +++ b/docs/microfrontend-composer/back-kit/changelog.md @@ -15,7 +15,15 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). -## [1.5.4] - 2024-06-04 +## [1.5.5] - 2024-06-28 + +### Fixed + +- fixed `bk-table` fit parent on resize +- fixed half hidden tooltip in editor +- fixed error for required array of dates in forms + +## [1.5.4] - 2024-06-13 ### Added diff --git a/docs/microfrontend-composer/composer/changelog.md b/docs/microfrontend-composer/composer/changelog.md index 199911702c..b3d63347f5 100644 --- a/docs/microfrontend-composer/composer/changelog.md +++ b/docs/microfrontend-composer/composer/changelog.md @@ -10,6 +10,12 @@ DO NOT MODIFY IT BY HAND. Instead, modify the source file and run the aggregator to regenerate this file. --> +## [1.8.2] - 2024-07-01 + +### Fixed + +- No crud endpoints cause CRUD Client edit crash + ## [1.8.1] - 2024-06-11 ### Changed diff --git a/docs/release-notes/stable versions.md b/docs/release-notes/stable versions.md index 394b9a74fd..261834b37e 100644 --- a/docs/release-notes/stable versions.md +++ b/docs/release-notes/stable versions.md @@ -30,6 +30,6 @@ As the transition period from one MTW to the next approaches, more precise dates | Quarter | Stable Version | Start MTW | End MTW | |-----------|----------------|----------------------|----------------------| | Q1 - 2024 | v12.0.x | _January 18th, 2024_ | _April 15th, 2024_ | -| Q2 - 2024 | v12.3.x | _April 15th, 2024_ | _mid-July, 2024_ | -| Q3 - 2024 | v13.0.x | _mid-July, 2024_ | _mid-October, 2024_ | +| Q2 - 2024 | v12.3.x | _April 15th, 2024_ | _July 18th, 2024_ | +| Q3 - 2024 | v13.0.x | _July 18th, 2024_ | _mid-October, 2024_ | | Q4 - 2024 | _TBD_ | _mid-October, 2024_ | _mid-January, 2025_ | diff --git a/docs/release-notes/v13.0.1.md b/docs/release-notes/v13.0.1.md index 8f48bac845..eaef6a206d 100644 --- a/docs/release-notes/v13.0.1.md +++ b/docs/release-notes/v13.0.1.md @@ -63,7 +63,8 @@ This version addressed the following bugs: * fixed bug in project creation that prevented the user from finding the default template set by Blueprint section; * fixed bug that caused a problem with redirects in Runtime area; * fixed bug that prevented saving configuration on projects with Azure as provider, if the corresponding project was empty; -* fixed a bug in the sshUrl management during service creation +* fixed a bug in the sshUrl management during service creation; +* fixed a bug that prevented to create an Example or a Template from Marketplace if that was including interpolated variables in the Docker Image Name; the issue was caused by some incorrect validations, that have been removed. ## Fast Data diff --git a/docs/release-notes/v13.0.3.md b/docs/release-notes/v13.0.3.md index 5f0aac63b2..c226ccf9d7 100644 --- a/docs/release-notes/v13.0.3.md +++ b/docs/release-notes/v13.0.3.md @@ -5,15 +5,7 @@ sidebar_label: v13.0.3 image: "img/release-note-link-preview.png" --- -_June 21st, 2024_ - -:::info -Mia-Platform Console v13.0.3 is **now in Preview** and will be generally available on July 04th. - -Console SaaS users can try out v13.0.3 latest improvements in Preview! Open a Service Request to ask for the creation of a sandbox Company in case you do not have access to any Company. - -For self-hosted installations, please read the [following guidelines](#how-to-update-your-console). -::: +_July 04th, 2024_ ## Console @@ -40,6 +32,18 @@ This feedback will then be gathered and analyzed to improve the overall performa Once you have configured the Runtime Monitoring system for your Project, you can now define the scraping rules for each of your Microservice containers. You can perform such action in the `Monitoring` tab of each Microservice's details page. For more information, visit the related [documentation page](/development_suite/api-console/api-design/microservice-monitoring.md). +### Whitelabeling for Self-Hosted Clients + +During a Self-Hosted installation, it is now possible to customize certain Console images to suit the client needs. + +The customizable properties are: +- Login page logo; +- Background of the login page; +- Favicon; +- Sidebar logos (in both extended and collapsed versions). + +For more information, visit the related [documentation page](/infrastructure/self-hosted/installation-chart/helm-values/80_whitelabeling.md). + ### Bug Fix This version addressed the following bugs: @@ -90,4 +94,4 @@ The new version `7.0.3` of the CRUD Service is available! ## How to update your Console -For self-hosted installations, please head to the [self hosted upgrade guide](/infrastructure/self-hosted/installation-chart/100_how-to-upgrade.md) or contact your Mia-Platform referent and upgrade to _Console Helm Chart_ `v13.4.0-beta.0`. +For self-hosted installations, please head to the [self hosted upgrade guide](/infrastructure/self-hosted/installation-chart/100_how-to-upgrade.md) or contact your Mia-Platform referent and upgrade to _Console Helm Chart_ `v13.4.0`. diff --git a/docs/release-notes/v13.0.4.md b/docs/release-notes/v13.0.4.md new file mode 100644 index 0000000000..4173bda9ec --- /dev/null +++ b/docs/release-notes/v13.0.4.md @@ -0,0 +1,113 @@ +--- +id: v13.0.4 +title: Version 13.0.4 Release Notes +sidebar_label: v13.0.4 +image: "img/release-note-link-preview.png" +--- + +_July 04th, 2024_ + +:::info +Mia-Platform Console v13.0.4 is **now in Preview** and will be generally available on July 18th. + +Console SaaS users can try out v13.0.4 latest improvements in Preview! Open a Service Request to ask for the creation of a sandbox Company in case you do not have access to any Company. + +For self-hosted installations, please read the [following guidelines](#how-to-update-your-console). +::: + +## Console + +### Mia-Assistant available on Self-Hosted installations + +Mia-Assistant, the AI chatbot of Mia-Platform, is now available also on Self-Hosted installations! +For more information about how to configure it, head to the [installation chart documentation](/infrastructure/self-hosted/installation-chart/helm-values/75_assistant.md). + +### Manage iFrame extensions via miactl + +`miactl` v0.13.0 is out now and it is featuring new commands to manage your iFrame Company extensions directly from command line! +To discover more about such new commands, head to the related [documentation page](/cli/miactl/30_commands.md#extensions). + +### Bug Fix + +This version addressed the following bugs: + +* fixed a bug that caused a malfunction when creating Dashboard Categories from a project Blueprint; +* fixed a navigation bug that caused the user to enter an inconsistent state if the permission to access to a specific project was missing; +* fixed a bug that wrongly allowed users to create a container with the same name of the microservice to which it was added. + +## Fast Data + +### Fast Data Configurator + +#### Bug Fix + +This version addressed the following bug: + +* fixed a bug causing both the old and the new field to be kept when renaming a field of a nested object of a Single View. + +## Microfrontend Composer + +### Configurator + +#### Bug Fix + +This version addressed the following bugs: + +* fixed a bug that caused a malfunction of the Composer when opening the CRUD client component properties with no CRUD endpoints exposed. + +### Back-Kit Library + +#### Bug Fix + +This version addresses the following bugs: + +* fixed a bug for which bk-table doesn't fit parent container after resizing the browser window; +* fixed an editor tooltip that falls out of view in form modals; +* fixed an error in forms with array of dates fields. + +## Marketplace + +### Marketplace Updates + +#### CRUD Service + +The new version `7.0.4` of the CRUD Service is available! + +##### Bug Fix + +* fixed bug that made CRUD validating items of a collection with the wrong configuration, due to compilers collision with collections having the same prefix. + +#### Form Service Frontend + +The new version `2.0.5` of the Form Service Frontend is available! + +##### Bug Fix + +* Fixed bug on expired form behavior + +#### Messaging Service + +The new version `1.7.0` of the Messaging Service is available! + +##### New features + +* Added support for localization of interpolated data in message templates + +#### Notification Manager Service + +The new version `2.3.0` of the Notification Manager Service is available! + +##### New features + +* Added endpoints to manage message templates with `bk-crud-client` on Backoffice +* Added endpoints to manage notification settings with `bk-crud-client` on Backoffice +* Added support for localization of interpolated data in message templates +* Added support for integration with external services to retrieve user properties + +##### Bug Fix + +* Fixed a bug causing errors when sending attachments via email using both the Messaging and Event API + +## How to update your Console + +For self-hosted installations, please head to the [self hosted upgrade guide](/infrastructure/self-hosted/installation-chart/100_how-to-upgrade.md) or contact your Mia-Platform referent and upgrade to _Console Helm Chart_ `v13.5.0-beta.0`. diff --git a/docs/release-notes/versions.md b/docs/release-notes/versions.md index aa4df1c0e1..bd92133763 100644 --- a/docs/release-notes/versions.md +++ b/docs/release-notes/versions.md @@ -7,6 +7,7 @@ slug: "/release-notes/versions" --- | Release | Release notes | |---------|--------------------------------------------| +| v13.0.4 | [Read the release notes](/release-notes/v13.0.4.md) | | v13.0.3 | [Read the release notes](/release-notes/v13.0.3.md) | | v13.0.2 | [Read the release notes](/release-notes/v13.0.2.md) | | v13.0.1 | [Read the release notes](/release-notes/v13.0.1.md) | diff --git a/docs/runtime_suite/api-portal/10_overview.md b/docs/runtime_suite/api-portal/10_overview.md index a17ae6a4c8..af2c778846 100644 --- a/docs/runtime_suite/api-portal/10_overview.md +++ b/docs/runtime_suite/api-portal/10_overview.md @@ -17,18 +17,18 @@ The **API Portal** microservice will present you a graphical interface for your This interface will semantically describe the APIs in a readable structure text format and will also allow you to interact and test each of them by clicking on the "Try it out" button. :::note -The available Open Api document is automatically generated and kept in sync by [Swagger Aggregator](../swagger-aggregator/overview). -You can [apply custom configurations directly from the Console](../../development_suite/api-console/advanced-section/swagger-aggregator/configuration) +The available Open Api document is automatically generated and kept in sync by [Swagger Aggregator](/runtime_suite/swagger-aggregator/10_overview.md). +You can [apply custom configurations directly from the Console](/development_suite/api-console/advanced-section/swagger-aggregator/configuration.md) ::: The Open Api documentation lets you know exactly how your APIs will work and behave, before integrating your APIs into your code. It lists all the available REST-endpoints and provides detailed information for each of them: description, parameters and schema. :::note -API Portal generates the [Documentation Portal](../../console/project-configuration/documentation-portal) section of the Console where all services and CRUDs routes are shown and can be tested. +API Portal generates the [Documentation Portal](/console/project-configuration/documentation-portal.md) section of the Console where all services and CRUDs routes are shown and can be tested. ::: ## Features Other than showing your [Open Api specification document](https://swagger.io/resources/open-api/), the **API Portal** allows to filter it. It can be filtered by tags, methods and endpoint name. -It's also possible to change the category which is a map of the [subswaggers](../../development_suite/api-console/advanced-section/swagger-aggregator/configuration#subswaggers) related to the [Swagger Aggregator](../swagger-aggregator/overview) microservice. +It's also possible to change the category which is a map of the [subswaggers](/development_suite/api-console/advanced-section/swagger-aggregator/configuration.md#subswaggers) related to the [Swagger Aggregator](/runtime_suite/swagger-aggregator/10_overview.md) microservice. diff --git a/docs/runtime_suite/api-portal/20_configuration.md b/docs/runtime_suite/api-portal/20_configuration.md index 40889f7b41..d2b06dd973 100644 --- a/docs/runtime_suite/api-portal/20_configuration.md +++ b/docs/runtime_suite/api-portal/20_configuration.md @@ -10,10 +10,10 @@ DO NOT MODIFY IT BY HAND. Instead, modify the source file and run the aggregator to regenerate this file. --> -The **API Portal** microservice can be added to your project by visiting Mia-Platform [Marketplace](../../marketplace/overview_marketplace). It works best with the [Swagger Aggregator](../swagger-aggregator/overview) but it's possible to use it with a custom microservice if the correct data are returned. +The **API Portal** microservice can be added to your project by visiting Mia-Platform [Marketplace](/marketplace/overview_marketplace.md). It works best with the [Swagger Aggregator](/runtime_suite/swagger-aggregator/10_overview.md) but it's possible to use it with a custom microservice if the correct data are returned. :::note -You can select the [API Documentation](../../runtime_suite_applications/api-documentation-aggregator/overview) application on the [Marketplace](../../marketplace/overview_marketplace) to have a ready-to-use `API Portal` that works with the `Swagger Aggregator` microservice. +You can select the [API Documentation](/runtime_suite_applications/api-documentation-aggregator/10_overview.md) application on the [Marketplace](/marketplace/overview_marketplace.md) to have a ready-to-use `API Portal` that works with the `Swagger Aggregator` microservice. ::: ## Routes @@ -24,7 +24,7 @@ The main endpoints are: * `/api/openapi/json`: it expects a compliant [Open API specification document](https://swagger.io/resources/open-api/). All versions are supported; -* `/api/openapi/subswaggers/`: it expects an array of objects like `[{"name": "", "categoryUrl": ""}]`. The `categoryUrl` is joined, using [path.join](https://www.npmjs.com/package/path), with `/api/openapi/json`. To understand what is a subswagger, please see [this page](../../development_suite/api-console/advanced-section/swagger-aggregator/configuration#subswaggers). +* `/api/openapi/subswaggers/`: it expects an array of objects like `[{"name": "", "categoryUrl": ""}]`. The `categoryUrl` is joined, using [path.join](https://www.npmjs.com/package/path), with `/api/openapi/json`. To understand what is a subswagger, please see [this page](/development_suite/api-console/advanced-section/swagger-aggregator/configuration.md#subswaggers). The endpoints regarding the downloads are: diff --git a/docs/runtime_suite/crud-service/changelog.md b/docs/runtime_suite/crud-service/changelog.md index 27a4821766..7fae81f13e 100644 --- a/docs/runtime_suite/crud-service/changelog.md +++ b/docs/runtime_suite/crud-service/changelog.md @@ -15,6 +15,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). +## 7.0.4 - 2024-06-28 + +### Fixed + +- bug that made compilers collide with collections having the same prefix. + ## 7.0.3 - 2024-06-20 ### Changed diff --git a/docs/runtime_suite/form-service-frontend/changelog.md b/docs/runtime_suite/form-service-frontend/changelog.md index f5673816bf..441cbeacd3 100644 --- a/docs/runtime_suite/form-service-frontend/changelog.md +++ b/docs/runtime_suite/form-service-frontend/changelog.md @@ -15,24 +15,35 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). +## 2.0.5 2024-05-23 + +- fixed bug on expired form behavior + +## 2.0.4 2024-03-28 + +### Fixed + +- fixed error on form creation +- fixed error on form update + ## 2.0.3 2024-02-12 -## Fixed +### Fixed -- fixed error handler in style assets loader -- fixed error message when updating/saving a form schema in the builder +- Fixed error message when updating/saving a form schema in the builder +- Fixed error handler in style assets loader ## 2.0.2 2024-01-15 -## Fixed +### Fixed -- improved behavior of error notification in builder when saving or updating form +- Improved behavior of error notification in builder when saving or updating form ## 2.0.1 2023-12-15 ### Fixed -- if the application is already at `/visualizer/:id`, the page is reloaded after a form submition +- If the application is already at `/visualizer/:id`, the page is reloaded after a form submition ## 2.0.0 2023-11-21 @@ -41,14 +52,15 @@ The fix that requires setting the properties specified in the form builder even ### Changed -- Make form modal messages (availability and expiration) translatable +- Supports translations for availability and expiration error messages - Update the FormDatePicker in order to avoid past date selection +- Supports recap via email ### Added - Make the expiration message customizable for each form -- Support form start date - User can set the email address of the recap email sent when a user fill a form +- Support form start date ### Fixed diff --git a/docs/runtime_suite/swagger-aggregator/changelog.md b/docs/runtime_suite/swagger-aggregator/changelog.md index 25130f3b68..dbdc7ebbd0 100644 --- a/docs/runtime_suite/swagger-aggregator/changelog.md +++ b/docs/runtime_suite/swagger-aggregator/changelog.md @@ -43,7 +43,6 @@ Instead, modify the source file and run the aggregator to regenerate this file. ### Added - - `PREVENT_REQUEST_BODY_CONFLICTS` environment variable, to prevent the request body aggregation during the conversion from Swagger 2 to OpenAPI Specification v3. It is equivalent to the `resolveInternal` [parameter of the `swagger2openapi` library](https://github.com/Mermade/oas-kit/blob/main/packages/swagger2openapi/README.md#a-command-line) used for the conversion. ### Updated diff --git a/docs/runtime_suite_applications/microfrontend-composer-on-prem-toolkit/changelog.md b/docs/runtime_suite_applications/microfrontend-composer-on-prem-toolkit/changelog.md index 0557700ae1..3c59835a9a 100644 --- a/docs/runtime_suite_applications/microfrontend-composer-on-prem-toolkit/changelog.md +++ b/docs/runtime_suite_applications/microfrontend-composer-on-prem-toolkit/changelog.md @@ -15,6 +15,10 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). +## [1.2.12] - 2024-06-28 + +- Updated `back-kit` to version `1.5.5` + ## [1.2.11] - 2024-06-14 - Updated `back-kit` to version `1.5.4` diff --git a/docs/runtime_suite_applications/microfrontend-composer-toolkit/changelog.md b/docs/runtime_suite_applications/microfrontend-composer-toolkit/changelog.md index f0ddd4aa9a..4f940a5730 100644 --- a/docs/runtime_suite_applications/microfrontend-composer-toolkit/changelog.md +++ b/docs/runtime_suite_applications/microfrontend-composer-toolkit/changelog.md @@ -15,6 +15,10 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [3.4.9] - 2024-06-28 + +- Updated `back-kit` to version `1.5.5` + ## [3.4.8] - 2024-06-14 - Updated `back-kit` to version `1.5.4` diff --git a/docs/runtime_suite_templates/ai-rag-template/10_overview_and_usage.md b/docs/runtime_suite_templates/ai-rag-template/10_overview_and_usage.md new file mode 100644 index 0000000000..7123fcd571 --- /dev/null +++ b/docs/runtime_suite_templates/ai-rag-template/10_overview_and_usage.md @@ -0,0 +1,186 @@ +--- +id: overview_and_usage +title: AI RAG Template +sidebar_label: Overview And Usage +--- + + + +The _AI RAG Template_ is a template to build and run your own RAG application and build a Chatbot that is capable to perform a conversation with a user. + +The service is developed using the [LangChain](https://python.langchain.com/docs/get_started/introduction/) framework, which enables creating sequences of complex interactions using Large Language Models. The web server is implemented using the [FastAPI](https://fastapi.tiangolo.com/) framework. + +In order to work, it is required to have a MongoDB instance to be used as Vector Store and that supports [MongoDB Vector Search indexes](https://www.mongodb.com/docs/atlas/atlas-vector-search/tutorials/vector-search-quick-start/), which means an Atlas instance with version 6 or above. + +## Overview + +The following is the high-level architecture of the template. + +```mermaid +flowchart LR + fe[Frontend] + be[Backend] + vs[(Vector Store)] + llm[LLM API] + eg[Embeddings Generator API] + + fe --1. user question +\nchat history--> be + be --2. user question--> eg + eg --3. embedding-->be + be --4. similarity search-->vs + vs --5. similar docs-->be + be --6. user question +\nchat history +\nsimilar docs-->llm + llm --7. bot answer--> be + be --8. bot answer--> fe +``` + +### Embeddings + +Please mind that the template does not include embeddings or any logic to create them. It is intended that the Vector Store will include the embeddings (or these are generated separately). In any case, please ensure that the embedding model used the populate the Vector Store is the same embedding model used when running the service, otherwise the service will generate answers only based on its own knowledge, without being able to use the Vector Store, with the risk of hallucinations when chatting with the user. + +### API + +When running the service, the application exposes a Swagger UI at the `/docs` endpoint. + +### Chat Endpoint (`/chat/completions`) + +The `/chat/completions` endpoint generates responses to user queries based on provided context and chat history. It leverages information from the configured Vector Store to formulate relevant responses, enhancing the conversational experience. + +***Example***: + +
+Request + +```curl +curl 'http://localhost:3000/chat/completions' \ + -H 'content-type: application/json' \ + --data-raw '{"chat_query":"Design a CRUD schema for an online store selling merchandise items","chat_history":[]}' +``` + +
+ +
+Response + +```json +{ + "message": "For an online store selling merchandise items, we can design a CRUD schema for a `Product` entity with the following properties:\n\n- `name`: A mandatory string.\n- `description`: An optional string.\n- `price`: A mandatory number.\n\nThe CRUD schema, excluding the default attributes, would look like this:\n\n```json\n[\n {\n \"name\": \"name\",\n \"type\": \"string\",\n \"required\": true,\n \"nullable\": false,\n \"encryptionEnabled\": false,\n \"encryptionSearchable\": false,\n \"sensitivityValue\": 0\n },\n {\n \"name\": \"price\",\n \"type\": \"number\",\n \"required\": true,\n \"nullable\": false,\n \"encryptionEnabled\": false,\n \"encryptionSearchable\": false,\n \"sensitivityValue\": 0\n },\n {\n \"name\": \"description\",\n \"type\": \"string\",\n \"required\": false,\n \"nullable\": false,\n \"encryptionEnabled\": false,\n \"encryptionSearchable\": false,\n \"sensitivityValue\": 0\n }\n]\n```\n\nThis schema defines the structure of the `Product` entity with the necessary properties for managing merchandise items in the online store.", + "references": [ + { + "content": "### Create CRUD to Read and Write Table Data \nTo evaluate the new page, it's essential to create a CRUD microservice and expose the relevant data through an endpoint, facilitating reading and writing operations on our table. \n:::warning\nIf you're unfamiliar with CRUD microservices, consider consulting the [CRUD Tutorial](/console/tutorials/configure-marketplace-components/rest-api-for-crud-on-data.mdx).\n::: \nFor our example, let's employ a basic CRUD microservice featuring a `Product` entity endowed with the subsequent properties:\n* `name`: A mandatory string.\n* `description`: An optional string.\n* `price`: A mandatory number. \nThe data CRUD will be exposed via an endpoint named `products`. \nBelow is the CRUD schema, excluding the default CRUD attributes (_id, creatorId, createdAt, updaterId, updatedAt, and \\_\\_STATE\\_\\_): \n```json\n[\n{\n\"name\":\"name\",\n\"type\":\"string\",\n\"required\":true,\n\"nullable\":false,\n\"encryptionEnabled\":false,\n\"encryptionSearchable\":false,\n\"sensitivityValue\":0\n},\n{\n\"name\":\"price\",\n\"type\":\"number\",\n\"required\":true,\n\"nullable\":false,\n\"encryptionEnabled\":false,\n\"encryptionSearchable\":false,\n\"sensitivityValue\":0\n},\n{\n\"name\":\"description\",\n\"type\":\"string\",\n\"required\":false,\n\"nullable\":false,\n\"encryptionEnabled\":false,\n\"encryptionSearchable\":false,\n\"sensitivityValue\":0\n}\n]\n```\nNow, the CRUD data can be exposed using an endpoint named `products`.", + "url": "../../microfrontend-composer/tutorials/basics" + }, + { + "content": "### Create CRUD to Read and Write Table Data \nTo evaluate the new page, it's essential to create a CRUD microservice and expose the relevant data through an endpoint, facilitating reading and writing operations on our table. \n:::warning\nIf you're unfamiliar with CRUD microservices, consider consulting the [CRUD Tutorial](/console/tutorials/configure-marketplace-components/rest-api-for-crud-on-data.mdx).\n::: \nFor our example, let's employ a basic CRUD microservice featuring a `Product` entity endowed with the subsequent properties:\n* `name`: A mandatory string.\n* `description`: An optional string.\n* `price`: A mandatory number. \nThe data CRUD will be exposed via an endpoint named `products`. \nBelow is the CRUD schema, excluding the default CRUD attributes (_id, creatorId, createdAt, updaterId, updatedAt, and \\_\\_STATE\\_\\_): \n```json\n[\n{\n\"name\":\"name\",\n\"type\":\"string\",\n\"required\":true,\n\"nullable\":false,\n\"encryptionEnabled\":false,\n\"encryptionSearchable\":false,\n\"sensitivityValue\":0\n},\n{\n\"name\":\"price\",\n\"type\":\"number\",\n\"required\":true,\n\"nullable\":false,\n\"encryptionEnabled\":false,\n\"encryptionSearchable\":false,\n\"sensitivityValue\":0\n},\n{\n\"name\":\"description\",\n\"type\":\"string\",\n\"required\":false,\n\"nullable\":false,\n\"encryptionEnabled\":false,\n\"encryptionSearchable\":false,\n\"sensitivityValue\":0\n}\n]\n```\nNow, the CRUD data can be exposed using an endpoint named `products`.", + "url": "../../microfrontend-composer/tutorials/basics" + }, + { + "content": "### Create a CRUD for persistency \nTo create a CRUD service you can follow [this](/console/tutorials/configure-marketplace-components/rest-api-for-crud-on-data.mdx) tutorial.\nAs data schema please import this schema. \nRemember to create a **unique index** for the collection on the `sagaId` field and to set the **default state** for new documents to `PUBLIC`. \nTo do this follow these steps:\n1. Open the _Design_ section of the Console.\n1. On the left panel, in the _Data Models_ group, click on _MongoDB CRUD_ section.\n1. Click on the CRUD you created.\n1. In the _Indexes_ section click _Add index_.\n1. Enter these values:\n- **Name**: `sagaIdIndex`\n- **Type**: `Normal`\n- **Field**: `sagaId` \n
\n
\n![Create CRUD index](img/create-crud-1.png) \n
\n
\n1. Click _Create_. The new index will be shown.\n1. Set the `unique` checkbox for the `sagaIdIndex` index.\n1. In the _Internal Endpoints_ section make sure that `Default state` is set to `PUBLIC`. \n
\n
\n![Create CRUD index](img/create-crud-2.png) \n
\n
\nYou can find more information on CRUD Persistency Manager in the [dedicated](/runtime_suite/flow-manager-service/30_configuration.md#crud-persistency-manager) page.", + "url": "../../console/tutorials/configure-marketplace-components/flow-manager" + }, + { + "content": "### Create a CRUD for persistency \nTo create a CRUD service you can follow [this](/console/tutorials/configure-marketplace-components/rest-api-for-crud-on-data.mdx) tutorial.\nAs data schema please import this schema. \nRemember to create a **unique index** for the collection on the `sagaId` field and to set the **default state** for new documents to `PUBLIC`. \nTo do this follow these steps:\n1. Open the _Design_ section of the Console.\n1. On the left panel, in the _Data Models_ group, click on _MongoDB CRUD_ section.\n1. Click on the CRUD you created.\n1. In the _Indexes_ section click _Add index_.\n1. Enter these values:\n- **Name**: `sagaIdIndex`\n- **Type**: `Normal`\n- **Field**: `sagaId` \n
\n
\n![Create CRUD index](img/create-crud-1.png) \n
\n
\n1. Click _Create_. The new index will be shown.\n1. Set the `unique` checkbox for the `sagaIdIndex` index.\n1. In the _Internal Endpoints_ section make sure that `Default state` is set to `PUBLIC`. \n
\n
\n![Create CRUD index](img/create-crud-2.png) \n
\n
\nYou can find more information on CRUD Persistency Manager in the [dedicated](/runtime_suite/flow-manager-service/30_configuration.md#crud-persistency-manager) page.", + "url": "../../console/tutorials/configure-marketplace-components/flow-manager" + } + ] +} +``` + +
+ +### Metrics Endpoint (`/-/metrics`) + +The `/-/metrics` endpoint exposes useful metrics to be collected by Prometheus. + +## Environment Variables + +The following environment variables are required for the service to work: + +- **PORT**: the port used to expose the API (default: _3000_) +- **LOG_LEVEL**: the level of the logger (default: _INFO_) +- **CONFIGURATION_PATH**: the path that contains the [JSON configuration file](#configuration) +- **MONGODB_CLUSTER_URI**: the MongoDB connection string +- **LLM_API_KEY**: the API Key of the LLM (_NOTE_: currently, we support only the OpenAI models, thus the API Key is the same as the OpenAI API Key) +- **EMBEDDINGS_API_KEY**: the API Key of the embeddings model (_NOTE_: currently, we support only the OpenAI models, thus the API Key is the same as the OpenAI API Key) + +It is suggested to save the environment variables in a `.env` file. + +## Configuration + +The service requires several configuration parameters for execution. Below is an example configuration: + +```json +{ + "llm": { + "name": "gpt-3.5-turbo" + }, + "embeddings": { + "name": "text-embedding-3-small" + }, + "vectorStore": { + "dbName": "database-test", + "collectionName": "assistant-documents", + "indexName": "vector_index", + "relevanceScoreFn": "euclidean", + "embeddingKey": "embedding", + "textKey": "text", + "maxDocumentsToRetrieve": 4, + "minScoreDistance": 0.5 + }, + "chain": { + "aggregateMaxTokenNumber": 2000, + "rag": { + "promptsFilePath": { + "system": "/path/to/system-prompt.txt", + "user": "/path/to/user-prompt.txt" + } + } + } +} +``` + +Description of configuration parameters: + +| Name | Key | Description | +|------|-----|-------------| +| LLM Name | `llm.name` | Name of the chat model to use. We currently support only [OpenAI models](https://platform.openai.com/docs/models). | +| Embeddings Name | `embeddings.name` | Name of the encoder to use. We currently support only [OpenAI embeddings models](https://platform.openai.com/docs/guides/embeddings/what-are-embeddings). | +| Vector Store DB Name | `vectorStore.dbName` | Name of the MongoDB database to use as a knowledge base and that contains the collection with the embeddings. | +| Vector Store Collection Name | `vectorStore.collectionName` | Name of the MongoDB collection to use for storing documents and document embeddings. | +| Vector Store Index Name | `vectorStore.indexName` | Name of the vector index to use for retrieving documents related to the user's query. For more info, refer to the [Create a Vector index](#create-a-vector-index) paragraph. | +| Vector Store Relevance Score Function | `vectorStore.relevanceScoreFn` | Name of the similarity function used for extracting similar documents using the created vector index. For more info, refer to the [Create a Vector index](#create-a-vector-index) paragraph. | +| Vector Store Embeddings Key | `vectorStore.embeddingsKey` | Name of the field used to save the semantic encoding of documents. The question received will be compared to the vector in this field with the Vector Index. For more info, refer to the [Create a Vector index](#create-a-vector-index) paragraph. | +| Vector Store Text Key | `vectorStore.textKey` | Name of the field used to save the raw document (or chunk of document). The content of this field will be included in the prompt. | +| Vector Store Max. Documents To Retrieve | `vectorStore.maxDocumentsToRetrieve` | Maximum number of documents retrieved from the Vector Store. | +| Vector Store Min. Score Distance | `vectorStore.minScoreDistance` | Minimum score required for the extracted document to be used in the prompt. Any document with a score below this value will be discarded. | +| Chain RAG System Prompts File Path | `vectorStore.textKey` | Path to the file containing system prompts for the RAG model. | +| Chain RAG User Prompts File Path | `vectorStore.textKey` | Path to the file containing user prompts for the RAG model. | + +### Create a Vector Index + +This template requires a [MongoDB Vector Search Index](https://www.mongodb.com/docs/atlas/atlas-vector-search/vector-search-type/) to function correctly, and requires a MongoDB Atlas instance version 6 or above to work. + +You can create a new Vector Search Index with the following structure: + +```json +{ + "fields": [ + { + "type": "vector", + "path": "<>", + "numDimensions": 768, + "similarity": "<>" + } + ] +} +``` + +You should remember to: + +- to have as `path` the same value of the `vectorStore.embeddingsKey` configuration parameter +- to have as `similarity` the same value of the `vectorStore.relevanceScoreFn` configuration parameter +- to have as `numDimensions` to appropriate value based on the [embeddings model used](https://platform.openai.com/docs/guides/embeddings/how-to-get-embeddings) diff --git a/docs/runtime_suite_templates/ai-rag-template/_category_.json b/docs/runtime_suite_templates/ai-rag-template/_category_.json new file mode 100644 index 0000000000..b738effad6 --- /dev/null +++ b/docs/runtime_suite_templates/ai-rag-template/_category_.json @@ -0,0 +1,4 @@ +{ + "label": "AI RAG Template", + "position": 10 +} \ No newline at end of file diff --git a/docs/runtime_suite_templates/ai-rag-template/changelog.md b/docs/runtime_suite_templates/ai-rag-template/changelog.md new file mode 100644 index 0000000000..cc5a069dc6 --- /dev/null +++ b/docs/runtime_suite_templates/ai-rag-template/changelog.md @@ -0,0 +1,22 @@ +--- +id: changelog +title: Changelog +sidebar_label: CHANGELOG +--- + + + +All notable changes to this project will be documented in this file. + +The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), +and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). + +## 0.1.1 - 2024-05-09 + +### Added + +- first template implementation diff --git a/package.json b/package.json index 1c162e5870..55e529fd85 100644 --- a/package.json +++ b/package.json @@ -51,7 +51,7 @@ }, "devDependencies": { "@babel/eslint-parser": "^7.24.7", - "@swc/core": "^1.6.1", + "@swc/core": "^1.6.6", "eslint": "^8.57.0", "eslint-plugin-react": "7.34.3", "front-matter": "^4.0.2", diff --git a/sidebars.json b/sidebars.json index 4bc2f18b13..e38f0c67a6 100644 --- a/sidebars.json +++ b/sidebars.json @@ -1800,6 +1800,7 @@ "id": "release-notes/versions" }, "items": [ + { "id": "release-notes/v13.0.4", "type": "doc" }, { "id": "release-notes/v13.0.3", "type": "doc" }, { "id": "release-notes/v13.0.2", "type": "doc" }, { "id": "release-notes/v13.0.1", "type": "doc" }, diff --git a/versioned_docs/version-12.x.x/release-notes/v12.3.5.md b/versioned_docs/version-12.x.x/release-notes/v12.3.5.md new file mode 100644 index 0000000000..eb2f5c2577 --- /dev/null +++ b/versioned_docs/version-12.x.x/release-notes/v12.3.5.md @@ -0,0 +1,19 @@ +--- +id: v12.3.5 +title: Version 12.3.5 Release Notes +sidebar_label: v12.3.5 +image: "img/release-note-link-preview.png" +--- + +_July 04th, 2024_ + +## Console + +### Bug Fix + +This version addressed the following bug: +* we fixed a bug that prevented to create an Example or a Template from Marketplace if that was including interpolated variables in the Docker Image Name; the issue was caused by some incorrect validations, that have been removed. + +## How to update your Console + +For self-hosted installations, please head to the [self hosted upgrade guide](/infrastructure/self-hosted/installation-chart/100_how-to-upgrade.md#v12---version-upgrades) or contact your Mia-Platform referent and upgrade to _Console Helm Chart_ `v13.0.5`. \ No newline at end of file diff --git a/versioned_docs/version-12.x.x/release-notes/versions.md b/versioned_docs/version-12.x.x/release-notes/versions.md index 766a2b6e1e..12e92fd617 100644 --- a/versioned_docs/version-12.x.x/release-notes/versions.md +++ b/versioned_docs/version-12.x.x/release-notes/versions.md @@ -8,6 +8,7 @@ slug: "/release-notes/versions" | Release | Release notes | |---------|--------------------------------------------| | v12.4.0 | [Read the release notes](/release-notes/v12.4.0.md) | +| v12.3.5 | [Read the release notes](/release-notes/v12.3.5.md) | | v12.3.4 | [Read the release notes](/release-notes/v12.3.4.md) | | v12.3.3 | [Read the release notes](/release-notes/v12.3.3.md) | | v12.3.2 | [Read the release notes](/release-notes/v12.3.2.md) | diff --git a/versioned_sidebars/version-12.x.x-sidebars.json b/versioned_sidebars/version-12.x.x-sidebars.json index 622544d0ed..bf532e3b36 100644 --- a/versioned_sidebars/version-12.x.x-sidebars.json +++ b/versioned_sidebars/version-12.x.x-sidebars.json @@ -1713,6 +1713,10 @@ "id": "release-notes/v12.4.0", "type": "doc" }, + { + "id": "release-notes/v12.3.5", + "type": "doc" + }, { "id": "release-notes/v12.3.4", "type": "doc" diff --git a/yarn.lock b/yarn.lock index af965e428c..6250ccbf8c 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3448,92 +3448,92 @@ __metadata: languageName: node linkType: hard -"@swc/core-darwin-arm64@npm:1.6.1": - version: 1.6.1 - resolution: "@swc/core-darwin-arm64@npm:1.6.1" +"@swc/core-darwin-arm64@npm:1.6.6": + version: 1.6.6 + resolution: "@swc/core-darwin-arm64@npm:1.6.6" conditions: os=darwin & cpu=arm64 languageName: node linkType: hard -"@swc/core-darwin-x64@npm:1.6.1": - version: 1.6.1 - resolution: "@swc/core-darwin-x64@npm:1.6.1" +"@swc/core-darwin-x64@npm:1.6.6": + version: 1.6.6 + resolution: "@swc/core-darwin-x64@npm:1.6.6" conditions: os=darwin & cpu=x64 languageName: node linkType: hard -"@swc/core-linux-arm-gnueabihf@npm:1.6.1": - version: 1.6.1 - resolution: "@swc/core-linux-arm-gnueabihf@npm:1.6.1" +"@swc/core-linux-arm-gnueabihf@npm:1.6.6": + version: 1.6.6 + resolution: "@swc/core-linux-arm-gnueabihf@npm:1.6.6" conditions: os=linux & cpu=arm languageName: node linkType: hard -"@swc/core-linux-arm64-gnu@npm:1.6.1": - version: 1.6.1 - resolution: "@swc/core-linux-arm64-gnu@npm:1.6.1" +"@swc/core-linux-arm64-gnu@npm:1.6.6": + version: 1.6.6 + resolution: "@swc/core-linux-arm64-gnu@npm:1.6.6" conditions: os=linux & cpu=arm64 & libc=glibc languageName: node linkType: hard -"@swc/core-linux-arm64-musl@npm:1.6.1": - version: 1.6.1 - resolution: "@swc/core-linux-arm64-musl@npm:1.6.1" +"@swc/core-linux-arm64-musl@npm:1.6.6": + version: 1.6.6 + resolution: "@swc/core-linux-arm64-musl@npm:1.6.6" conditions: os=linux & cpu=arm64 & libc=musl languageName: node linkType: hard -"@swc/core-linux-x64-gnu@npm:1.6.1": - version: 1.6.1 - resolution: "@swc/core-linux-x64-gnu@npm:1.6.1" +"@swc/core-linux-x64-gnu@npm:1.6.6": + version: 1.6.6 + resolution: "@swc/core-linux-x64-gnu@npm:1.6.6" conditions: os=linux & cpu=x64 & libc=glibc languageName: node linkType: hard -"@swc/core-linux-x64-musl@npm:1.6.1": - version: 1.6.1 - resolution: "@swc/core-linux-x64-musl@npm:1.6.1" +"@swc/core-linux-x64-musl@npm:1.6.6": + version: 1.6.6 + resolution: "@swc/core-linux-x64-musl@npm:1.6.6" conditions: os=linux & cpu=x64 & libc=musl languageName: node linkType: hard -"@swc/core-win32-arm64-msvc@npm:1.6.1": - version: 1.6.1 - resolution: "@swc/core-win32-arm64-msvc@npm:1.6.1" +"@swc/core-win32-arm64-msvc@npm:1.6.6": + version: 1.6.6 + resolution: "@swc/core-win32-arm64-msvc@npm:1.6.6" conditions: os=win32 & cpu=arm64 languageName: node linkType: hard -"@swc/core-win32-ia32-msvc@npm:1.6.1": - version: 1.6.1 - resolution: "@swc/core-win32-ia32-msvc@npm:1.6.1" +"@swc/core-win32-ia32-msvc@npm:1.6.6": + version: 1.6.6 + resolution: "@swc/core-win32-ia32-msvc@npm:1.6.6" conditions: os=win32 & cpu=ia32 languageName: node linkType: hard -"@swc/core-win32-x64-msvc@npm:1.6.1": - version: 1.6.1 - resolution: "@swc/core-win32-x64-msvc@npm:1.6.1" +"@swc/core-win32-x64-msvc@npm:1.6.6": + version: 1.6.6 + resolution: "@swc/core-win32-x64-msvc@npm:1.6.6" conditions: os=win32 & cpu=x64 languageName: node linkType: hard -"@swc/core@npm:^1.6.1": - version: 1.6.1 - resolution: "@swc/core@npm:1.6.1" - dependencies: - "@swc/core-darwin-arm64": "npm:1.6.1" - "@swc/core-darwin-x64": "npm:1.6.1" - "@swc/core-linux-arm-gnueabihf": "npm:1.6.1" - "@swc/core-linux-arm64-gnu": "npm:1.6.1" - "@swc/core-linux-arm64-musl": "npm:1.6.1" - "@swc/core-linux-x64-gnu": "npm:1.6.1" - "@swc/core-linux-x64-musl": "npm:1.6.1" - "@swc/core-win32-arm64-msvc": "npm:1.6.1" - "@swc/core-win32-ia32-msvc": "npm:1.6.1" - "@swc/core-win32-x64-msvc": "npm:1.6.1" +"@swc/core@npm:^1.6.6": + version: 1.6.6 + resolution: "@swc/core@npm:1.6.6" + dependencies: + "@swc/core-darwin-arm64": "npm:1.6.6" + "@swc/core-darwin-x64": "npm:1.6.6" + "@swc/core-linux-arm-gnueabihf": "npm:1.6.6" + "@swc/core-linux-arm64-gnu": "npm:1.6.6" + "@swc/core-linux-arm64-musl": "npm:1.6.6" + "@swc/core-linux-x64-gnu": "npm:1.6.6" + "@swc/core-linux-x64-musl": "npm:1.6.6" + "@swc/core-win32-arm64-msvc": "npm:1.6.6" + "@swc/core-win32-ia32-msvc": "npm:1.6.6" + "@swc/core-win32-x64-msvc": "npm:1.6.6" "@swc/counter": "npm:^0.1.3" - "@swc/types": "npm:^0.1.8" + "@swc/types": "npm:^0.1.9" peerDependencies: "@swc/helpers": "*" dependenciesMeta: @@ -3560,7 +3560,7 @@ __metadata: peerDependenciesMeta: "@swc/helpers": optional: true - checksum: 10/a79873f5591d13d82c22cd80ebad49fc10252f5e0f71d3b14865a355ef022ec4b79de5d5da1877e14776579290c2c9a5033bae8b32d807f2995d155278d093a9 + checksum: 10/9cb53c75a06ed82bdceb6f4b1118e26957c6de7b899927a2e455ea66725c79601dfc59cb56a8e8f4019557fcf062cdafa100ccc249dfcd9229b73a629922e7ea languageName: node linkType: hard @@ -3571,12 +3571,12 @@ __metadata: languageName: node linkType: hard -"@swc/types@npm:^0.1.8": - version: 0.1.8 - resolution: "@swc/types@npm:0.1.8" +"@swc/types@npm:^0.1.9": + version: 0.1.9 + resolution: "@swc/types@npm:0.1.9" dependencies: "@swc/counter": "npm:^0.1.3" - checksum: 10/2d1cda35116e03714137c1c37f4493efe0e26e88285ecc9dcdf6256a77984e367ea7b5f31d650f110fdcfd6ac53dff3ec77f841787ca328d2efa7b07ef1ac318 + checksum: 10/c67ee0480b7d71c20764c5d99addebc1aacd4aed218f56143fa946132a93ff3e11bdea913c628ad992acf78c4d1fe69e65bb4fd2b81d8006a2edf94661d2fbce languageName: node linkType: hard @@ -10257,7 +10257,7 @@ __metadata: "@docusaurus/plugin-client-redirects": "npm:2.4.3" "@docusaurus/preset-classic": "npm:2.4.3" "@staticdeploy/cli": "npm:^0.15.5" - "@swc/core": "npm:^1.6.1" + "@swc/core": "npm:^1.6.6" clsx: "npm:^2.1.1" cspell: "npm:^8.8.4" docusaurus-json-schema-plugin: "npm:^1.12.1"