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

Support custom providers #530

Merged
merged 9 commits into from
Apr 3, 2024
3 changes: 1 addition & 2 deletions src/components/Message/AppMessage/Instructions.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import {

import MessageBase, { type MessageBaseProps } from "../MessageBase";
import { ChatCraftAppMessage } from "../../../lib/ChatCraftMessage";
import { providerFromUrl, getSupportedProviders } from "../../../lib/providers";
import { providerFromUrl, supportedProviders } from "../../../lib/providers";
import { OpenRouterProvider } from "../../../lib/providers/OpenRouterProvider";
import RevealablePasswordInput from "../../RevealablePasswordInput";
import { useSettings } from "../../../hooks/use-settings";
Expand Down Expand Up @@ -57,7 +57,6 @@ function Instructions(props: MessageBaseProps) {
const { settings, setSettings } = useSettings();
const [isValidating, setIsValidating] = useState(false);
const [isInvalid, setIsInvalid] = useState(false);
const supportedProviders = getSupportedProviders();

// Override the text of the message
const message = new ChatCraftAppMessage({ ...props.message, text: ApiKeyInstructionsText });
Expand Down