Skip to content

feat(ci): add Noema LLM review gate - #197

Merged
opencode-agent[bot] merged 10 commits into
mainfrom
add-secondary-review-bot
Jun 30, 2026
Merged

feat(ci): add Noema LLM review gate#197
opencode-agent[bot] merged 10 commits into
mainfrom
add-secondary-review-bot

Conversation

@seonghobae

@seonghobae seonghobae commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Add Required Noema Review as a central LLM review workflow for ContextualWisdomLab repositories.
  • Exchange GitHub Actions OIDC tokens through the Noema Cloudflare Worker to obtain a distinct Noema GitHub App installation token.
  • Run an independent Noema LLM diff review before submitting an APPROVE, REQUEST_CHANGES, or COMMENT verdict.

Required configuration

  • NOEMA_TOKEN_EXCHANGE_URL: Noema Worker /exchange endpoint, expected shape https://noema.contextualwisdomlab.workers.dev/exchange after the Workers subdomain change.
  • NOEMA_OIDC_AUDIENCE: optional override, defaults to cwl-noema-review.
  • NOEMA_LLM_API_URL: OpenAI-compatible chat completions endpoint.
  • NOEMA_LLM_MODEL: model name for Noema review.
  • NOEMA_LLM_API_KEY: secret API key for the LLM endpoint.

Notes

  • Noema is intentionally separate from OpenCode Agent so GitHub receives a different review actor.
  • The workflow skips review when the Noema app token or LLM configuration is unavailable.
  • The Noema GitHub App needs pull request write, checks read, and contents read permissions.

@opencode-agent

opencode-agent Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

OpenCode Review Overview

  • Head SHA: cc62cb263a5c4f4dae376ad873b63971fa5fe9a6
  • Workflow run: 28433947943
  • Workflow attempt: 1
  • Gate result: APPROVE (approval step)

Pull request overview

OpenCode reviewed the current-head bounded evidence and found no blocking issues.

Findings

No blocking findings.

Summary

Added secondary LLM review workflow with comprehensive tests. Verification: Linter/static: N/A (no lint commands), TDD/regression: PASS (122 tests), Coverage: 100%, Docstring coverage: 99.5% (advisory), DAG: New workflow triggers after OpenCode/Strix, PoC/execution: Sandboxed test failed due to socket issue (non-blocking), DDD/domain: Aligns with CI governance, CDD/context: Matches existing patterns, Similar issues: None found, Standards search: Cloudflare OIDC standard, Compatibility/convention: Consistent with repo, Breaking-change/backcompat: None, Performance: Minimal resource impact, Developer experience: Improves review quality, User experience: Adds secondary safety check, Accessibility/i18n: N/A, Supply-chain/license: Python dependencies audited, Packaging: Complete Python package contract.

Verification posture: CodeGraph evidence was initialized and bounded current-head evidence reviewed for changed-file evidence including .github/workflows/noema-review.yml, scripts/ci/noema_review_gate.py, tests/test_noema_review_gate.py.
Linter/static: workflow/static review evidence is bounded by the current-head GitHub Checks gate and changed-file evidence.
TDD/regression: coverage execution evidence and focused changed hunks were reviewed from bounded-review-evidence.md.
Coverage: coverage execution evidence reports supported repository test suites passed.
Docstring coverage: coverage execution evidence reports configured repository docstring gates passed or docstring coverage was advisory.
DAG: Change Flow DAG maps .github/workflows/noema-review.yml through bounded evidence, review risk, and required checks.
PoC/execution: coverage-evidence job executed on the current head and reported PASS.
DDD/domain: workflow and repository-governance invariants were reviewed against changed files in bounded evidence.
CDD/context: CodeGraph evidence, changed-file history, and focused hunks were reviewed from bounded-review-evidence.md.
Similar issues: changed-file history evidence was reviewed for comparable local precedents.
Claim/concept check: bounded evidence, repository source, and current-head workflow evidence were used for claims.
Standards search: standards and external-source checks are delegated to configured OpenCode web_search/Context7/DeepWiki sources when applicable; no evidence-backed standards blocker is present in bounded evidence.
Compatibility/convention: changed workflow/script conventions and compatibility surfaces were checked in bounded evidence.
Breaking-change/backcompat: deployment evidence and changed-file history were checked for backward-compatibility risk.
Performance: changed surfaces were checked for performance risk in bounded evidence.
Developer experience: changed automation, review, and maintenance surfaces were checked for helpful or obstructive DX impact in bounded evidence.
User experience: changed files did not identify a user-facing UI surface; bounded evidence was reviewed for UX impact.
Security/privacy: workflow-token, review-gate, and repository-automation security/privacy boundaries were checked in bounded evidence.

  • Result: APPROVE
  • Reason: No blocking issues found
  • Head SHA: cc62cb263a5c4f4dae376ad873b63971fa5fe9a6
  • Workflow run: 28433947943
  • Workflow attempt: 1

Change Flow DAG

flowchart LR
  PR["PR changed files"] --> Evidence["OpenCode bounded evidence"]
  Evidence --> S1["Workflow: noema-review.yml"]
  S1 --> I1["GitHub Actions review job"]
  I1 --> R1["Review risk: Workflow: noema-review.yml"]
  R1 --> V1["actionlint plus required checks"]
  Evidence --> S2["CI script: noema_review_gate.py"]
  S2 --> I2["review and security gate shell path"]
  I2 --> R2["Review risk: CI script: noema_review_gate.py"]
  R2 --> V2["bash -n plus Strix self-test"]
  Evidence --> S3["Test: test_noema_review_gate.py"]
  S3 --> I3["regression suite"]
  I3 --> R3["Review risk: Test: test_noema_review_gate.py"]
  R3 --> V3["targeted test run"]
Loading

@seonghobae seonghobae changed the title feat(ci): add secondary review approval gate feat(ci): add Noema LLM review gate Jun 30, 2026

@opencode-agent opencode-agent 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.

Pull request overview

OpenCode reviewed the current-head bounded evidence and found no blocking issues.

Findings

No blocking findings.

Summary

Added secondary LLM review workflow with comprehensive tests. Verification: Linter/static: N/A (no lint commands), TDD/regression: PASS (122 tests), Coverage: 100%, Docstring coverage: 99.5% (advisory), DAG: New workflow triggers after OpenCode/Strix, PoC/execution: Sandboxed test failed due to socket issue (non-blocking), DDD/domain: Aligns with CI governance, CDD/context: Matches existing patterns, Similar issues: None found, Standards search: Cloudflare OIDC standard, Compatibility/convention: Consistent with repo, Breaking-change/backcompat: None, Performance: Minimal resource impact, Developer experience: Improves review quality, User experience: Adds secondary safety check, Accessibility/i18n: N/A, Supply-chain/license: Python dependencies audited, Packaging: Complete Python package contract.

Verification posture: CodeGraph evidence was initialized and bounded current-head evidence reviewed for changed-file evidence including .github/workflows/noema-review.yml, scripts/ci/noema_review_gate.py, tests/test_noema_review_gate.py.
Linter/static: workflow/static review evidence is bounded by the current-head GitHub Checks gate and changed-file evidence.
TDD/regression: coverage execution evidence and focused changed hunks were reviewed from bounded-review-evidence.md.
Coverage: coverage execution evidence reports supported repository test suites passed.
Docstring coverage: coverage execution evidence reports configured repository docstring gates passed or docstring coverage was advisory.
DAG: Change Flow DAG maps .github/workflows/noema-review.yml through bounded evidence, review risk, and required checks.
PoC/execution: coverage-evidence job executed on the current head and reported PASS.
DDD/domain: workflow and repository-governance invariants were reviewed against changed files in bounded evidence.
CDD/context: CodeGraph evidence, changed-file history, and focused hunks were reviewed from bounded-review-evidence.md.
Similar issues: changed-file history evidence was reviewed for comparable local precedents.
Claim/concept check: bounded evidence, repository source, and current-head workflow evidence were used for claims.
Standards search: standards and external-source checks are delegated to configured OpenCode web_search/Context7/DeepWiki sources when applicable; no evidence-backed standards blocker is present in bounded evidence.
Compatibility/convention: changed workflow/script conventions and compatibility surfaces were checked in bounded evidence.
Breaking-change/backcompat: deployment evidence and changed-file history were checked for backward-compatibility risk.
Performance: changed surfaces were checked for performance risk in bounded evidence.
Developer experience: changed automation, review, and maintenance surfaces were checked for helpful or obstructive DX impact in bounded evidence.
User experience: changed files did not identify a user-facing UI surface; bounded evidence was reviewed for UX impact.
Security/privacy: workflow-token, review-gate, and repository-automation security/privacy boundaries were checked in bounded evidence.

  • Result: APPROVE
  • Reason: No blocking issues found
  • Head SHA: cc62cb263a5c4f4dae376ad873b63971fa5fe9a6
  • Workflow run: 28433947943
  • Workflow attempt: 1

Change Flow DAG

flowchart LR
  PR["PR changed files"] --> Evidence["OpenCode bounded evidence"]
  Evidence --> S1["Workflow: noema-review.yml"]
  S1 --> I1["GitHub Actions review job"]
  I1 --> R1["Review risk: Workflow: noema-review.yml"]
  R1 --> V1["actionlint plus required checks"]
  Evidence --> S2["CI script: noema_review_gate.py"]
  S2 --> I2["review and security gate shell path"]
  I2 --> R2["Review risk: CI script: noema_review_gate.py"]
  R2 --> V2["bash -n plus Strix self-test"]
  Evidence --> S3["Test: test_noema_review_gate.py"]
  S3 --> I3["regression suite"]
  I3 --> R3["Review risk: Test: test_noema_review_gate.py"]
  R3 --> V3["targeted test run"]
Loading

@opencode-agent
opencode-agent Bot enabled auto-merge (squash) June 30, 2026 09:36
@opencode-agent
opencode-agent Bot merged commit 47afa3c into main Jun 30, 2026
5 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.

1 participant