Skip to content

Add weekly agent-facing OpenTelemetry reference workflow - #74598

Merged
pelikhan merged 2 commits into
mainfrom
pelikhan/otel-reference-workflow
Nov 3, 2026
Merged

pelikhan merged 2 commits into
mainfrom
pelikhan/otel-reference-workflow

Conversation

@pelikhan

@pelikhan pelikhan commented Nov 3, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Add a weekly and manually triggered agentic workflow that creates and maintains .github/aw/otel.md, teaching agents all available OTel measurements, their semantics, types, units, availability, correlation, aggregation, and query recipes.
  • Scan the complete checkout and trace emitter implementations, helpers, callers, and tests. Reconcile available measurements with specs/otel-observability-spec.md, distinguishing implemented behavior from optional or planned requirements and documenting discrepancies without changing the existing specification.
  • Add optional, pinned-compiler-validated TypeSpec descriptions only when stable message shapes make them useful. These remain informative rather than a second normative specification.
  • Create at most one draft reference PR, skip while an earlier PR is open, and no-op on unchanged content. Restrict changes to the guide and optional TypeSpec file/README, with exact root-path protected-files exceptions for the guide and README; other protections remain in place.

Validation

  • Compiled the new workflow with actionlint and shellcheck: no issues.
  • Ran make recompile: all 356 workflows compiled. Unrelated existing lock-file container-pin drift was restored rather than included.
  • Repository formatting/build/schema/drift gate passed; impacted Go test selection found no changed Go files.
  • Executed the source inventory and verified representative runtime/compiler/test coverage.
  • Exercised the actual safe-output file-protection helper: all intended outputs are allowed and unrelated protected paths are denied. Verified exclusions in both agent and handler compiled configurations.

No live workflow was dispatched. The guide itself will be produced by the workflow's first run after merge.

Maintain .github/aw/otel.md from emitted telemetry and the existing observability specification. Scope generated PRs and protected-file exclusions to the reference and optional TypeSpec artifacts.

Co-authored-by: Copilot App <[email protected]>
@pelikhan
pelikhan marked this pull request as ready for review November 3, 2026 20:00
Copilot AI adaptive review requested due to automatic review settings November 3, 2026 20:00
@github-actions

github-actions Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

✅ PR Code Quality Reviewer completed the code quality review.

🔎 Code quality review by PR Code Quality Reviewer

@github-actions

github-actions Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

✅ Design Decision Gate 🏗️ completed the design decision gate check. See the comment below for the result and any generated ADR draft.

Design Decision Gate 🏗️

Outcome: reported_no_action

The agent completed and reported no action. A no-op output alone does not verify that all required work was completed or that publication was possible.

Agent messages are omitted from this comment. The category uses structured run status, not interpretation of agent prose.

Generated from Design Decision Gate 🏗️ · routed: gpt56 max · ~1 AIC · ⌖ ~2 AIC · ⊞ 7.7K · ◷

🏗️ ADR gate enforced by Design Decision Gate 🏗️

@github-actions

github-actions Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

🧠 Matt Pocock Skills Reviewer has completed the skills-based review. ✅

🧠 Reviewed using Matt Pocock's skills by Matt Pocock Skills Reviewer

@github-actions

github-actions Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

✅ Ponytail Reviewer completed successfully!

Generated by Ponytail Reviewer for #74598

@github-actions

github-actions Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

✅ Test Quality Sentinel completed test quality analysis.

Test Quality Sentinel

Outcome: reported_no_action

The agent completed and reported no action. A no-op output alone does not verify that all required work was completed or that publication was possible.

Agent messages are omitted from this comment. The category uses structured run status, not interpretation of agent prose.

Generated from Test Quality Sentinel · haiku45 · ~10 AIC · ⌖ ~13 AIC · ⊞ 9.4K · ◷

🧪 Test quality analysis by Test Quality Sentinel

@github-actions

github-actions Bot commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

Comment Memory

Peek at saved memory (pr-code-quality-reviewer)
reviewed_at: 2026-11-03T20:07:10Z
review_event: REQUEST_CHANGES
top_themes: [untrusted-input trust boundary, protected generated guidance]
files_reviewed: [.github/workflows/weekly-otel-reference.md]
comment_count: 1

Note

This comment is managed by comment memory.

Expand the saved memory block to view or edit the persistent context for this thread.
Edit only the text inside the backtick fences; workflow metadata and the footer are regenerated automatically.

Learn more about comment memory

🔎 Code quality review by PR Code Quality Reviewer · copilot · gpt50 · ~2 AIC · ⌖ ~1 AIC · ⊞ 1.6K · ◷
Comment /review to run again

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

What this change does: This adds a weekly/manual workflow that inventories OpenTelemetry source and asks an agent to maintain an agent-facing guide, with optional TypeSpec output and a guarded draft PR.

