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

Feature/add proxy configuration #423

Open
wants to merge 12 commits into
base: dev
Choose a base branch
from

Conversation

ByJacob
Copy link
Contributor

@ByJacob ByJacob commented Oct 17, 2024

Pull Request Description 🚀

Overview

This pull request updates the Azure library and introduces new features for enhanced configuration options.

Features

  • Updated Azure Library: Upgraded to the latest version for improved functionality. 📚
  • HTTP Proxy Configuration:
    • Added the ability to configure an HTTP proxy for OpenAI and Azure providers. 🌐
    • Note: Proxy features cannot be added for all providers due to differing SDKs and the inability to test all configurations. However, this provides a solid foundation for implementing proxy support for additional clients in the future. 🛠️
  • Custom CA Configuration:
    • Allowed configuration of extra Certificate Authorities (CAs) for the HTTP agent. 🏛️
  • Client Certificate Support:
    • Enabled the use of client certificates when connecting to APIs. 🔑

Documentation

  • Updated relevant documentation to reflect changes in library usage and new configuration options. 📄

Notes

  • Please review the changes and provide feedback. 💬

Thank you! 🙏

…h to different LLM providers and configure additional settings like proxy and CA bundle

📝 (package.json): update devDependencies to include required types packages for follow-redirects, and add dependencies for http-proxy-agent and https-proxy-agent
♻️ (config.ts): refactor config.ts to include new configuration options for HTTP proxy, CA bundle, timeout, verify SSL, client certificate, and API version
🚀 (azure.ts): update azure.ts to use the new OpenAI package and pass the HTTP agent to handle proxy settings
♻️ (groq.ts): refactor groq.ts to use OpenAI package instead of the deprecated @azure/openai package
♻️ (openAi.ts): refactor openAi.ts to use OpenAI package instead of the deprecated @azure/openai package, and pass the HTTP agent to handle proxy settings
🚀 (set_missing_default_values.ts): add new migration to set missing default values in global config file
♻️ (engine.ts): refactor engine.ts to include API version in the default config object
🔧 (httpAgent.ts): add new httpAgent utility to handle HTTP settings including proxy, CA bundle, timeout, verify SSL, and client certificate
…it from Docker build

⬆️ (package.json): upgrade version from 3.2.2 to 3.2.3 in package.json
♻️ (httpAgent.ts): refactor code in getHttpAgent function to improve readability and maintainability
@di-sukharev di-sukharev changed the base branch from master to dev November 19, 2024 17:58
@di-sukharev di-sukharev changed the base branch from dev to master November 19, 2024 17:58
}

export class AzureEngine implements AiEngine {
config: AzureAiEngineConfig;
client: AzureOpenAIClient;
client: OpenAI;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

are you sure about this?

@@ -1,6 +1,6 @@
import migration00 from './00_use_single_api_key_and_url';
import migration01 from './01_remove_obsolete_config_keys_from_global_file';
import migration02 from './02_set_missing_default_values';
import migration03 from './03_set_missing_default_values';
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why? is there a typo?

@di-sukharev
Copy link
Owner

@ByJacob nice job, left few comments, also pls change the base branch to dev (we first merge there) and solve conflicts (there are few). to solve the /out dir conflict — just rebuild the package

@di-sukharev
Copy link
Owner

@ByJacob pls let me know when you fix conflicts, i will merge this as soon as you are ready

di-sukharev and others added 8 commits December 14, 2024 20:02
* 378: fix hook env (di-sukharev#402)

* fix(prepare-commit-msg-hook): update error handling to provide clearer instructions for setting API keys and improve user guidance

* Fix: a bug that causes an error when pushing without setting git remote (di-sukharev#396)

* update deploy commands

* feat(cli): add context flag for providing additional commit message input

* Fix [Bug]: punycode` module is deprecated di-sukharev#426 (di-sukharev#433)

Signed-off-by: Tiger Kaovilai <passawit.kaovilai@gmail.com>

* npm audit fix (di-sukharev#432)

Signed-off-by: Tiger Kaovilai <passawit.kaovilai@gmail.com>

* Feat: Add an option to `Don't push` when there are multiple git remotes (di-sukharev#434)

---------

Co-authored-by: GPT8 <57486732+di-sukharev@users.noreply.github.com>

* feat(engine): add support for MLX AI provider (di-sukharev#437)

---------

Signed-off-by: Emmanuel Ferdman <emmanuelferdman@gmail.com>
Co-authored-by: Emmanuel Ferdman <emmanuelferdman@gmail.com>

* feat(config, engine): add support for Mistral AI provider and engine (di-sukharev#436)

* docs(CONTRIBUTING.md): update `TODO.md` reference (di-sukharev#435)

Signed-off-by: Emmanuel Ferdman <emmanuelferdman@gmail.com>

* feat(config, engine): add support for Mistral AI provider and engine

* ```
feat(package): add mistralai and zod dependencies
```

* fix: recreate package-lock.json with node20

* fix: recreate package-lock.json with node v20.18.1 based on branch dev

---------

Signed-off-by: Emmanuel Ferdman <emmanuelferdman@gmail.com>
Co-authored-by: Emmanuel Ferdman <emmanuelferdman@gmail.com>
Co-authored-by: pedro-valentim <>

---------

Signed-off-by: Tiger Kaovilai <passawit.kaovilai@gmail.com>
Signed-off-by: Emmanuel Ferdman <emmanuelferdman@gmail.com>
Co-authored-by: Takanori Matsumoto <matscube@gmail.com>
Co-authored-by: BILLY Maxime <ozeliurs@gmail.com>
Co-authored-by: Welington Sampaio <welington.sampaio@icloud.com>
Co-authored-by: Tiger Kaovilai <passawit.kaovilai@gmail.com>
Co-authored-by: albi ⚡️ <sigismondi.alberto@gmail.com>
Co-authored-by: Emmanuel Ferdman <emmanuelferdman@gmail.com>
Co-authored-by: Pedro Valentim Silva Leite <18179935+pedro-valentim@users.noreply.github.com>
@di-sukharev
Copy link
Owner

@ByJacob dude?

@ByJacob ByJacob changed the base branch from master to dev January 20, 2025 13:09
@ByJacob
Copy link
Contributor Author

ByJacob commented Jan 20, 2025

@ByJacob dude?

Hi i merge with dev branch

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants