Uh oh!
There was an error while loading. Please reload this page.
fix(pydantic): install the pydantic-ai CLI and match the real pai interface - #51242
Conversation
TriageCategory: feature | Risk: high | Score: 30/100
Recommended action: Still a draft/WIP with most of the checklist unchecked and no diff yet (0 changed files). Revisit once implementation is pushed and CI runs.
|
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
pai interfacepelikhan
commented
Aug 8, 2026
/smoke-pydantic |
|
pelikhan
commented
Aug 8, 2026
…thout npm installation Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Fixed in c99a2d4. The step failed with |
Great work on fixing the Pydantic AI engine integration! 👍 This PR successfully addresses the root cause of the smoke test failures by:
The fix is focused, well-documented, and includes the necessary test coverage. This is ready for review and merge. The
|
pelikhan
commented
Aug 8, 2026
/smoke-pydantic |
|
pelikhan
commented
Aug 8, 2026
…s are token-steered Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
pelikhan
commented
Aug 8, 2026
/smoke-pydantic |
|
pelikhan
commented
Aug 8, 2026
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Fixed in 3a7cb0f. Two issues, both confirmed from the run artifacts and reproduced locally against 1. The
The bare name already steers to Copilot (steering is by port, fixed in 0f8ba8d), and 2. The real remaining failure was the response shape. Run 31237213483 got a clean 200 and still failed, with Verified end-to-end by extracting the harness from the compiled lock file and running it against a mock proxy: it sends |
pelikhan
commented
Aug 8, 2026
/smoke-pydantic |
|
Smoke Test: Pydantic AI - ✅ PASS
Overall Status: PASS Run: https://github.com/github/gh-aw/actions/runs/31242043047
|
pelikhan
commented
Aug 8, 2026
@copilot resolve the merge conflicts on this branch. |
There was a problem hiding this comment.
Pull request overview
Fixes Pydantic AI CLI installation and execution through the AWF proxy with MCP support.
Changes:
- Installs and invokes
pai2.26.0 correctly. - Adds a Pydantic AI harness and MCP agent-spec adapter.
- Updates smoke-test expectations and generated workflow.
Show a summary per file
| File | Description |
|---|---|
pkg/workflow/behavior_defined_engine.go | Adds AWF installation for non-npm engines. |
.github/workflows/shared/pydantic.md | Defines installation, proxy routing, and MCP integration. |
.github/workflows/smoke-pydantic.md | Revises smoke-test requirements. |
.github/workflows/smoke-pydantic.lock.yml | Recompiled generated workflow. |
Review details
Tip
Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.
- Files reviewed: 4/4 changed files
- Comments generated: 2
- Review effort level: Balanced
| // Engines that install their CLI through `pre-agent-steps` (e.g. Pydantic AI) | ||
| // declare no installation block at all, but the agent still runs inside the | ||
| // firewall sandbox, so the AWF binary must be installed. | ||
| return BuildNpmEngineInstallStepsWithAWF(nil, workflowData) |
| 2. **Bash Tool Testing**: Execute bash commands to verify file creation was successful (use `cat` to read the file back) | ||
| 3. **Repository Access Testing**: Run `git log --oneline -1` in the repository checkout and confirm a commit is reported | ||
| 1. **Model Connectivity Testing**: Answer the question "What is 2 + 2?" in a single short line. | ||
| 2. **MCP Tool Testing**: Confirm that the `safeoutputs` MCP tools are available to you. |
gh-aw-bot
commented
Aug 8, 2026
@copilot Quick triage nudge for this PR. Please refresh the branch if GitHub can update it cleanly, address the remaining review feedback, and run the Open items (newest first):
Run: https://github.com/github/gh-aw/actions/runs/31242800863
|
…integration # Conflicts: # .github/workflows/smoke-pydantic.lock.yml Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Uh oh!
There was an error while loading. Please reload this page.
🎉 This pull request is included in a new release. Release: |
The
Smoke Pydantic AIjob fails at thePredownload Pydantic AI CLIstep witherror: Failed to spawn: pai.uv run paionly resolves commands from an existing uv project, so the CLI was never installed — and the rest of the engine definition was written against apaiinterface that does not exist.Verified against
pydantic-ai2.26.0:paihas norunsubcommand (the prompt is positional), the model must be passed as-m provider:model, there is noPAI_MODELenv var, and MCP servers can only be supplied through an agent spec passed with-a.shared/pydantic.mdpip install --user "pydantic-ai==$GH_AW_ENGINE_VERSION"and verify with"$HOME/.local/bin/pai" --version, mirroring the Aider engine.uvlives under/opt/hostedtoolcache, which is not mounted into the AWF container;~/.local/binis. Engine version pinned to2.26.0(was a placeholder0.1.0).uv run pai run <prompt>topai --no-stream -m "$PAI_MODEL" [-a .pydantic-ai/agent.json] "<prompt>".openai-chat:<model>so it resolves toOpenAIChatModelbehind the AWF OpenAI-compatible proxy (openai:would select the Responses API).mcp-config-env-var: GH_AW_MCP_CONFIGwith an MCP config adapter that renders gateway servers into a Pydantic AI agent spec, passed with-a. Non-HTTP servers are skipped with a log line.pypi.org/files.pythonhosted.orgnetwork defaults.Generated spec:
{ "model": "openai-chat:gpt-5", "capabilities": [ { "MCP": { "id": "safeoutputs", "url": "http://host.docker.internal:9999/mcp/safeoutputs", "headers": { "Authorization": "…" } } } ] }The spec-level
modelis a valid-by-construction fallback;-mtakes precedence whenever the workflow declares a model.pkg/workflowexecution.model-env-provider-separatorfor behavior-defined engines, defaulting to/so existing engines (aider, opencode) are unaffected. Needed to emitopenai-chat:claude-sonnet-4-5rather thanopenai-chat/claude-sonnet-4-5. Schema, generated frontmatter reference, and a table-driven unit test included.smoke-pydantic.mdgit logassertions could never pass:paiis a chat CLI and ships no filesystem or shell tools.Lock file recompiled.