Commit Graph

3 Commits

Author SHA1 Message Date
ChaoLiu 9cfdacc387 test: update AI plugin tests for new configuration structure
- Add Enabled field to all Config test objects
- Update timeout expectations to reflect 10s default
- Change API key test expectation to support optional keys for local services
- Fix all LoadConfigFromEnv test cases for new field structure
- Ensure all Chat and Client tests use properly configured objects

Signed-off-by: ChaoLiu <chaoliu719@gmail.com>
2025-08-22 12:15:28 +08:00
ChaoLiu 9db3dcf0a2 fix: resolve golangci-lint violations across codebase
- Replace fmt.Errorf with errors.Wrapf/New for forbidigo compliance
- Add missing periods to comments for godot compliance
- Fix goimports formatting issues in multiple files
- Remove unused struct field writes in tests
- Replace unused method receivers with underscore
- Optimize single-case switch to if-else statement

Signed-off-by: ChaoLiu <chaoliu719@gmail.com>
2025-08-22 12:06:13 +08:00
Chao Liu 070598cbd3 feat: implement AI client with OpenAI integration
- Add plugin/ai/client.go with OpenAI API wrapper
- Add comprehensive test suite for AI client functionality

Signed-off-by: Chao Liu <chaoliu719@gmail.com>
2025-08-22 10:05:40 +08:00