Convert all AI services to use plugin-based structured output:
- Create dedicated plugins for code intelligence, review, docs, issues, and workflows
- Replace JSON parsing with SendForStructuredOutputAsync
- Add PluginHelpers for consistent deserialization
- Remove inline prompt instructions in favor of plugin definitions
- Eliminate brittle JSON parsing and error handling
- Improve type safety and maintainability across all AI features
Affected services: CodeIntelligence, CodeReview, Documentation, Issue, Workflow inspection
Implement AI plugins for automated landing page creation:
- LandingPageContentPlugin: generates hero, features, stats, CTAs from repo metadata
- LandingPageTranslationPlugin: translates landing page content to target languages
- Shared model classes matching Go server's expected JSON structure
- Uses structured output via tool_choice for reliable parsing
- Supports 20+ icon types for features and value props
- Integrates with WorkflowService for task execution
Add protocol_version field to Initialize RPC for forward compatibility as the plugin protocol evolves.
Changes:
- Add protocol_version to InitializeRequest (server → plugin)
- Add protocol_version to InitializeResponse (plugin → server)
- Set current protocol version to 1
- Version 0 indicates pre-versioning implementations (treated as v1)
This allows the server and plugins to negotiate capabilities:
- Server can avoid calling RPCs that older plugins don't implement
- Plugins can detect newer servers and enable advanced features
- Graceful degradation when versions mismatch
The AI service now reports protocol version 1 during initialization.
Update AI service README to reflect the dual-service architecture (AI operations + plugin protocol) and complete integration guide.
Architecture Updates:
- Document both GitCaddyAIService and PluginService running on port 5000
- Add architecture diagram showing server's AI client and plugin manager connections
- Clarify h2c (cleartext HTTP/2) transport for gRPC + REST on same port
API Reference:
- Add plugin protocol RPC methods (Initialize, HealthCheck, OnEvent, Shutdown)
- Explain plugin lifecycle and health monitoring (30s intervals)
- Document manifest-based capability declaration
Integration Guide:
- Split configuration into [ai] (operations) and [plugins.gitcaddy-ai] (lifecycle)
- Explain how both sections work together for complete integration
- Update client examples to use port 5000 (was 5051)
- Add transport details and event subscription explanation
This provides a complete picture of how the AI service integrates with the server as both an AI operations provider and a managed plugin.
Add gRPC-based plugin protocol implementation to the AI sidecar, enabling the GitCaddy server to manage it as an external plugin with lifecycle control and health monitoring.
Plugin Protocol Implementation:
- Add plugin.proto with PluginService definition (Initialize, Shutdown, HealthCheck, GetManifest, OnEvent, HandleHTTP)
- Implement PluginServiceImpl gRPC service in C#
- Return manifest declaring AI service capabilities, routes, and required permissions
- Integrate license validation into health checks
- Register plugin service alongside existing AI service
Server Integration:
- Configure Kestrel for HTTP/1.1 + HTTP/2 on port 5000 (enables gRPC + REST)
- Map PluginService gRPC endpoint at /plugin.v1.PluginService
- Enable server to call Initialize on startup, HealthCheck periodically, and Shutdown on graceful stop
This completes Phase 5 of the AI integration, allowing the server's external plugin manager to monitor and control the sidecar's lifecycle instead of relying on manual process management.
Add support for per-request AI provider configuration and workflow YAML inspection endpoint, enabling multi-tenant AI operations.
Per-Request Provider Config:
- Add CreateConversation overload accepting provider, model, and API key
- Add CreateConversation helper method in AIController to resolve config cascade
- When ProviderConfig is provided in request, override sidecar defaults
- Falls back to sidecar configuration when not provided (backwards compatible)
This fixes the critical multi-tenant gap where all organizations shared the sidecar's hardcoded provider configuration.
Workflow Inspection:
- Add POST /api/v1/workflows/inspect endpoint
- Analyzes GitHub Actions/Gitea Actions YAML for issues
- Detects syntax errors, security issues, performance problems, and best practice violations
- Returns structured JSON with issues (line, severity, message, fix) and suggestions
- Supports runner label compatibility checking
Both features support the ProviderConfigDto pattern for tenant-specific AI configuration.
Add missing REST endpoint POST /api/v1/issues/respond to the AI service, completing the REST API coverage for Tier 1 operations.
The endpoint wraps the existing gRPC IssueService.GenerateResponseAsync method, accepting issue metadata (title, body, comments) and returning an AI-generated response with follow-up questions.
This enables the Go server's AI client (modules/ai/client.go) to call the issue response operation via REST, matching the pattern used by other Tier 1 operations (triage, review, explain).
Add nuget.config with Gitea package source for MarketAlly.* packages and credential configuration using environment variables. Remove nuget.config from .gitignore to track package source configuration while keeping credentials secure through environment variable substitution.
Add conditional reference logic to use ProjectReference when available locally, falling back to PackageReference in CI environments. Pass NuGet credentials as environment variables during restore to enable authentication for private package feeds.
Add git configuration step before checkout to handle authentication for private repository redirects. This ensures workflow jobs can access private dependencies hosted on git.marketally.com using the GitHub token.
Add Gitea Actions workflows for automated CI/CD. Build workflow runs on push/PR to build, test, and push Docker images. Release workflow triggers on version tags to build multi-platform binaries, package NuGet client, create GitHub releases, and publish versioned Docker images. Also add REST API controller for AI services alongside existing gRPC endpoints.
Add Go and .NET client libraries for GitCaddy AI Service with usage examples. Include Business Source License 1.1, Makefile for build automation, and comprehensive README. Update service configuration and all service classes to support new client integration.
Add complete project scaffolding for GitCaddy.AI, an AI-powered Git assistant service. Includes:
- gRPC service implementation with proto definitions
- Core services: chat, code review, code intelligence, documentation, issues, and workflows
- AI provider factory with configuration support
- License validation system
- Docker containerization with dev and prod compose files
- .NET 9.0 solution with service and client projects