Skip to content

Commit

Permalink
docs: switch default model references to gpt-4o across the project
Browse files Browse the repository at this point in the history
- Update model references from `gpt-3.5-turbo` to `gpt-4o` in README.md and README.zh-tw.md
- Change default OpenAI model to `gpt-4o` in configuration settings
- Modify example commands to use `gpt-4o` model instead of `gpt-3.5-turbo`
- Update commit command flag default model to `gpt-4o` in commit.go

Signed-off-by: Bo-Yi Wu <[email protected]>
  • Loading branch information
appleboy committed Feb 13, 2025
1 parent 3e476eb commit 62a3c8d
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 19 deletions.
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

English | [繁體中文](./README.zh-tw.md)

A CLI written in [Go](https://go.dev) that writes git commit messages or provides a code review summary for you using ChatGPT AI (gpt-3.5-turbo, gpt-4 model) and automatically installs a [git prepare-commit-msg hook](https://git-scm.com/docs/githooks).
A CLI written in [Go](https://go.dev) that writes git commit messages or provides a code review summary for you using ChatGPT AI (gpt-4o, gpt-4 model) and automatically installs a [git prepare-commit-msg hook](https://git-scm.com/docs/githooks).

- [繁體中文介紹][1]
- [繁體中文影片][2]
Expand All @@ -27,7 +27,7 @@ A CLI written in [Go](https://go.dev) that writes git commit messages or provide
- Supports excluding files from the git diff command.
- Supports commit message translation into another language (supports `en`, `zh-tw`, or `zh-cn`).
- Supports socks proxy or custom network HTTP proxy.
- Supports [model lists](https://github.com/appleboy/CodeGPT/blob/bf28f000463cfc6dfa2572df61e1b160c5c680f7/openai/openai.go#L18-L38) like `gpt-4`, `gpt-3.5-turbo`, etc.
- Supports [model lists](https://github.com/appleboy/CodeGPT/blob/bf28f000463cfc6dfa2572df61e1b160c5c680f7/openai/openai.go#L18-L38) like `gpt-4`, `gpt-4o`, etc.
- Supports generating a brief code review.

![code review](./images/code_review.png)
Expand Down Expand Up @@ -87,7 +87,7 @@ This will create a `.codegpt.yaml` file in your home directory ($HOME/.config/co
| **openai.base_url** | Replace the default base URL (`https://api.openai.com/v1`). |
| **openai.api_key** | Generate API key from [openai platform page](https://platform.openai.com/account/api-keys). |
| **openai.org_id** | Identifier for this organization sometimes used in API requests. See [organization settings](https://platform.openai.com/account/org-settings). Only for `openai` service. |
| **openai.model** | Default model is `gpt-3.5-turbo`, you can change to `gpt-4-turbo` or other custom model (Groq or OpenRouter provider). |
| **openai.model** | Default model is `gpt-4o`, you can change to other custom model (Groq or OpenRouter provider). |
| **openai.proxy** | HTTP/HTTPS client proxy. |
| **openai.socks** | SOCKS client proxy. |
| **openai.timeout** | Default HTTP timeout is `10s` (ten seconds). |
Expand Down Expand Up @@ -179,7 +179,7 @@ We can use the Llama3 model from the [ollama][41] API Service, please visit [her
```sh
# pull llama3 8b model
ollama pull llama3
ollama cp llama3 gpt-3.5-turbo
ollama cp llama3 gpt-4o
```

Try to use the `ollama` API Service.
Expand All @@ -188,7 +188,7 @@ Try to use the `ollama` API Service.
curl http://localhost:11434/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{
"model": "gpt-3.5-turbo",
"model": "gpt-4o",
"messages": [
{
"role": "user",
Expand Down Expand Up @@ -247,7 +247,7 @@ codegpt commit --preview
The commit message is shown below.

```sh
Summarize the commit message use gpt-3.5-turbo model
Summarize the commit message use gpt-4o model
We are trying to summarize a git diff
We are trying to summarize a title for pull request
================Commit Summary====================
Expand All @@ -270,7 +270,7 @@ codegpt commit --lang zh-tw --preview
Consider the following outcome:

```sh
Summarize the commit message use gpt-3.5-turbo model
Summarize the commit message use gpt-4o model
We are trying to summarize a git diff
We are trying to summarize a title for pull request
We are trying to translate a git commit message to Traditional Chinese language
Expand Down Expand Up @@ -374,7 +374,7 @@ git commit
```sh
$ git commit
Summarize the commit message use gpt-3.5-turbo model
Summarize the commit message use gpt-4o model
We are trying to summarize a git diff
We are trying to summarize a title for pull request
================Commit Summary====================
Expand Down Expand Up @@ -409,7 +409,7 @@ codegpt review --lang zh-tw
See the following result:
```sh
Code review your changes using gpt-3.5-turbo model
Code review your changes using gpt-4o model
We are trying to review code changes
PromptTokens: 1021, CompletionTokens: 200, TotalTokens: 1221
We are trying to translate core review to Traditional Chinese language
Expand Down
18 changes: 9 additions & 9 deletions README.zh-tw.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

[English](./README.md) | 繁體中文

一個用 [Go](https://go.dev) 編寫的 CLI 工具,使用 ChatGPT AI(gpt-3.5-turbo, gpt-4 模型)為你撰寫 git 提交訊息或提供程式碼審查摘要,並自動安裝 [git prepare-commit-msg hook](https://git-scm.com/docs/githooks)
一個用 [Go](https://go.dev) 編寫的 CLI 工具,使用 ChatGPT AI(gpt-4o, gpt-4 模型)為你撰寫 git 提交訊息或提供程式碼審查摘要,並自動安裝 [git prepare-commit-msg hook](https://git-scm.com/docs/githooks)

- [繁體中文介紹][1]
- [繁體中文影片][2]
Expand All @@ -27,7 +27,7 @@
- 支援從 git diff 命令中排除文件。
- 支援將提交訊息翻譯成其他語言(支援 `en``zh-tw``zh-cn`)。
- 支援 socks 代理或自訂網路 HTTP 代理。
- 支援 [模型列表](https://github.com/appleboy/CodeGPT/blob/bf28f000463cfc6dfa2572df61e1b160c5c680f7/openai/openai.go#L18-L38),如 `gpt-4``gpt-3.5-turbo` 等。
- 支援 [模型列表](https://github.com/appleboy/CodeGPT/blob/bf28f000463cfc6dfa2572df61e1b160c5c680f7/openai/openai.go#L18-L38),如 `gpt-4``gpt-4o` 等。
- 支援生成簡要的程式碼審查。

![code review](./images/code_review.png)
Expand Down Expand Up @@ -87,7 +87,7 @@ codegpt config set openai.api_key sk-xxxxxxx
| **openai.base_url** | 替換默認的基礎 URL (`https://api.openai.com/v1`)。 |
| **openai.api_key** |[openai 平台頁面](https://platform.openai.com/account/api-keys) 生成 API 金鑰。 |
| **openai.org_id** | 在 API 請求中有時使用的組織標識符。請參閱 [組織設置](https://platform.openai.com/account/org-settings)。僅適用於 `openai` 服務。 |
| **openai.model** | 默認模型是 `gpt-3.5-turbo`,你可以更改為 `gpt-4-turbo` 或其他自訂模型(Groq 或 OpenRouter 提供者)。 |
| **openai.model** | 默認模型是 `gpt-4o`,你可以更改為 `gpt-4-turbo` 或其他自訂模型(Groq 或 OpenRouter 提供者)。 |
| **openai.proxy** | HTTP/HTTPS 客戶端代理。 |
| **openai.socks** | SOCKS 客戶端代理。 |
| **openai.timeout** | 默認 HTTP 超時為 `10s`(十秒)。 |
Expand Down Expand Up @@ -179,7 +179,7 @@ GroqCloud 目前支援[以下模型][32]:
```sh
# 拉取 llama3 8b 模型
ollama pull llama3
ollama cp llama3 gpt-3.5-turbo
ollama cp llama3 gpt-4o
```

嘗試使用 `ollama` API 服務。
Expand All @@ -188,7 +188,7 @@ ollama cp llama3 gpt-3.5-turbo
curl http://localhost:11434/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{
"model": "gpt-3.5-turbo",
"model": "gpt-4o",
"messages": [
{
"role": "user",
Expand Down Expand Up @@ -247,7 +247,7 @@ codegpt commit --preview
提交訊息如下所示。

```sh
Summarize the commit message use gpt-3.5-turbo model
Summarize the commit message use gpt-4o model
We are trying to summarize a git diff
We are trying to summarize a title for pull request
================Commit Summary====================
Expand All @@ -270,7 +270,7 @@ codegpt commit --lang zh-tw --preview
Consider the following outcome:

```sh
Summarize the commit message use gpt-3.5-turbo model
Summarize the commit message use gpt-4o model
We are trying to summarize a git diff
We are trying to summarize a title for pull request
We are trying to translate a git commit message to Traditional Chinese language
Expand Down Expand Up @@ -374,7 +374,7 @@ git commit
```sh
$ git commit
Summarize the commit message use gpt-3.5-turbo model
Summarize the commit message use gpt-4o model
We are trying to summarize a git diff
We are trying to summarize a title for pull request
================Commit Summary====================
Expand Down Expand Up @@ -409,7 +409,7 @@ codegpt review --lang zh-tw
請參閱以下結果:
```sh
Code review your changes using gpt-3.5-turbo model
Code review your changes using gpt-4o model
We are trying to review code changes
PromptTokens: 1021, CompletionTokens: 200, TotalTokens: 1221
We are trying to translate core review to Traditional Chinese language
Expand Down
2 changes: 1 addition & 1 deletion cmd/commit.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ func init() {
commitCmd.PersistentFlags().BoolVar(&preview, "preview", false, "preview commit message")
commitCmd.PersistentFlags().IntVar(&diffUnified, "diff_unified", 3,
"generate diffs with <n> lines of context, default is 3")
commitCmd.PersistentFlags().StringVar(&commitModel, "model", "gpt-3.5-turbo", "select openai model")
commitCmd.PersistentFlags().StringVar(&commitModel, "model", "gpt-4o", "select openai model")
commitCmd.PersistentFlags().StringVar(&commitLang, "lang", "en", "summarizing language uses English by default")
commitCmd.PersistentFlags().StringSliceVar(&excludeList, "exclude_list", []string{},
"exclude file from git diff command")
Expand Down

0 comments on commit 62a3c8d

Please sign in to comment.