-
Notifications
You must be signed in to change notification settings - Fork 11
providers: add Claude Code SDK provider integration #68
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
2262bdd to
d0acd6a
Compare
|
Force pushed to clear out an unintentionally deleted comment about Ollama. |
|
Okay, I'm pulling this out of draft. It is working. I've done hundreds of translations so far without issue. |
|
There are some issues with flake8 and pylint: python_gpt_po/services/providers/claude_sdk_provider.py:5:1: F401 'logging' imported but unused
python_gpt_po/services/providers/claude_sdk_provider.py:6:1: F401 'sys' imported but unused
python_gpt_po/services/providers/provider_init.py:4:1: F401 'logging' imported but unused |
|
fixed. |
Imports are incorrectly sorted and/or formatted. |
Enable Claude SDK authentication via Claude Code CLI without requiring API keys. The Claude SDK provider complements existing API-based providers by supporting local authentication through the installed Claude Code tool. - add claude-agent-sdk dependency - add CLAUDE_SDK enum variant for provider type identification - register CLAUDE_SDK as local provider requiring no API key - implement ClaudeSdkProvider with multiple model support and fallbacks - register new provider in initialization pipeline - document Claude SDK usage in CLI help with example Signed-off-by: Eric Wheeler <[email protected]>
Unused imports increase cognitive load and may trigger linting warnings. Cleaning removes technical debt and improves code clarity. - remove unused logging and sys imports from claude_sdk_provider.py - remove unused logging import from provider_init.py - remove trailing blank line from provider_init.py Signed-off-by: Eric Wheeler <[email protected]>
Condense the multi-line import statement in the Claude SDK provider to fit on fewer lines, aligning imports horizontally rather than vertically. - reformat import statement to condensed format Signed-off-by: Eric Wheeler <[email protected]>
62a0fd9 to
a1e132c
Compare
|
fixed and rebased |
|
It looks like Python 3.9 failed, but the dependency does require 3.10. Would you like this to be conditionally available if someone pip installs the claude sdk package, or do you want to drop support for 3.9? |
Enable Claude Code SDK authentication via Claude Code CLI without requiring API keys. The Claude SDK provider complements existing API-based providers by supporting local authentication through the installed Claude Code tool.
This integration allows users with Claude Code subscriptions to leverage their existing Claude Code CLI installation for translation tasks without managing API keys or paying per token. The provider implements the same interface as other providers while using the claude-agent-sdk for communication with the locally authenticated Claude service.