Commit Graph

4 Commits

  • feat(coding-agent): add Google Cloud Code Assist OAuth flow
    - Add OAuth handler with PKCE flow and local callback server
    - Automatic project discovery via loadCodeAssist/onboardUser endpoints
    - Store credentials with projectId for API calls
    - Encode token+projectId as JSON for provider to decode
    - Register as 'google-cloud-code-assist' OAuth provider
  • feat(ai): add Google Cloud Code Assist provider
    - Add new API type 'google-cloud-code-assist' for Gemini CLI / Antigravity auth
    - Extract shared Google utilities to google-shared.ts
    - Implement streaming provider for Cloud Code Assist endpoint
    - Add 7 models: gemini-3-pro-high/low, gemini-3-flash, claude-sonnet/opus, gpt-oss
    
    Models use OAuth authentication and have sh cost (uses Google account quota).
    OAuth flow will be implemented in coding-agent in a follow-up.
  • refactor(ai): improve error handling and stop reason types
    - Add 'aborted' as a distinct stop reason separate from 'error'
    - Change AssistantMessage.error to errorMessage for clarity
    - Update error event to include reason field ('error' | 'aborted')
    - Map provider-specific safety/refusal reasons to 'error' stop reason
    - Reorganize utility functions into utils/ directory
    - Rename agent.ts to agent-loop.ts for better clarity
    - Fix error handling in all providers to properly distinguish abort from error