Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[fundamental][bugfix] Replace retired model "text-ada-001" #3429

Merged
merged 4 commits into from
Jun 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/promptflow-executor-unit-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ on:
- src/promptflow/promptflow/storage/**
- src/promptflow/tests/*
- src/promptflow/tests/executor/**
- src/promptflow/tests/test_configs/**
- src/promptflow-tracing/promptflow/**
- src/promptflow-core/promptflow/**
- src/promptflow-devkit/promptflow/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
from promptflow._sdk._user_agent import USER_AGENT
from promptflow._sdk.entities._trace import Span
from promptflow._utils.logger_utils import get_cli_sdk_logger
from promptflow._utils.user_agent_utils import ClientUserAgentUtil, setup_user_agent_to_operation_context
from promptflow._utils.user_agent_utils import setup_user_agent_to_operation_context
from promptflow.core._errors import MissingRequiredPackage

from .general_utils import convert_time_unix_nano_to_timestamp, json_load
Expand Down Expand Up @@ -347,8 +347,8 @@ class TraceTelemetryHelper:
CUSTOM_DIMENSIONS_TRACE_COUNT = "trace_count"

def __init__(self):
setup_user_agent_to_operation_context(USER_AGENT)
self._user_agent = ClientUserAgentUtil.get_user_agent()
# `setup_user_agent_to_operation_context` will get user agent and return
self._user_agent = setup_user_agent_to_operation_context(USER_AGENT)
self._telemetry_logger = get_telemetry_logger()
self._lock = multiprocessing.Lock()
self._summary: typing.Dict[TraceCountKey, int] = dict()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,5 @@
'ad585ee1806aae44c095f4b3e473e472bb8be141', (91136, 1272)
'ea48203d881e43bd9e027a19525ba88816c9a639', (92672, 14393)
'e53962d6670e3c446a659b93e8ff5900f82bce76', (107520, 14391)
'b3e2c3c192f72b517f5d32e5f416b1f818922bbd', (122368, 3698)
'17d268bf2d53b839d08502d3a92c6ce0f5e67fdd', (126464, 916)
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,5 @@
'ad585ee1806aae44c095f4b3e473e472bb8be141', (91136, 1272)
'ea48203d881e43bd9e027a19525ba88816c9a639', (92672, 14393)
'e53962d6670e3c446a659b93e8ff5900f82bce76', (107520, 14391)
'b3e2c3c192f72b517f5d32e5f416b1f818922bbd', (122368, 3698)
'17d268bf2d53b839d08502d3a92c6ce0f5e67fdd', (126464, 916)
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ def completion(connection: AzureOpenAIConnection, prompt: str, stream: bool) ->
if IS_LEGACY_OPENAI:
completion = openai.Completion.create(
prompt=prompt,
engine="text-ada-001",
engine="gpt-35-turbo-instruct",
max_tokens=256,
temperature=0.8,
top_p=1.0,
Expand All @@ -40,7 +40,7 @@ def completion(connection: AzureOpenAIConnection, prompt: str, stream: bool) ->
else:
completion = get_client(connection).completions.create(
prompt=prompt,
model="text-ada-001",
model="gpt-35-turbo-instruct",
max_tokens=256,
temperature=0.8,
top_p=1.0,
Expand Down
Loading