Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

vdb-tests.yml 2.5KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798
  1. name: Run VDB Tests
  2. on:
  3. pull_request:
  4. branches:
  5. - main
  6. paths:
  7. - api/core/rag/datasource/**
  8. - docker/**
  9. - .github/workflows/vdb-tests.yml
  10. - api/uv.lock
  11. - api/pyproject.toml
  12. concurrency:
  13. group: vdb-tests-${{ github.head_ref || github.run_id }}
  14. cancel-in-progress: true
  15. jobs:
  16. test:
  17. name: VDB Tests
  18. runs-on: ubuntu-latest
  19. strategy:
  20. matrix:
  21. python-version:
  22. - "3.11"
  23. - "3.12"
  24. steps:
  25. - name: Checkout code
  26. uses: actions/checkout@v4
  27. with:
  28. persist-credentials: false
  29. - name: Free Disk Space
  30. uses: endersonmenezes/free-disk-space@v2
  31. with:
  32. remove_dotnet: true
  33. remove_haskell: true
  34. remove_tool_cache: true
  35. - name: Setup UV and Python
  36. uses: astral-sh/setup-uv@v6
  37. with:
  38. enable-cache: true
  39. python-version: ${{ matrix.python-version }}
  40. cache-dependency-glob: api/uv.lock
  41. - name: Check UV lockfile
  42. run: uv lock --project api --check
  43. - name: Install dependencies
  44. run: uv sync --project api --dev
  45. - name: Set up dotenvs
  46. run: |
  47. cp docker/.env.example docker/.env
  48. cp docker/middleware.env.example docker/middleware.env
  49. - name: Expose Service Ports
  50. run: sh .github/workflows/expose_service_ports.sh
  51. - name: Set up Vector Store (TiDB)
  52. uses: hoverkraft-tech/compose-action@v2.0.2
  53. with:
  54. compose-file: docker/tidb/docker-compose.yaml
  55. services: |
  56. tidb
  57. tiflash
  58. - name: Set up Vector Stores (Weaviate, Qdrant, PGVector, Milvus, PgVecto-RS, Chroma, MyScale, ElasticSearch, Couchbase, OceanBase)
  59. uses: hoverkraft-tech/compose-action@v2.0.2
  60. with:
  61. compose-file: |
  62. docker/docker-compose.yaml
  63. services: |
  64. weaviate
  65. qdrant
  66. couchbase-server
  67. etcd
  68. minio
  69. milvus-standalone
  70. pgvecto-rs
  71. pgvector
  72. chroma
  73. elasticsearch
  74. oceanbase
  75. - name: setup test config
  76. run: |
  77. echo $(pwd)
  78. ls -lah .
  79. cp api/tests/integration_tests/.env.example api/tests/integration_tests/.env
  80. - name: Check VDB Ready (TiDB)
  81. run: uv run --project api python api/tests/integration_tests/vdb/tidb_vector/check_tiflash_ready.py
  82. - name: Test Vector Stores
  83. run: uv run --project api bash dev/pytest/pytest_vdb.sh