Should fix:

  1. Redundant source inventory (.github/workflows/weekly-otel-reference.md:L47-64)

    • What this is: A pre-agent grep writes a candidate-file list for the agent.
    • Problem: The prompt still requires a full-checkout scan and admits the list is not proof of completeness, so every run must redo discovery.
    • Fix: Remove the inventory step and handoff, or make the inventory authoritative.
    • If we skip it: The workflow keeps carrying shell and temporary-file machinery that does not reduce the agent work.
  2. Optional TypeSpec has mandatory setup (.github/workflows/weekly-otel-reference.md:L40-45)

    • What this is: Every invocation sets up Node and installs the TypeSpec compiler.
    • Problem: The task allows no TypeSpec when no stable shapes exist, but the base workflow still pays for that tooling.
    • Fix: Make compiler setup conditional on the optional artifact, or remove this optional path.
    • If we skip it: The workflow retains a mandatory toolchain for an output it may not produce.

Verdict: fix 1 and 2 first.
Not checked: correctness, security, performance, and the generated lock file, per the review scope.
Lean: -23 lines possible.

Generated by ✂️ Ponytail Reviewer for #74598 · codex · routed: gpt56 max · ~4 AIC · ⌖ ~1 AIC · ⊞ 118
Comment /ponytail to run again

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

The workflow has a trust-boundary issue: it removes the generated agent reference from protected-file review while sourcing evidence from untrusted repository and PR content.

Findings

  • Keep .github/aw/otel.md behind the request-review protection (or equivalent required review) before it becomes authoritative context for future agents.

The existing prompt-injection concern on the source-reading instruction was already reported by another reviewer; I did not duplicate it.

🔎 Code quality review by PR Code Quality Reviewer · copilot · gpt50 · ~2 AIC · ⌖ ~1 AIC · ⊞ 1.6K
Comment /review to run again

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

Dependency lifecycle scripts could compromise later credential-bearing setup, and creating the guide without updating required companion lists would fail synchronization tests.

3 open issues
What changed in this PR

Adds weekly and manually triggered automation to maintain gh-aw’s agent-facing OpenTelemetry reference from source implementations and the existing observability specification. The guide itself will be generated by a later workflow run.

Changes:

  • Inventories telemetry emitters and documents measurement semantics, correlation, aggregation, and query recipes.
  • Optionally maintains informative TypeSpec contracts validated with a pinned compiler.
  • Limits publication to one draft PR, skips existing open reference PRs, and restricts editable paths.
File Description
.github/​workflows/​weekly-otel-reference.md Defines discovery, documentation, validation, and constrained publication.
.github/​workflows/​weekly-otel-reference.lock.yml Provides the generated GitHub Actions jobs and execution safeguards.

Review effort: Max (auto)

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Skills-Based Review 🧠

Applied /grill-with-docs and /tdd to this new workflow. Requesting changes on two items: a review gate that the exclusion removes, and an install step that is only partly pinned.

📋 Key Themes & Highlights

Key Themes

  • Review gate removed for agent-facing guide: /.github/aw/otel.md is excluded from protected-files, so its changes skip the request-review gate that future agents rely on.
  • Partial supply-chain pin: @typespec/[email protected] is pinned, but --no-save --package-lock=false lets transitive dependencies resolve fresh on each run, and install scripts run by default.

Verified

  • ✅ Lock file matches source: compiled the PR head 4b5c895 with the repo's own compiler and saw no drift.
  • ✅ Leading-slash exclude entries are parsed as root-relative path exclusions, as the workflow intends.
  • ✅ skip-if-match depends on the gh-aw-workflow-id marker, which the create_pull_request footer emits.

Not Covered

  • The PR head was checked out by SHA from the local clone, because the remote fetch failed on TLS. The diff itself came from the pre-fetched patch.
  • I did not duplicate the open github-advanced-security comment on line 82. The workflow already tells the agent to treat repo and PR text as evidence, not instructions.

@copilot please address the review comments above.

🧠 Reviewed using Matt Pocock's skills by Matt Pocock Skills Reviewer · copilot · routed: haiku55 xhigh · ~8 AIC · ⌖ ~1 AIC · ⊞ 5.4K
Comment /matt to run again

@github-actions

github-actions Bot commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

Note

The pull request was not created — a fallback review issue was created instead due to protected file changes: #74631

PR Finisher

Submitted for publication (not yet confirmed pushed): merged main, and updated weekly-otel-reference.md to remove the source-inventory pre-step, drop the node network group, add --ignore-scripts to the TypeSpec install, and keep .github/aw/otel.md protected (removed from the exclude list). Review replies and resolutions are deferred until publication.

