Skip to content

Commit

Permalink
requirement: google-cloud-aiplatform = ">=1.57.0" modified
Browse files Browse the repository at this point in the history
  • Loading branch information
riccardo-alle committed Aug 8, 2024
1 parent 7f6428f commit a8d8b3f
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 15 deletions.
2 changes: 1 addition & 1 deletion allms/defaults/vertex_ai.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ class PalmModelDefaults:


class GeminiModelDefaults:
GCP_MODEL_NAME = "gemini-1.0-pro-001"
GCP_MODEL_NAME = "gemini-1.5-flash-001"
MODEL_TOTAL_MAX_TOKENS = 30720
MAX_OUTPUT_TOKENS = 2048
TEMPERATURE = 0.0
Expand Down
22 changes: 11 additions & 11 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ packages = [{include = "allms"}]
[tool.poetry.dependencies]
python = ">=3.8.1,<4.0"
fsspec = "^2023.6.0"
google-cloud-aiplatform = "^1.47.0"
google-cloud-aiplatform = ">=1.57.0"
pydash = "^7.0.6"
transformers = "^4.34.1"
pydantic = "1.10.13"
Expand Down
3 changes: 1 addition & 2 deletions tests/test_end_to_end.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,6 @@ def test_model_is_queried_successfully(
assert list(map(lambda output: int(output[IODataConstants.GENERATED_TOKENS_NUMBER]), expected_output)) == list(
map(lambda example: example.number_of_generated_tokens, parsed_responses))


def test_prompt_is_not_modified_for_open_source_models(self, mock_aioresponse, models, mocker):
# GIVEN
open_source_models = ["azure_llama2", "azure_mistral", "vertex_gemma"]
Expand Down Expand Up @@ -150,7 +149,7 @@ def test_prompt_is_not_modified_for_open_source_models(self, mock_aioresponse, m

def test_gemini_specific_args_are_passed_to_model(self):
# GIVEN
gemini_model_name = "gemini-1.0-pro-001"
gemini_model_name = "gemini-1.5-pro-001"
gemini_safety_settings = {
HarmCategory.HARM_CATEGORY_UNSPECIFIED: HarmBlockThreshold.BLOCK_NONE,
HarmCategory.HARM_CATEGORY_DANGEROUS_CONTENT: HarmBlockThreshold.BLOCK_MEDIUM_AND_ABOVE,
Expand Down

0 comments on commit a8d8b3f

Please sign in to comment.