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

Adding Gemini support #132

Open
ykeremy opened this issue Mar 28, 2024 · 5 comments
Open

Adding Gemini support #132

ykeremy opened this issue Mar 28, 2024 · 5 comments
Assignees
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@ykeremy
Copy link
Contributor

ykeremy commented Mar 28, 2024

LiteLLM docs for Gemini: https://litellm.vercel.app/docs/providers/gemini

Required steps for integrating a new LLM model:

  1. Define the required variables for the new models

#####################
# LLM Configuration #
#####################
# ACTIVE LLM PROVIDER
LLM_KEY: str = "OPENAI_GPT4V"
# COMMON
LLM_CONFIG_MAX_TOKENS: int = 4096
LLM_CONFIG_TEMPERATURE: float = 0
# LLM PROVIDER SPECIFIC
ENABLE_OPENAI: bool = True
ENABLE_ANTHROPIC: bool = False
ENABLE_AZURE: bool = False
# OPENAI
OPENAI_API_KEY: str | None = None
# ANTHROPIC
ANTHROPIC_API_KEY: str | None = None
# AZURE
AZURE_DEPLOYMENT: str | None = None
AZURE_API_KEY: str | None = None
AZURE_API_BASE: str | None = None
AZURE_API_VERSION: str | None = None

  1. Implement the configuration for the new models and register them

if SettingsManager.get_settings().ENABLE_OPENAI:
LLMConfigRegistry.register_config("OPENAI_GPT4_TURBO", LLMConfig("gpt-4-turbo-preview", ["OPENAI_API_KEY"], False))
LLMConfigRegistry.register_config("OPENAI_GPT4V", LLMConfig("gpt-4-vision-preview", ["OPENAI_API_KEY"], True))

  1. Update Skyvern setup script with the LLM configuration options

setup_llm_providers() {

@ykeremy ykeremy added enhancement New feature or request good first issue Good for newcomers labels Mar 28, 2024
@unaisshemim
Copy link

Can you assign this to me

@ykeremy
Copy link
Contributor Author

ykeremy commented Apr 3, 2024

🎉 Let us know if you have any question / need any help. Happy coding!

@unaisshemim
Copy link

Is there any thing should be changed in the .env.example file

@unaisshemim
Copy link

Is there any specific code formatter using here

Copy link

github-actions bot commented May 4, 2024

This issue is stale because it has been open for 30 days with no activity.

@github-actions github-actions bot added the Stale label May 4, 2024
@suchintan suchintan removed the Stale label May 6, 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 good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

3 participants