Validation: make recompile succeeded; lock files were excluded from the submission, so a maintainer must recompile locks. make agent-report-progress failed only on lock drift. Not addressed: conditional TypeSpec setup, and the fallback/SKILL.md sync for a new otel.md (needs files outside allowed-files). CI needs a maintainer re-trigger.

Sous-chef work: Update this branch with the latest main using make merge-main, resolving any conflicts and preserving the intended changes.

Address 10 unresolved reviews regarding prompt injection risks, redundant source inventory, conditional TypeSpec setup, protected file review gates, and dependency lifecycle script security.

Generated by 🏁 PR Finisher · copilot · auto · ~25 AIC · ⌖ ~1 AIC · ⊞ 10.7K · ◷

Keep generated guidance under protected-file review, constrain untrusted source text, and remove redundant inventory and unconditional TypeSpec downloads. Seed the source-grounded guide and synchronize its skill and fallback registrations.

Co-authored-by: Copilot App <[email protected]>
@pelikhan

pelikhan commented Nov 3, 2026

Copy link
Copy Markdown
Collaborator Author

Regarding this completion notice: no additional code change is requested. The associated protected-guidance finding is addressed in its inline thread.

@pelikhan

pelikhan commented Nov 3, 2026

Copy link
Copy Markdown
Collaborator Author

Regarding this status-only result: no architecture change or ADR is requested here. This batch addresses the actionable inline findings rather than treating the no-op report as proof of completion.

@pelikhan

pelikhan commented Nov 3, 2026

Copy link
Copy Markdown
Collaborator Author

Regarding this completion notice: no separate code change is needed for the notice itself. The protected-guide and TypeSpec setup findings are addressed individually in their inline threads.

@pelikhan

pelikhan commented Nov 3, 2026

Copy link
Copy Markdown
Collaborator Author

Regarding this completion notice: no separate code change is requested. The redundant inventory and mandatory optional-tooling findings are addressed in their inline threads.

@pelikhan

pelikhan commented Nov 3, 2026

Copy link
Copy Markdown
Collaborator Author

Regarding this status-only result: no additional test change is requested here. Focused checks for the guide registration, compiled workflow, and publication protections are handled as part of this batch.

@pelikhan

pelikhan commented Nov 3, 2026

Copy link
Copy Markdown
Collaborator Author

Regarding this managed memory, accepted the associated trust-boundary finding: the generated guide now remains protected by request-review, with tighter content-handling rules. The managed comment is left unchanged; the actual finding is answered in its inline thread.

@pelikhan

pelikhan commented Nov 3, 2026

Copy link
Copy Markdown
Collaborator Author

Partially accepted this handoff: implemented the actionable hardening, seeded and registered the guide, and regenerated the lock directly on this PR branch, superseding the unpublished fallback work. A base-branch merge was not needed for these fixes, so this batch avoids that unrelated change and does not rely on the prior no-op or publication report.

@github-actions

github-actions Bot commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

Note

The pull request was not created — a fallback review issue was created instead due to protected file changes: #74636

PR Finisher pass: changes submitted for publication (not confirmed pushed).

  • Merged main locally.
  • Workflow: removed TypeSpec setup, the node network group, and the source-inventory pre-step. Removed protected-files exclusions, so the guide stays protected under request-review. allowed-files is now only .github/aw/otel.md. The prompt now treats source text as untrusted and requires a reference-data preamble.
  • Seeded .github/aw/otel.md with description frontmatter; updated the fallback JSON and SKILL.md lists.
  • Validation: make recompile OK; go test ./pkg/cli -run Fallback|AwFiles|Skill OK. make agent-report-progress could not complete (pinned Prettier unavailable here).
  • Generated lock YAML is excluded from the submission; a maintainer should recompile.
  • Review replies/resolutions are deferred until the push is published. CI needs a maintainer re-trigger.

Sous-chef head: 4b5c895
Sous-chef work: Update this branch with the latest main using make merge-main, resolving any conflicts and preserving the intended changes.
Sous-chef state: b577daf541cb3b21689dba289aacdf5d71b9bae8fbbc95d04abe9b620880eaf5

Generated by 🏁 PR Finisher · copilot · auto · ~31 AIC · ⌖ ~1 AIC · ⊞ 10.7K · ◷

"multi-agent-research.md",
"network.md",
"optimize-agentic-workflow.md",
"otel.md",
@pelikhan
pelikhan merged commit e03c0f1 into main Nov 3, 2026
127 checks passed
@pelikhan
pelikhan deleted the pelikhan/otel-reference-workflow branch November 3, 2026 21:58
@github-actions

github-actions Bot commented Nov 4, 2026

Copy link
Copy Markdown
Contributor

🎉 This pull request is included in a new release.

Release: v1.2.0

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