add stepfun models

This commit is contained in:
chenlinfeng
2024-08-16 16:31:42 +08:00
parent 122aa94c9f
commit e29ea54f2c
11 changed files with 521 additions and 3 deletions

View File

@@ -62,6 +62,10 @@ declare global {
TENCENT_SECRET_KEY?: string;
TENCENT_SECRET_ID?: string;
// stepfun only
STEPFUN_URL?: string;
STEPFUN_API_KEY?: string;
// moonshot only
MOONSHOT_URL?: string;
MOONSHOT_API_KEY?: string;
@@ -137,6 +141,7 @@ export const getServerSideConfig = () => {
const isGoogle = !!process.env.GOOGLE_API_KEY;
const isAnthropic = !!process.env.ANTHROPIC_API_KEY;
const isTencent = !!process.env.TENCENT_API_KEY;
const isStepfun = !!process.env.STEPFUN_API_KEY;
const isBaidu = !!process.env.BAIDU_API_KEY;
const isBytedance = !!process.env.BYTEDANCE_API_KEY;
@@ -196,6 +201,10 @@ export const getServerSideConfig = () => {
tencentSecretKey: getApiKey(process.env.TENCENT_SECRET_KEY),
tencentSecretId: process.env.TENCENT_SECRET_ID,
isStepfun,
stepfunUrl: process.env.STEPFUN_URL,
stepfunApiKey: getApiKey(process.env.STEPFUN_API_KEY),
isMoonshot,
moonshotUrl: process.env.MOONSHOT_URL,
moonshotApiKey: getApiKey(process.env.MOONSHOT_API_KEY),