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

Add Azure OpenAI support to RAFT's raft.py #382

Closed
cedricvidal opened this issue Apr 23, 2024 · 0 comments · Fixed by #381
Closed

Add Azure OpenAI support to RAFT's raft.py #382

cedricvidal opened this issue Apr 23, 2024 · 0 comments · Fixed by #381
Labels
enhancement New feature or request

Comments

@cedricvidal
Copy link
Contributor

cedricvidal commented Apr 23, 2024

Currently, while it is possible to use Azure to run the fine-tuning, it is not currently possible to generate the fine-tuning dataset using Azure OpenAI.

Adding support for running the raft.py script using Azure OpenAI deployments would be very useful for Azure users.

Note: doesn't cover eval.py

@cedricvidal cedricvidal added the enhancement New feature or request label Apr 23, 2024
ShishirPatil pushed a commit that referenced this issue Apr 26, 2024
- Added `--embedding-model` CLI arg defaults to text-embedding-ada-002.
Used to generate the chunks embeddings
- Added `--completion-model` CLI arg defaults to gpt-4. Used to generate
the Q/A dataset
- New client_utils.py with two helpers: `build_openai_client` and
`build_langchain_embeddings`.
- `build_openai_client` builds an `OpenAI` or `AzureOpenAI` client based
on detecting `AZURE_*` specific env vars or not
- `build_langchain_embeddings` builds a `AzureOpenAIEmbeddings` or
`OpenAIEmbeddings` based on detecting `AZURE_*` specific env vars or not
- Loads environment variables from .env file using python-dotenv package
- Added dependency on python-dotenv
- Added doc to README

Fixes #382
@cedricvidal cedricvidal changed the title Add Azure OpenAI support to RAFT's raft.py and eval.py Add Azure OpenAI support to RAFT's raft.py Apr 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant