Use OpenRouter for this repo's own PR review and run it as a single step #74

Closed
opened 2026-10-15 10:08:29 +00:00 by agent-pi · 1 comment
Collaborator

The pr-review job in .forgejo/workflows/ci.yml currently invokes WuMing twice: once against Moonshot for the code/security agents and once against DeepSeek for the config/docs/shell/tests agents. That means two API accounts to manage and two sequential LLM review passes on every PR.

WuMing now supports an openrouter backend (merged in #73), so the repo can review its own PRs through one OpenRouter account in a single step, keeping per-agent model choices via the name:model syntax.

Related gap: action.yml does not yet expose the new backend inputs (openrouter_key, openai_base_url, openai_key, openai_model), so workflows cannot pass an OpenRouter key to the action at all.

The `pr-review` job in `.forgejo/workflows/ci.yml` currently invokes WuMing twice: once against Moonshot for the code/security agents and once against DeepSeek for the config/docs/shell/tests agents. That means two API accounts to manage and two sequential LLM review passes on every PR. WuMing now supports an `openrouter` backend (merged in #73), so the repo can review its own PRs through one OpenRouter account in a single step, keeping per-agent model choices via the `name:model` syntax. Related gap: `action.yml` does not yet expose the new backend inputs (`openrouter_key`, `openai_base_url`, `openai_key`, `openai_model`), so workflows cannot pass an OpenRouter key to the action at all.
Author
Collaborator

Findings from exploration

  • The pr-review job runs two uses: ./ steps today: Kimi via moonshot for code/security, DeepSeek for config/docs/shell/tests.
  • action.yml maps with: inputs to WUMING_* env vars but has no inputs for the four variables added in #73 (WUMING_OPENROUTER_KEY, WUMING_OPENAI_BASE_URL, WUMING_OPENAI_KEY, WUMING_OPENAI_MODEL), and its backend description predates the new values.
  • Model slugs verified live against the OpenRouter catalog in the #72 investigation: moonshotai/kimi-k2.7-code and deepseek/deepseek-v4.1-flash both exist; the name:model parser splits on the first colon only, so vendor/model slugs with slashes parse correctly.
  • Docs surfaces listing backend choices: docs/getting-started/deploying-on-forgejo-actions.md (per-backend sections) and docs/getting-started/deploying-on-woodpecker.md.

Plan of attack

  1. action.yml: add openrouter_key, openai_base_url, openai_key, openai_model inputs (descriptions in the existing style) and map them to the WUMING_* env vars; update the backend input description to deepseek | anthropic | ollama | moonshot | openrouter | openai.
  2. .forgejo/workflows/ci.yml: replace the two review steps with one — backend: openrouter, openrouter_key: ${{ secrets.wuming_openrouter_key }}, agents: code:moonshotai/kimi-k2.7-code,security:moonshotai/kimi-k2.7-code,config:deepseek/deepseek-v4.1-flash,docs:deepseek/deepseek-v4.1-flash,shell:deepseek/deepseek-v4.1-flash,tests:deepseek/deepseek-v4.1-flash (preserves today's model assignments through one account), max_diff_lines: "2000" unchanged.
  3. docs/getting-started/deploying-on-forgejo-actions.md: add OpenRouter and generic-openai sections under "Choosing a backend" mirroring the existing per-backend layout; deploying-on-woodpecker.md likewise if it enumerates backends.
  4. Marvin8 needs to create the wuming_openrouter_key secret on the repo before the next PR review run succeeds.

Branch: feat/issue-74-openrouter-own-review

Commits:

  • :sparkles: expose openrouter and generic openai inputs in the action
  • :fire: merge the two PR review steps into one OpenRouter run
  • :memo: document OpenRouter and generic openai backend setup in the Actions guides
## Findings from exploration - The `pr-review` job runs two `uses: ./` steps today: Kimi via moonshot for `code`/`security`, DeepSeek for `config`/`docs`/`shell`/`tests`. - `action.yml` maps `with:` inputs to `WUMING_*` env vars but has no inputs for the four variables added in #73 (`WUMING_OPENROUTER_KEY`, `WUMING_OPENAI_BASE_URL`, `WUMING_OPENAI_KEY`, `WUMING_OPENAI_MODEL`), and its `backend` description predates the new values. - Model slugs verified live against the OpenRouter catalog in the #72 investigation: `moonshotai/kimi-k2.7-code` and `deepseek/deepseek-v4.1-flash` both exist; the `name:model` parser splits on the first colon only, so `vendor/model` slugs with slashes parse correctly. - Docs surfaces listing backend choices: `docs/getting-started/deploying-on-forgejo-actions.md` (per-backend sections) and `docs/getting-started/deploying-on-woodpecker.md`. ## Plan of attack 1. `action.yml`: add `openrouter_key`, `openai_base_url`, `openai_key`, `openai_model` inputs (descriptions in the existing style) and map them to the `WUMING_*` env vars; update the `backend` input description to `deepseek | anthropic | ollama | moonshot | openrouter | openai`. 2. `.forgejo/workflows/ci.yml`: replace the two review steps with one — `backend: openrouter`, `openrouter_key: ${{ secrets.wuming_openrouter_key }}`, `agents: code:moonshotai/kimi-k2.7-code,security:moonshotai/kimi-k2.7-code,config:deepseek/deepseek-v4.1-flash,docs:deepseek/deepseek-v4.1-flash,shell:deepseek/deepseek-v4.1-flash,tests:deepseek/deepseek-v4.1-flash` (preserves today's model assignments through one account), `max_diff_lines: "2000"` unchanged. 3. `docs/getting-started/deploying-on-forgejo-actions.md`: add OpenRouter and generic-openai sections under "Choosing a backend" mirroring the existing per-backend layout; `deploying-on-woodpecker.md` likewise if it enumerates backends. 4. Marvin8 needs to create the `wuming_openrouter_key` secret on the repo before the next PR review run succeeds. **Branch:** `feat/issue-74-openrouter-own-review` **Commits:** - `:sparkles: expose openrouter and generic openai inputs in the action` - `:fire: merge the two PR review steps into one OpenRouter run` - `:memo: document OpenRouter and generic openai backend setup in the Actions guides`
Sign in to join this conversation.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
marvin8/wuming#74
No description provided.