diff --git a/.env.example b/.env.example index b34acab..8ea5abd 100644 --- a/.env.example +++ b/.env.example @@ -1,4 +1,9 @@ APP_ENV=development #APP_ENV=production -OPENAI_API_KEY=sk-... \ No newline at end of file +BITO_CLI_PATH=bito + +ERNIE_API_KEY=... +ERNIE_SECRET_KEY=... + +OPENAI_API_KEY=sk-... diff --git a/config/ai-commit.php b/config/ai-commit.php index 61c6e43..7a7c769 100644 --- a/config/ai-commit.php +++ b/config/ai-commit.php @@ -70,6 +70,32 @@ 'timeout' => 120, ], ], + 'ernie_bot' => [ + 'driver' => 'ernie_bot', + 'http_options' => [], + 'api_key' => env('ERNIE_API_KEY', '...'), + 'secret_key' => env('ERNIE_SECRET_KEY', '...'), + 'parameters' => [ + // 'messages' => 'required|array', + 'temperature' => 0.95, + 'top_p' => 0.8, + 'penalty_score' => 1.0, + 'stream' => true, + ], + ], + 'ernie_bot_turbo' => [ + 'driver' => 'ernie_bot_turbo', + 'http_options' => [], + 'api_key' => env('ERNIE_API_KEY', '...'), + 'secret_key' => env('ERNIE_SECRET_KEY', '...'), + 'parameters' => [ + // 'messages' => 'required|array', + 'temperature' => 0.95, + 'top_p' => 0.8, + 'penalty_score' => 1.0, + 'stream' => true, + ], + ], 'openai' => [ 'driver' => 'openai', 'api_key' => env('OPENAI_API_KEY', 'sk-...'), @@ -111,32 +137,6 @@ // 'logit_bias' => null, ], ], - 'ernie_bot' => [ - 'driver' => 'ernie_bot', - 'http_options' => [], - 'api_key' => env('ERNIE_API_KEY', '...'), - 'secret_key' => env('ERNIE_SECRET_KEY', '...'), - 'parameters' => [ - // 'messages' => 'required|array', - 'temperature' => 0.95, - 'top_p' => 0.8, - 'penalty_score' => 1.0, - 'stream' => true, - ], - ], - 'ernie_bot_turbo' => [ - 'driver' => 'ernie_bot_turbo', - 'http_options' => [], - 'api_key' => env('ERNIE_API_KEY', '...'), - 'secret_key' => env('ERNIE_SECRET_KEY', '...'), - 'parameters' => [ - // 'messages' => 'required|array', - 'temperature' => 0.95, - 'top_p' => 0.8, - 'penalty_score' => 1.0, - 'stream' => true, - ], - ], ], /**