Skip to content

Commit afc77b6

Browse files
authored
chore: fix out of disk space for tests in GitHub workflows (#100)
1 parent be3b35b commit afc77b6

File tree

10 files changed

+49
-47
lines changed

10 files changed

+49
-47
lines changed

.github/workflows/deploy-development.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ jobs:
3838
gitlab-project-id: "2461"
3939

4040
name: Deploy to ${{ matrix.environment-name }}
41-
uses: epam/ai-dial-ci/.github/workflows/deploy-development.yml@3.0.2
41+
uses: epam/ai-dial-ci/.github/workflows/deploy-development.yml@3.1.0
4242
with:
4343
gitlab-project-id: ${{ matrix.gitlab-project-id }}
4444
environment-name: ${{ matrix.environment-name }}

.github/workflows/pr-title-check.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,6 @@ concurrency:
1313

1414
jobs:
1515
pr-title-check:
16-
uses: epam/ai-dial-ci/.github/workflows/pr-title-check.yml@3.0.2
16+
uses: epam/ai-dial-ci/.github/workflows/pr-title-check.yml@3.1.0
1717
secrets:
1818
ACTIONS_BOT_TOKEN: ${{ secrets.ACTIONS_BOT_TOKEN }}

.github/workflows/pr.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@ concurrency:
1010

1111
jobs:
1212
run_tests:
13-
uses: epam/ai-dial-ci/.github/workflows/python_docker_pr.yml@3.0.2
13+
uses: epam/ai-dial-ci/.github/workflows/python_docker_pr.yml@3.1.0
1414
with:
15+
python-version: 3.11
16+
poetry-version: 2.2.1
1517
maximize-build-space: true
1618
secrets: inherit

.github/workflows/release.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@ concurrency:
1010

1111
jobs:
1212
release:
13-
uses: epam/ai-dial-ci/.github/workflows/python_docker_release.yml@3.0.2
13+
uses: epam/ai-dial-ci/.github/workflows/python_docker_release.yml@3.1.0
1414
secrets: inherit
1515
with:
16+
python-version: 3.11
17+
poetry-version: 2.2.1
1618
maximize-build-space: true

README.md

Lines changed: 22 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,11 @@
55
The Dial RAG answers user questions using information from the documents provided by user. It supports the following document formats: PDF, DOC/DOCX, PPT/PPTX, TXT and other plain text formats such as code files. Also, it supports PDF and JPEG, PNG and other image formats for the image understanding.
66

77
The Dial RAG implements several retrieval methods to find the relevant information:
8-
* **Description retriever** - uses vision model to generate page images descriptions and perform search on them. Supports different vision models, like `gpt-4o-mini`, `gemini-1.5-flash-002` or `anthropic.claude-v3-haiku`.
9-
* **Multimodal retriever** - uses multimodal embedding models for pages images search. Supports different multimodal models, like [`azure-ai-vision-embeddings`](https://learn.microsoft.com/en-us/azure/ai-services/computer-vision/concept-image-retrieval), [Google `multimodalembedding@001`](https://cloud.google.com/vertex-ai/generative-ai/docs/embeddings/get-multimodal-embeddings) or [`amazon.titan-embed-image-v1`](https://docs.aws.amazon.com/bedrock/latest/userguide/titan-multiemb-models.html)
10-
* **Semantic retriever** - uses [text embedding model](https://huggingface.co/epam/bge-small-en) to find the relevant information in the documents.
11-
* **Keyword retriever** - uses [Okapi BM25](https://en.wikipedia.org/wiki/Okapi_BM25) algorithm to find the relevant information in the documents.
8+
9+
- **Description retriever** - uses vision model to generate page images descriptions and perform search on them. Supports different vision models, like `gpt-4o-mini`, `gemini-1.5-flash-002` or `anthropic.claude-v3-haiku`.
10+
- **Multimodal retriever** - uses multimodal embedding models for pages images search. Supports different multimodal models, like [`azure-ai-vision-embeddings`](https://learn.microsoft.com/en-us/azure/ai-services/computer-vision/concept-image-retrieval), [Google `multimodalembedding@001`](https://cloud.google.com/vertex-ai/generative-ai/docs/embeddings/get-multimodal-embeddings) or [`amazon.titan-embed-image-v1`](https://docs.aws.amazon.com/bedrock/latest/userguide/titan-multiemb-models.html)
11+
- **Semantic retriever** - uses [text embedding model](https://huggingface.co/epam/bge-small-en) to find the relevant information in the documents.
12+
- **Keyword retriever** - uses [Okapi BM25](https://en.wikipedia.org/wiki/Okapi_BM25) algorithm to find the relevant information in the documents.
1213

1314
The Dial RAG is intended to be used in the [Dial](https://github.com/epam/ai-dial) environment. It uses the [Dial Core](https://github.com/epam/ai-dial-core) to access the LLMs and other services.
1415

@@ -18,17 +19,18 @@ The Dial RAG is intended to be used in the [Dial](https://github.com/epam/ai-dia
1819

1920
Following environment variables are required to set for the deployment configuration:
2021

21-
|Variable|Description|
22-
|---|---|
23-
|`DIAL_URL`| url to the dial core |
24-
|`DIAL_RAG__INDEX_STORAGE__USE_DIAL_FILE_STORAGE`| set to **True** to store indexes in the Dial File Storage instead of the local file storage |
22+
| Variable | Description |
23+
| ------------------------------------------------ | ------------------------------------------------------------------------------------------- |
24+
| `DIAL_URL` | url to the dial core |
25+
| `DIAL_RAG__INDEX_STORAGE__USE_DIAL_FILE_STORAGE` | set to **True** to store indexes in the Dial File Storage instead of the local file storage |
2526

2627
### Configuration files
2728

2829
The Dial RAG provides a set of configuration files with predefined settings for different environments. The configuration files are located in the `config` directory.
2930
You can set the environment variable `DIAL_RAG__CONFIG_PATH` to point to the required configuration file depending on the Dial environment and available models.
3031

3132
The following configuration files are available in the `config` directory:
33+
3234
- `config/aws_description.yaml` - AWS environment with description retriever, which uses `Claude Haiku 4.5` model for page images descriptions and `Claude Sonnet 3.5` for the answer generation.
3335
- `config/aws_embedding.yaml` - AWS environment with multimodal retriever, which uses `amazon.titan-embed-image-v1` model for page images embeddings and `Claude Sonnet 3.5` for the answer generation.
3436
- `config/azure_description.yaml` - Azure environment with description retriever, which uses `GPT-4.1 mini` model for page images descriptions and `GPT-4.1` for the answer generation.
@@ -39,14 +41,12 @@ The following configuration files are available in the `config` directory:
3941

4042
If you are running the Dial RAG in a different environment, you can create your own configuration file based on one of the provided files and set the `DIAL_RAG__CONFIG_PATH` environment variable to point to it. If you need a small change in the configuration (for example to change the model name), you can point the `DIAL_RAG__CONFIG_PATH` to the existing file and override the required settings using the environment variables. See the [Additional environment variables](#additional-environment-variables) section for the list of available settings.
4143

42-
4344
### Logging configuration environment variables
4445

45-
|Variable|Default|Description|
46-
|---|---|---|
47-
|`LOG_LEVEL`| `INFO` | Log level for the application. |
48-
|`LOG_LEVEL_OVERRIDE`| `{}` | Allows to override log level for specific modules. Example: `LOG_LEVEL_OVERRIDE='{"dial_rag": "DEBUG", "urllib3": "ERROR" }'`|
49-
46+
| Variable | Default | Description |
47+
| -------------------- | ------- | ----------------------------------------------------------------------------------------------------------------------------- |
48+
| `LOG_LEVEL` | `INFO` | Log level for the application. |
49+
| `LOG_LEVEL_OVERRIDE` | `{}` | Allows to override log level for specific modules. Example: `LOG_LEVEL_OVERRIDE='{"dial_rag": "DEBUG", "urllib3": "ERROR" }'` |
5050

5151
### Additional environment variables
5252

@@ -247,19 +247,17 @@ Dial RAG supports following commands in messages:
247247

248248
### Attach
249249

250-
`/attach <url>` - allows to provide an url to the attached document in the message body. Is equivalent to the setting `messages[i].custom_content.attachments[j].url` in the [Dial API](https://epam-rail.com/dial_api#/paths/~1openai~1deployments~1%7BDeployment%20Name%7D~1chat~1completions/post).
250+
`/attach <url>` - allows to provide an url to the attached document in the message body. Is equivalent to the setting `messages[i].custom_content.attachments[j].url` in the [Dial API](https://dialx.ai/dial_api).
251251

252252
The `/attach` command is useful to attach the document which is available in the Internet and is not uploaded to the Dial File Storage.
253253

254-
255254
### Debug commands
256255

257256
Dial RAG supports following debug commands if the option `ENABLE_DEBUG_COMMANDS` is set to `true`.
258257

259-
* `/model <model>` - allows to override the chat model used for the answer generation. Should be a deployment name of a chat model in available the Dial.
260-
* `/query_model <model>` - allows to override the model used to summarize the chat history to the standalone question. Should be a deployment name of a chat model in available the Dial. The model should support `tool calls`.
261-
* `/profile` - generates CPU profile report for the request. The report will be available as an attachment in the `Profiler` stage.
262-
258+
- `/model <model>` - allows to override the chat model used for the answer generation. Should be a deployment name of a chat model in available the Dial.
259+
- `/query_model <model>` - allows to override the model used to summarize the chat history to the standalone question. Should be a deployment name of a chat model in available the Dial. The model should support `tool calls`.
260+
- `/profile` - generates CPU profile report for the request. The report will be available as an attachment in the `Profiler` stage.
263261

264262
## Developer environment
265263

@@ -275,7 +273,6 @@ poetry install
275273

276274
This will install all requirements for running the package, linting, formatting and tests.
277275

278-
279276
Alternatively, if you have [uv](https://docs.astral.sh/uv/) installed, you can use it to create the environment with required version of Python and poetry:
280277

281278
```sh
@@ -291,14 +288,12 @@ If you want to use poetry from the uv with make commands, you can set the `POETR
291288
POETRY="uvx poetry@2.2.1" make install
292289
```
293290

294-
295291
### IDE configuration
296292

297293
The recommended IDE is [VSCode](https://code.visualstudio.com/).
298294
Open the project in VSCode and install the recommended extensions.
299295

300-
This project uses [Ruff](https://docs.astral.sh/ruff/) as a linter and formatter. To configure it for your IDE follow the instructions in https://docs.astral.sh/ruff/editors/setup/.
301-
296+
This project uses [Ruff](https://docs.astral.sh/ruff/) as a linter and formatter. To configure it for your IDE follow the instructions in <https://docs.astral.sh/ruff/editors/setup/>.
302297

303298
### Make on Windows
304299

@@ -314,7 +309,7 @@ The command definitions inside Makefile should be cross-platform to keep the dev
314309

315310
### Environment Variables
316311

317-
Copy `.env.example` to `.env` and customize it for your environment for the development process. See the [Configuration](#Configuration) section for the list of environment variables.
312+
Copy `.env.example` to `.env` and customize it for your environment for the development process. See the [Configuration](#configuration) section for the list of environment variables.
318313

319314
## Run
320315

@@ -360,8 +355,6 @@ The `docker_compose_local` folder contains the Docker Compose file and auxiliary
360355
docker-compose up --build dial-rag
361356
```
362357

363-
364-
365358
## Lint
366359

367360
Run the linting before committing:
@@ -395,12 +388,12 @@ make docker_test
395388
Some of the tests marked with the `@e2e_test` decorator utilize cached results located in the `./tests/cache` directory. By default, these tests will use cached values. During test execution, you may encounter warning or failure messages such as `Failed: There is no response found in cache, use environment variable REFRESH=True to update` This indicates that some logic has changed and that the cached responses are out of date.
396389

397390
These tests can be executed using environment variables, or nox sessions:
391+
398392
- `make test` (or `nox -s test`) - usual test run, executed on CI. The test uses *ONLY* the cached responses from LLM. If cache missing, test throws an exception.
399393
- `REFRESH=True make test` (or `nox -s test -- --refresh`) - This flag will delete all unused cache files, and stores new ones required by the executed tests.
400394

401395
To use the `REFRESH` flag, you need to have running dial-core on `DIAL_CORE_HOST` (default "localhost:8080") with `DIAL_CORE_API_KEY` (default "dial_api_key").
402396

403-
404397
## Clean
405398

406399
To remove the virtual environment and build artifacts:
@@ -411,10 +404,9 @@ make clean
411404

412405
## Update docs
413406

414-
This project uses [settings-doc](https://github.com/radeklat/settings-doc) to generate the [Configuration](#Configuration) section of this documentation from the Pydantic settings.
407+
This project uses [settings-doc](https://github.com/radeklat/settings-doc) to generate the [Configuration](#configuration) section of this documentation from the Pydantic settings.
415408
To update the documentation run:
416409

417410
```sh
418411
make docs
419412
```
420-

aidial_rag/dial_user_limits.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ class TokenStats(BaseModel):
1212
class UserLimitsForModel(BaseModel):
1313
"""Implementation of the response from the /v1/deployments/{deployment_name}/limits endpoint
1414
15-
See https://epam-rail.com/dial_api#tag/Limits for the API documentation.
15+
See https://dialx.ai/dial_api#tag/Limits for the API documentation.
1616
"""
1717

1818
minute_token_stats: TokenStats = Field(alias="minuteTokenStats")
@@ -24,7 +24,7 @@ async def get_user_limits_for_model(
2424
) -> UserLimitsForModel:
2525
"""Returns the user limits for the specified model deployment.
2626
27-
See https://epam-rail.com/dial_api#tag/Limits for the API documentation.
27+
See https://dialx.ai/dial_api#tag/Limits for the API documentation.
2828
"""
2929
headers = {"Api-Key": dial_config.api_key.get_secret_value()}
3030
limits_url = (

0 commit comments

Comments
 (0)