gac 1.11.1__py3-none-any.whl → 1.12.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of gac might be problematic. Click here for more details.
- gac/__version__.py +1 -1
- gac/ai.py +2 -0
- gac/ai_utils.py +1 -0
- gac/init_cli.py +1 -0
- gac/providers/__init__.py +2 -0
- gac/providers/deepseek.py +38 -0
- {gac-1.11.1.dist-info → gac-1.12.0.dist-info}/METADATA +2 -2
- {gac-1.11.1.dist-info → gac-1.12.0.dist-info}/RECORD +11 -10
- {gac-1.11.1.dist-info → gac-1.12.0.dist-info}/WHEEL +0 -0
- {gac-1.11.1.dist-info → gac-1.12.0.dist-info}/entry_points.txt +0 -0
- {gac-1.11.1.dist-info → gac-1.12.0.dist-info}/licenses/LICENSE +0 -0
gac/__version__.py
CHANGED
gac/ai.py
CHANGED
|
@@ -13,6 +13,7 @@ from gac.providers import (
|
|
|
13
13
|
call_anthropic_api,
|
|
14
14
|
call_cerebras_api,
|
|
15
15
|
call_chutes_api,
|
|
16
|
+
call_deepseek_api,
|
|
16
17
|
call_fireworks_api,
|
|
17
18
|
call_gemini_api,
|
|
18
19
|
call_groq_api,
|
|
@@ -83,6 +84,7 @@ def generate_commit_message(
|
|
|
83
84
|
"anthropic": call_anthropic_api,
|
|
84
85
|
"cerebras": call_cerebras_api,
|
|
85
86
|
"chutes": call_chutes_api,
|
|
87
|
+
"deepseek": call_deepseek_api,
|
|
86
88
|
"fireworks": call_fireworks_api,
|
|
87
89
|
"gemini": call_gemini_api,
|
|
88
90
|
"groq": call_groq_api,
|
gac/ai_utils.py
CHANGED
gac/init_cli.py
CHANGED
|
@@ -35,6 +35,7 @@ def init() -> None:
|
|
|
35
35
|
("Anthropic", "claude-haiku-4-5"),
|
|
36
36
|
("Cerebras", "qwen-3-coder-480b"),
|
|
37
37
|
("Chutes", "zai-org/GLM-4.6-FP8"),
|
|
38
|
+
("DeepSeek", "deepseek-chat"),
|
|
38
39
|
("Fireworks", "accounts/fireworks/models/gpt-oss-20b"),
|
|
39
40
|
("Gemini", "gemini-2.5-flash"),
|
|
40
41
|
("Groq", "meta-llama/llama-4-maverick-17b-128e-instruct"),
|
gac/providers/__init__.py
CHANGED
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
from .anthropic import call_anthropic_api
|
|
4
4
|
from .cerebras import call_cerebras_api
|
|
5
5
|
from .chutes import call_chutes_api
|
|
6
|
+
from .deepseek import call_deepseek_api
|
|
6
7
|
from .fireworks import call_fireworks_api
|
|
7
8
|
from .gemini import call_gemini_api
|
|
8
9
|
from .groq import call_groq_api
|
|
@@ -20,6 +21,7 @@ __all__ = [
|
|
|
20
21
|
"call_anthropic_api",
|
|
21
22
|
"call_cerebras_api",
|
|
22
23
|
"call_chutes_api",
|
|
24
|
+
"call_deepseek_api",
|
|
23
25
|
"call_fireworks_api",
|
|
24
26
|
"call_gemini_api",
|
|
25
27
|
"call_groq_api",
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
"""DeepSeek API provider for gac."""
|
|
2
|
+
|
|
3
|
+
import os
|
|
4
|
+
|
|
5
|
+
import httpx
|
|
6
|
+
|
|
7
|
+
from gac.errors import AIError
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
def call_deepseek_api(model: str, messages: list[dict], temperature: float, max_tokens: int) -> str:
|
|
11
|
+
"""Call DeepSeek API directly."""
|
|
12
|
+
api_key = os.getenv("DEEPSEEK_API_KEY")
|
|
13
|
+
if not api_key:
|
|
14
|
+
raise AIError.authentication_error("DEEPSEEK_API_KEY not found in environment variables")
|
|
15
|
+
|
|
16
|
+
url = "https://api.deepseek.com/v1/chat/completions"
|
|
17
|
+
headers = {"Authorization": f"Bearer {api_key}", "Content-Type": "application/json"}
|
|
18
|
+
|
|
19
|
+
data = {"model": model, "messages": messages, "temperature": temperature, "max_tokens": max_tokens}
|
|
20
|
+
|
|
21
|
+
try:
|
|
22
|
+
response = httpx.post(url, headers=headers, json=data, timeout=120)
|
|
23
|
+
response.raise_for_status()
|
|
24
|
+
response_data = response.json()
|
|
25
|
+
content = response_data["choices"][0]["message"]["content"]
|
|
26
|
+
if content is None:
|
|
27
|
+
raise AIError.model_error("DeepSeek API returned null content")
|
|
28
|
+
if content == "":
|
|
29
|
+
raise AIError.model_error("DeepSeek API returned empty content")
|
|
30
|
+
return content
|
|
31
|
+
except httpx.HTTPStatusError as e:
|
|
32
|
+
if e.response.status_code == 429:
|
|
33
|
+
raise AIError.rate_limit_error(f"DeepSeek API rate limit exceeded: {e.response.text}") from e
|
|
34
|
+
raise AIError.model_error(f"DeepSeek API error: {e.response.status_code} - {e.response.text}") from e
|
|
35
|
+
except httpx.TimeoutException as e:
|
|
36
|
+
raise AIError.timeout_error(f"DeepSeek API request timed out: {str(e)}") from e
|
|
37
|
+
except Exception as e:
|
|
38
|
+
raise AIError.model_error(f"Error calling DeepSeek API: {str(e)}") from e
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: gac
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.12.0
|
|
4
4
|
Summary: LLM-powered Git commit message generator with multi-provider support
|
|
5
5
|
Project-URL: Homepage, https://github.com/cellwebb/gac
|
|
6
6
|
Project-URL: Documentation, https://github.com/cellwebb/gac#readme
|
|
@@ -91,7 +91,7 @@ gac
|
|
|
91
91
|
|
|
92
92
|
### 🌐 **Supported Providers**
|
|
93
93
|
|
|
94
|
-
- **Anthropic** • **Cerebras** • **Chutes.ai** • **Fireworks** • **Gemini**
|
|
94
|
+
- **Anthropic** • **Cerebras** • **Chutes.ai** • **DeepSeek** • **Fireworks** • **Gemini**
|
|
95
95
|
- **Groq** • **LM Studio** • **MiniMax** • **Ollama** • **OpenAI** • **OpenRouter**
|
|
96
96
|
- **Streamlake** • **Synthetic.new** • **Together AI** • **Z.AI** • **Z.AI Coding**
|
|
97
97
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
gac/__init__.py,sha256=z9yGInqtycFIT3g1ca24r-A3699hKVaRqGUI79wsmMc,415
|
|
2
|
-
gac/__version__.py,sha256=
|
|
3
|
-
gac/ai.py,sha256=
|
|
4
|
-
gac/ai_utils.py,sha256=
|
|
2
|
+
gac/__version__.py,sha256=pz_YrWiIGihOSHm_4WiV9sLizQLrXIAAXp4teEYrS0A,67
|
|
3
|
+
gac/ai.py,sha256=3Po9J0b1bjqtMs3p62yUMOMCU3ZT3iyh-QsagmevSWY,4081
|
|
4
|
+
gac/ai_utils.py,sha256=tZNLGJEyKhvBQ8zI0xZ56gfI6optHdkoHUa2ZzEtdBQ,7373
|
|
5
5
|
gac/cli.py,sha256=crUUI6osYtE3QAZ7r6DRlVk9gR3X2PctzS1sssVQ9_g,5070
|
|
6
6
|
gac/config.py,sha256=n3TkQYBqSKkH68QUM6M7kwSK83ghmItoh0p5ZDFnhHA,1746
|
|
7
7
|
gac/config_cli.py,sha256=v9nFHZO1RvK9fzHyuUS6SG-BCLHMsdOMDwWamBhVVh4,1608
|
|
@@ -9,16 +9,17 @@ gac/constants.py,sha256=8GHB7yeK2CYT0t80-k9N6LvgZPe-StNH3dK3NsUO46c,4977
|
|
|
9
9
|
gac/diff_cli.py,sha256=wnVQ9OFGnM0d2Pj9WVjWbo0jxqIuRHVAwmb8wU9Pa3E,5676
|
|
10
10
|
gac/errors.py,sha256=ysDIVRCd0YQVTOW3Q6YzdolxCdtkoQCAFf3_jrqbjUY,7916
|
|
11
11
|
gac/git.py,sha256=g6tvph50zV-wrTWrxARYXEpl0NeI8-ffFwHoqhp3fSE,8033
|
|
12
|
-
gac/init_cli.py,sha256=
|
|
12
|
+
gac/init_cli.py,sha256=mpjO6eVO-n3uT8NhJ7QWVQuVu2jFZ5aG4XksG2mbX78,4925
|
|
13
13
|
gac/main.py,sha256=dJrBSN5rJlbWspLGDx3eUJU4uZFVhvuv7qtgIvF7RH4,14723
|
|
14
14
|
gac/preprocess.py,sha256=aMxsjGxy9YP752NWjgf0KP5Sn6p8keIJAGlMYr8jDgQ,15373
|
|
15
15
|
gac/prompt.py,sha256=d_kBXmhf3bDVLyDj8J7AS7GBAxF2jlc8lXoHX3Dzi5k,24255
|
|
16
16
|
gac/security.py,sha256=15Yp6YR8QC4eECJi1BUCkMteh_veZXUbLL6W8qGcDm4,9920
|
|
17
17
|
gac/utils.py,sha256=nV42-brIHW_fBg7x855GM8nRrqEBbRzTSweg-GTyGE8,3971
|
|
18
|
-
gac/providers/__init__.py,sha256=
|
|
18
|
+
gac/providers/__init__.py,sha256=ZQES81QO2VnjCZkVRhyN1DDGQXrRD2DW0jswI1wU86Y,1136
|
|
19
19
|
gac/providers/anthropic.py,sha256=VK5d1s1PmBNDwh_x7illQ2CIZIHNIYU28btVfizwQPs,2036
|
|
20
20
|
gac/providers/cerebras.py,sha256=Ik8lhlsliGJVkgDgqlThfpra9tqbdYQZkaC4eNxRd9w,1648
|
|
21
21
|
gac/providers/chutes.py,sha256=cclJOLuGVIiiaF-9Bs1kH6SSOhEmduGB2zZ86KIaXKw,2617
|
|
22
|
+
gac/providers/deepseek.py,sha256=leT2S4_CE6JzwF3skDd4umBsu2rkJOJ66AfOdSL5wGc,1643
|
|
22
23
|
gac/providers/fireworks.py,sha256=zsWhf6LMVdtsD9keXRFwgn9lCQigz6VmrDl6vqIVkdI,1688
|
|
23
24
|
gac/providers/gemini.py,sha256=GZQz6Y9fd5-xk-U4pXn9bXLeBowxDXOYDyWyrtjFurM,2909
|
|
24
25
|
gac/providers/groq.py,sha256=9v2fAjDa_iRNHFptiUBN8Vt7ZDKkW_JOmIBeYvycD1M,2806
|
|
@@ -31,8 +32,8 @@ gac/providers/streamlake.py,sha256=KAA2ZnpuEI5imzvdWVWUhEBHSP0BMnprKXte6CbwBWY,2
|
|
|
31
32
|
gac/providers/synthetic.py,sha256=sRMIJTS9LpcXd9A7qp_ZjZxdqtTKRn9fl1W4YwJZP4c,1855
|
|
32
33
|
gac/providers/together.py,sha256=1bUIVHfYzcEDw4hQPE8qV6hjc2JNHPv_khVgpk2IJxI,1667
|
|
33
34
|
gac/providers/zai.py,sha256=kywhhrCfPBu0rElZyb-iENxQxxpVGykvePuL4xrXlaU,2739
|
|
34
|
-
gac-1.
|
|
35
|
-
gac-1.
|
|
36
|
-
gac-1.
|
|
37
|
-
gac-1.
|
|
38
|
-
gac-1.
|
|
35
|
+
gac-1.12.0.dist-info/METADATA,sha256=tssJw0ytHWHFn5YgNjNdKWLcxEaWffc6BR4WHGXctDc,7837
|
|
36
|
+
gac-1.12.0.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
37
|
+
gac-1.12.0.dist-info/entry_points.txt,sha256=tdjN-XMmcWfL92swuRAjT62bFLOAwk9bTMRLGP5Z4aI,36
|
|
38
|
+
gac-1.12.0.dist-info/licenses/LICENSE,sha256=vOab37NouL1PNs5BswnPayrMCqaN2sqLfMQfqPDrpZg,1103
|
|
39
|
+
gac-1.12.0.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|