Skip to content

Conversation

@PVeazie951
Copy link
Contributor

Summary

This PR fixes an issue where AI-generated CI/CD pipelines did not include provider-specific configuration (e.g. AWS OIDC role ARN), resulting in placeholder values like REPLACE_ME in the generated YAML.

Manual pipeline generation already worked correctly; the AI wizard path was losing context between the frontend and backend age

Root Cause

The AI wizard request (/agent/wizard/ai) was only forwarding the natural-language prompt to the backend agent.
As a result, authoritative pipeline configuration (provider, branch, stages, and provider options such as awsRoleArn) was never passed into the pipeline_generator MCP tool.

What Changed

Frontend
• Injected a pipelineSnapshot when calling the AI wizard, containing:
• template
• provider
• branch
• stages
• provider options (AWS role / GCP service account)

Backend – Router
• Updated /agent/wizard/ai to forward full pipeline context to the wizard agent
• Added debug logs to confirm snapshot presence and structure

Backend – Wizard Agent
• Hydrated the wizard agent with the incoming pipelineSnapshot
• Forwarded provider options, stages, and branch directly into pipeline_generator
• Preserved existing inference logic as a fallback only

Result
• AI-generated pipelines now match manual generation output
• AWS OIDC pipelines correctly include the resolved role-to-assume
• Eliminates placeholder values (REPLACE_ME)
• Maintains a single source of truth for pipeline configuration

Files Changed
• client/src/pages/ConfigurePage.tsx
• server/routes/agent.js
• server/agent/wizardAgent.js

@lorencDedaj lorencDedaj merged commit 5b0e5da into main Dec 17, 2025
11 of 13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants