Commit Graph
3 Commits
Author SHA1 Message Date
senior 8c17aed1fc @senior: issue #29 — derive Ollama Cloud provider models from the agent registry
The agent→model registry in route.sh is now the single source of truth for
Ollama Cloud model IDs. route.sh publishes the full registry as a step
output (agents=...), and install-opencode.sh derives the ollama-cloud
provider models: map from it (unprefixed IDs), instead of hardcoding a
second copy. The two files can no longer drift silently — adding/changing
a cloud model in the registry automatically updates the provider config.

- route.sh: emit agents=$(jq -c '.' /tmp/agents.json) to GITHUB_OUTPUT
- agent.yml: pass steps.prep.outputs.agents as AGENTS env to install-opencode.sh
- install-opencode.sh: derive CMODELS from $AGENTS; // {} keeps it valid
  when no agent uses an ollama-cloud model (non-ollama repos)
2026-07-04 07:12:15 +00:00
Felix FaerberandClaude Opus 4.8 b3deee7412 fix(agent): route issue-opened events (event_name is workflow_call in reusable wf)
The shared agent.yml is a reusable (workflow_call) workflow, so on Gitea
github.event_name evaluates to 'workflow_call' — not the original 'issues'/
'issue_comment'. route.sh branched on EVENT == "issues", so issue-opened runs
scanned the empty comment body and skipped the @pm fallback, exiting 1 with
"no known agent mentioned" (runs #393/#394). Comment runs were unaffected
because the @mention lives in $BODY.

Discriminate on the comment id (CID) instead, which IS reliably forwarded in
the event payload: empty => issue-opened (scan issue body, default @pm), set
=> comment (scan comment body). Also add .gitignore for .env.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-04 10:02:50 +03:00
lead 36ba91cdd8 @lead: externalize agent.yml inline scripts into .gitea/workflows/scripts/*.sh
Rebased onto the per-agent skill-scoping change so PR #25 carries both:
- route.sh keeps the registry 'skills' allow-list and emits skills as a step output
- install-opencode.sh writes the permission.skill block (deny-all + allow listed)

Pure refactor otherwise: each step's shell moves to its own file, called via
bash "$SCRIPTS/<name>.sh". The two extracted SKILL.md bodies are byte-identical to
main; routing/config/publish behavior is unchanged. Because this is a reusable
workflow (workflow_call) the runtime checkout is the caller's repo, so agent.yml now
checks THIS repo out into .agents-workflow/ (pinned @main) and points $SCRIPTS there.
2026-07-04 05:54:27 +00:00