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

feat: add OpenRouter api #13

Merged
merged 7 commits into from
Mar 10, 2025
Merged

feat: add OpenRouter api #13

merged 7 commits into from
Mar 10, 2025

Conversation

cubxxw
Copy link
Member

@cubxxw cubxxw commented Mar 10, 2025

This pull request introduces support for the OpenRouter AI provider, including configuration settings, API integration, and UI updates. The changes span multiple files to ensure seamless integration and functionality.

Key Changes:

Configuration and Environment:

  • Added OpenRouter configuration settings in .env.example to allow setting up API keys, base URL, site URL, site name, and additional models.

Backend Integration:

  • Enhanced proxy-server.js to include detailed logging and error handling for Huoshan API requests and responses.
  • Integrated OpenRouter API calls in aiService.ts, including methods for handling requests and responses, and added support for additional models via environment variables. [1] [2] [3] [4] [5]

Frontend Updates:

  • Updated AISettings.tsx to include new tabs and forms for configuring Huoshan, Qwen, and OpenRouter settings. [1] [2] [3]
  • Modified AddPromptModal.tsx to add OpenRouter models to the selectable options.

Type Definitions:

  • Updated index.ts to include new LLM models and AI providers for OpenRouter. [1] [2]

@cubxxw cubxxw merged commit d2f7a54 into main Mar 10, 2025
2 of 4 checks passed
@cubxxw cubxxw deleted the feat/cicd-optimize branch March 10, 2025 07:46
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.

1 participant