-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
š (environment.ts): Update environment variables to match the changesā¦
ā¦ in the .env.example file
- Loading branch information
Showing
8 changed files
with
76 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,14 @@ | ||
PORT=3001 | ||
NODE_ENV=development # koyeb ķź²½ ė³ģ ģ¤ģ ģ“ė ė§ģ¶źø° ģķ“ ģ¶ź° | ||
CORS_ORIGIN= | ||
|
||
OPENAI_API_KEY= | ||
|
||
REDIS_HOST= | ||
REDIS_PORT= | ||
REDIS_USERNAME= | ||
REDIS_PASSWORD= | ||
CORS_ORIGIN= | ||
FINE_TUNED_ID= | ||
|
||
|
||
MODEL_NAME_GPT_3_5_FT= | ||
MODEL_NAME_GPT_3_5= | ||
MODEL_NAME_GPT_4= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,38 @@ | ||
import { FINE_TUNED_ID } from '@/config'; | ||
import { | ||
MODEL_NAME_GPT_3_5, | ||
MODEL_NAME_GPT_3_5_FT, | ||
MODEL_NAME_GPT_4, | ||
} from '@/config'; | ||
import { ANALYZER_REDIS_SCHEMA } from '@/services/redis'; | ||
|
||
const { FIELDS } = ANALYZER_REDIS_SCHEMA; | ||
|
||
const FINE_TUNE_SUFFIX = '_fine_tuned'; | ||
|
||
export enum GPTModel { | ||
GPT_3 = 'gpt-3.5-turbo', | ||
export enum AIModelKey { | ||
GPT_3_5 = 'gpt-3.5', | ||
GPT_3_5_FT = 'gpt-3.5-ft', | ||
GPT_4 = 'gpt-4', | ||
} | ||
|
||
export const GPT_MODEL_LIST = Object.values(GPTModel); | ||
export const AI_MODEL = { | ||
[AIModelKey.GPT_3_5]: MODEL_NAME_GPT_3_5, | ||
[AIModelKey.GPT_3_5_FT]: MODEL_NAME_GPT_3_5_FT, | ||
[AIModelKey.GPT_4]: MODEL_NAME_GPT_4, | ||
}; | ||
|
||
export const ANALYSIS_MODEL_OPTIONS = { | ||
[GPTModel.GPT_3]: { | ||
export const ANALYSIS_MODEL_OPTION = { | ||
[AIModelKey.GPT_3_5_FT]: { | ||
promptField: FIELDS.ANALYSIS + FINE_TUNE_SUFFIX, | ||
temperature: 0.6, | ||
modelName: FINE_TUNED_ID ?? GPTModel.GPT_3, | ||
modelName: AI_MODEL[AIModelKey.GPT_3_5_FT], | ||
}, | ||
[GPTModel.GPT_4]: { | ||
[AIModelKey.GPT_4]: { | ||
promptField: FIELDS.ANALYSIS, | ||
temperature: 0.4, | ||
modelName: GPTModel.GPT_4, | ||
modelName: AI_MODEL[AIModelKey.GPT_4], | ||
}, | ||
} as const; | ||
}; | ||
|
||
export const ANALYSIS_MODEL = Object.keys(ANALYSIS_MODEL_OPTION); | ||
export type AnalysisModel = keyof typeof ANALYSIS_MODEL_OPTION; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters