Skip to content

daily-ambient-context-optimizer: add gh-aw CLI preflight and noop fallback path - #36792

Closed
pelikhan with Copilot wants to merge 4 commits into
mainfrom
copilot/daily-ambient-context-optimizer-again
Closed

daily-ambient-context-optimizer: add gh-aw CLI preflight and noop fallback path#36792
pelikhan with Copilot wants to merge 4 commits into
mainfrom
copilot/daily-ambient-context-optimizer-again

Conversation

CopilotAI commented Jun 4, 2026

Copy link
Copy Markdown
Contributor

The daily ambient-context optimizer could produce empty output when MCP CLI commands were unavailable. This change makes CLI readiness explicit and adds a deterministic fallback path so runs fail clearly instead of silently yielding empty reports.

  • Workflow runtime readiness

    • Adds an explicit setup step to install/upgrade github/gh-aw as a gh extension before analysis begins.
    • Verifies CLI availability with gh aw --version during setup.
  • Prompt-level preflight contract

    • Adds an MCP CLI Preflight section requiring:
      • gh --version
      • gh aw --version
      • gh aw logs --help
    • Instructs the agent to stop early and emit noop with the failed command when preflight fails.
  • Safe-output wiring for failure handling

    • Extends safe-outputs.noop config with explicit limits/behavior to support the preflight failure path (max, report-as-issue).
safe-outputs:
noop:
max: 1report-as-issue: truesteps:
- name: Install gh-aw CLIenv:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}run: | if gh extension list | grep -q "github/gh-aw"; then gh extension upgrade gh-aw || true else gh extension install github/gh-aw fi gh aw --version

CopilotAIand others added 3 commits June 4, 2026 02:55
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
CopilotAI changed the title [WIP] Optimize daily ambient contextdaily-ambient-context-optimizer: add gh-aw CLI preflight and noop fallback pathJun 4, 2026
CopilotAI requested a review from pelikhanJune 4, 2026 03:03

@pelikhanpelikhan left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@copilot update to use cli-proxy, gh-proxy and the agenticworkflows cli

Comment on lines +42 to +51
- name: Install gh-aw CLI
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
if gh extension list | grep -q "github/gh-aw"; then
gh extension upgrade gh-aw || true
else
gh extension install github/gh-aw
fi
gh aw --version

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@copilot it is installed. This is not the problem.

@pelikhanpelikhan closed this Jun 4, 2026
Copilot stopped work on behalf of pelikhan due to an error June 4, 2026 03:09
CopilotAI requested a review from pelikhanJune 4, 2026 03:09
@github-actions
github-actionsBot deleted the copilot/daily-ambient-context-optimizer-again branch June 12, 2026 03:01
Sign up for freeto 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.

[ambient-context] Daily Ambient Context Optimizer - 2026-06-04

2 participants

@pelikhan