[llm-polyglot] Add Azure OpenAI support to the polyglot#86
[llm-polyglot] Add Azure OpenAI support to the polyglot#86RollForReflex wants to merge 7 commits into
Conversation
🦋 Changeset detectedLatest commit: 0d46236 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
There was a problem hiding this comment.
👍 Looks good to me! Reviewed everything up to 8024004 in 37 seconds
More details
- Looked at
294lines of code in11files - Skipped
0files when reviewing. - Skipped posting
2drafted comments based on config settings.
1. .github/workflows/test-pr.yml:25
- Draft comment:
The environment variableAZURE_API_KEYshould beAZURE_OPENAI_API_KEYto be consistent with the naming convention used intest.yml. - Reason this comment was not posted:
Decided after close inspection that this draft comment was likely wrong and/or not actionable:
While consistency in naming conventions is good, I can't verify if this is actually inconsistent since I can't see test.yml. The comment could be correct, but without seeing the other file, I can't be certain. Following the principle of removing comments unless there's strong evidence they're correct, this should be removed.
The naming convention could be important for the application to work correctly, and removing this comment might lead to integration issues.
If the naming is critical for functionality, it would be caught by tests or build failures. This is more of a style suggestion that we can't verify without more context.
Delete the comment since we can't verify its accuracy without seeing test.yml, and if the naming was critical, it would be caught by tests.
2. public-packages/llm-client/src/providers/anthropic/index.ts:46
- Draft comment:
The logger name is incorrectly set to 'GEMINI-CLIENT'. It should be 'ANTHROPIC-CLIENT'. - Reason this comment was not posted:
Comment looked like it was already resolved.
Workflow ID: wflow_dHi4gHZcBsAdCOOV
You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.
There was a problem hiding this comment.
👍 Looks good to me! Incremental review on cd02a13 in 12 seconds
More details
- Looked at
14lines of code in1files - Skipped
0files when reviewing. - Skipped posting
1drafted comments based on config settings.
1. .github/workflows/test-pr.yml:25
- Draft comment:
TheAZURE_API_KEYenvironment variable is missing. Ensure it is added if required by the code. - Reason this comment was not posted:
Comment did not seem useful.
Workflow ID: wflow_JGYneopJACO8rOYR
You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.
There was a problem hiding this comment.
👍 Looks good to me! Incremental review on 223cd49 in 10 seconds
More details
- Looked at
15lines of code in1files - Skipped
0files when reviewing. - Skipped posting
1drafted comments based on config settings.
1. public-packages/llm-client/tests/azure-oai.test.ts:4
- Draft comment:
Ensure that environment variablesAZURE_OPENAI_API_KEYandAZURE_OPENAI_ENDPOINTare set before running tests to avoid undefined errors. - Reason this comment was not posted:
Confidence changes required:50%
The test setup should handle missing environment variables more gracefully.
Workflow ID: wflow_EjdtBbQLyVEneEb4
You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.
There was a problem hiding this comment.
👍 Looks good to me! Incremental review on 32c92ee in 13 seconds
More details
- Looked at
33lines of code in1files - Skipped
0files when reviewing. - Skipped posting
1drafted comments based on config settings.
1. public-packages/llm-client/src/types/index.ts:7
- Draft comment:
Ensure thatAzureOpenAIis correctly imported from theopenaipackage. IfAzureOpenAIis not defined in theopenaipackage, this will lead to a runtime error. - Reason this comment was not posted:
Comment did not seem useful.
Workflow ID: wflow_0iYGi5UJ9O7zjHBZ
You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.
There was a problem hiding this comment.
👍 Looks good to me! Incremental review on 03e101b in 39 seconds
More details
- Looked at
31lines of code in2files - Skipped
0files when reviewing. - Skipped posting
2drafted comments based on config settings.
1. public-packages/llm-client/tests/azure-oai.test.ts:4
- Draft comment:
Consider adding checks to ensureAZURE_OPENAI_API_KEYandAZURE_OPENAI_ENDPOINTare set before creating the client. This will prevent runtime errors if the environment variables are missing. - Reason this comment was not posted:
Decided after close inspection that this draft comment was likely wrong and/or not actionable:
The tests are running successfully without the environment variables, which suggests they aren't actually required. The removal of these variables was intentional. Since this is a test file, if the environment variables were required, the tests would fail. The fact that they were removed suggests the library has default behavior or mock functionality for tests.
Maybe there's some configuration I'm not seeing that makes these variables required in production but not in tests? Maybe the tests are using mock credentials internally?
Even if that's true, this is a test file and the tests are clearly working without these variables. The comment is suggesting adding complexity that the tests demonstrate isn't needed.
Delete the comment. The tests prove the environment variables aren't required, and the removal was intentional.
2. public-packages/llm-client/tests/azure-oai.test.ts:5
- Draft comment:
Consider making the model name configurable or checking its availability to avoid potential issues if the model name changes or is unavailable. - Reason this comment was not posted:
Confidence changes required:50%
The test file uses a specific model name 'gpt-4o-mini' which might not be available or could change. It's better to make this configurable.
Workflow ID: wflow_CllaLx6uh6G3pXnL
You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.
There was a problem hiding this comment.
Skipped PR review on 9a31193 because no changed files had a supported extension. If you think this was in error, please contact us and we'll fix it right away.
There was a problem hiding this comment.
👍 Looks good to me! Incremental review on 0d46236 in 8 seconds
More details
- Looked at
11lines of code in1files - Skipped
0files when reviewing. - Skipped posting
1drafted comments based on config settings.
1. .changeset/ten-buttons-scream.md:1
- Draft comment:
The changeset file is correctly formatted and provides a clear description of the change. No issues here. - Reason this comment was not posted:
Confidence changes required:0%
The changeset file is correctly formatted and provides a clear description of the change. No issues here.
Workflow ID: wflow_9P5qvgCPtLI4H6sZ
You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.
Important
Adds Azure OpenAI support to
llm-polyglot, including a new provider class, environment variables, documentation, and tests.AzureOpenAIProviderclass insrc/providers/azure/index.ts.LLMClientinsrc/index.tsto supportazure-openaiprovider.LLMClientOptionsinsrc/types/index.ts.AZURE_OPENAI_API_KEYandAZURE_OPENAI_ENDPOINTtotest-pr.yml,test.yml, andturbo.json.README.mdto include Azure OpenAI installation and usage instructions.@azure/openaitopeerDependenciesanddevDependenciesinpackage.json.azure-oai.test.tsfor Azure OpenAI provider tests.This description was created by
for 0d46236. It will automatically update as commits are pushed.