Skip to content

chore(config): update opencode configuration - #523

Merged
shunkakinoki merged 1 commit into
mainfrom
chore/update-opencode-config
Jan 10, 2026
Merged

chore(config): update opencode configuration#523
shunkakinoki merged 1 commit into
mainfrom
chore/update-opencode-config

Conversation

@shunkakinoki

@shunkakinoki shunkakinoki commented Jan 9, 2026

Copy link
Copy Markdown
Owner

Summary

  • Updated GLM model from 4.6 to 4.7 in opencode configuration
  • Changed model ID from @preset/glm-4-6 to @preset/glm-4-7
  • Updated display name to reflect the new version

Changes

  • Modified config/opencode/opencode.jsonc to use the latest GLM model version

Summary by cubic

Updates opencode configuration to use Preset GLM-4.7 instead of 4.6 via OpenRouter. Keeps the default model current; only the model ID and display name were changed.

Written for commit 8f1a973. Summary will update on new commits.

Copilot AI review requested due to automatic review settings January 9, 2026 18:26
@coderabbitai

coderabbitai Bot commented Jan 9, 2026

Copy link
Copy Markdown
📝 Walkthrough

Summary by CodeRabbit

  • Chores
    • Updated OpenRouter preset mapping from GLM-4.6 to GLM-4.7, providing access to the latest model version.

✏️ Tip: You can customize this high-level summary in your review settings.

Walkthrough

Updated the OpenRouter preset mapping in the configuration file from GLM-4.6 to GLM-4.7, changing the preset ID and display name accordingly. This single-file change updates model version references without altering the configuration structure.

Changes

Cohort / File(s) Summary
Configuration Updates
config/opencode/opencode.jsonc
Update OpenRouter preset mapping from GLM-4.6 to GLM-4.7; changed preset ID from @preset/glm-4-6 to @preset/glm-4-7 and updated display name accordingly

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

Possibly related PRs

Poem

🐰 A whisker-twitch of version cheer,
From 4.6 to 4.7 we steer,
The config hops with names so bright,
GLM presets shining in the light! ✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately summarizes the main change: updating the opencode configuration to reflect the GLM model version upgrade.
Description check ✅ Passed The description is directly related to the changeset, providing clear details about the GLM model version update from 4.6 to 4.7 and the configuration file changes.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch chore/update-opencode-config

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@gemini-code-assist

Copy link
Copy Markdown
Contributor

Summary of Changes

Hello @shunkakinoki, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request focuses on a routine maintenance update within the opencode configuration. The primary goal is to ensure that the system utilizes the latest version of the GLM model, thereby incorporating potential improvements or new features offered by the updated model. This change involves adjusting the model identifier and its corresponding display name to maintain consistency and accuracy.

Highlights

  • GLM Model Update: The GLM model version in the opencode configuration has been updated from 4.6 to 4.7.
  • Model ID Change: The model ID for the GLM model was changed from "@preset/glm-4-6" to "@preset/glm-4-7".
  • Display Name Adjustment: The display name for the GLM model was updated to "Preset GLM-4.7 (via OpenRouter)" to reflect the new version.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@mesa-dot-dev

mesa-dot-dev Bot commented Jan 9, 2026

Copy link
Copy Markdown

Mesa Description

TL;DR

Updated GLM model from 4.6 to 4.7 in opencode configuration.

What changed?

  • Modified config/opencode/opencode.jsonc to use GLM model 4.7, including updating the model ID from @preset/glm-4-6 to @preset/glm-4-7 and updating the display name.

Description generated by Mesa. Update settings

@gemini-code-assist gemini-code-assist 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.

Code Review

This pull request updates the GLM model version from 4.6 to 4.7 in the opencode configuration for openrouter-preset. While the model's id and name are correctly updated, the JSON key for this configuration remains glm-4-6. This creates an inconsistency that could be misleading. I've added a review comment recommending to update the key to glm-4-7 to maintain clarity and prevent potential issues.

Comment on lines +200 to +201
"id": "@preset/glm-4-7",
"name": "Preset GLM-4.7 (via OpenRouter)"

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.

high

The key for this model configuration on line 199 is glm-4-6, but the id and name fields now refer to glm-4-7. This inconsistency is misleading and could lead to incorrect model selection if the key is used as an identifier. For clarity and to prevent potential bugs, it's recommended to update the key on line 199 to glm-4-7 to match the model version.

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.

Pull request overview

This PR updates the GLM model configuration from version 4.6 to 4.7 in the OpenRouter preset section of the opencode configuration file.

Key changes:

  • Updated model ID from @preset/glm-4-6 to @preset/glm-4-7
  • Updated display name from "Preset GLM-4.6 (via OpenRouter)" to "Preset GLM-4.7 (via OpenRouter)"

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@@ -197,8 +197,8 @@
},
"models": {
"glm-4-6": {

Copilot AI Jan 9, 2026

Copy link

Choose a reason for hiding this comment

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

The model key "glm-4-6" is inconsistent with the updated model ID "@preset/glm-4-7" and name "Preset GLM-4.7 (via OpenRouter)". When updating the model version, the key should also be updated to "glm-4-7" to maintain consistency and avoid confusion. This mismatch could lead to developers referencing the wrong model version.

Suggested change
"glm-4-6": {
"glm-4-7": {

Copilot uses AI. Check for mistakes.

@cubic-dev-ai cubic-dev-ai 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.

No issues found across 1 file

@mesa-dot-dev mesa-dot-dev Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Performed full review of 9043376...8f1a973

Analysis

  1. Configuration Inconsistency: The PR introduces the only instance where a model's JSON key name ("glm-4-6") doesn't match its actual model ID ("@preset/glm-4-7"), breaking the established pattern used across all other models.

  2. Maintenance and Readability Concerns: The inconsistency may confuse future maintainers, as this is the only model with an explicit id field that differs from its key, with no documentation explaining the reason for this exception.

  3. Potential Reference Errors: Users or code referencing "glm-4-6" may unknowingly be using version 4.7, potentially causing subtle issues if version-specific features or behaviors are expected.

Tip

Help

Slash Commands:

  • /review - Request a full code review
  • /review latest - Review only changes since the last review
  • /describe - Generate PR description. This will update the PR body or issue comment depending on your configuration
  • /help - Get help with Mesa commands and configuration options

0 files reviewed | 0 comments | Edit Agent SettingsRead Docs

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In @config/opencode/opencode.jsonc:
- Around line 199-202: The config entry uses the object key "glm-4-6" while the
mapped preset id is "@preset/glm-4-7"; rename the object key from "glm-4-6" to
"glm-4-7" so the key matches the preset id (update the JSON object key where the
entry with id "@preset/glm-4-7" is defined) and verify the "@preset/glm-4-7"
preset is configured in your OpenRouter dashboard.
📜 Review details

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Disabled knowledge base sources:

  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 9043376 and 8f1a973.

📒 Files selected for processing (1)
  • config/opencode/opencode.jsonc
🧰 Additional context used
📓 Path-based instructions (1)
**/*.{js,jsx,ts,tsx,json,jsonc,md}

📄 CodeRabbit inference engine (.cursor/rules/general.mdc)

Use Biome for code formatting as configured in biome.json

Files:

  • config/opencode/opencode.jsonc
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (15)
  • GitHub Check: cubic · AI code reviewer
  • GitHub Check: Mesa Review
  • GitHub Check: nix-nixos
  • GitHub Check: nix-linux
  • GitHub Check: nix-darwin
  • GitHub Check: e2e-run (NixOS, ubuntu-latest)
  • GitHub Check: e2e-run (Ubuntu, ubuntu-latest)
  • GitHub Check: docker-build-push (linux/amd64, amd64, ubuntu-latest)
  • GitHub Check: e2e-run (MacOS, macos-latest)
  • GitHub Check: docker-build-push (linux/arm64, arm64, ubuntu-24.04-arm)
  • GitHub Check: shell-lint
  • GitHub Check: lua-neovim
  • GitHub Check: lua-hammerspoon
  • GitHub Check: lua-neovim-test
  • GitHub Check: shell-test

Comment on lines 199 to 202
"glm-4-6": {
"id": "@preset/glm-4-6",
"name": "Preset GLM-4.6 (via OpenRouter)"
"id": "@preset/glm-4-7",
"name": "Preset GLM-4.7 (via OpenRouter)"
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

# Find repo references to the old key or old/new preset ids
echo "=== Searching for 'glm-4-6' references ==="
rg -n '"glm-4-6"' --type json --type jsonc --type js --type ts . 2>/dev/null || echo "No matches found"

echo ""
echo "=== Searching for '@preset/glm-4-6' references ==="
rg -n '"@preset/glm-4-6"' . 2>/dev/null || echo "No matches found"

echo ""
echo "=== Searching for '@preset/glm-4-7' references ==="
rg -n '"@preset/glm-4-7"' . 2>/dev/null || echo "No matches found"

echo ""
echo "=== Checking config file context ==="
cat -n config/opencode/opencode.jsonc | sed -n '190,210p'

Repository: shunkakinoki/dotfiles

Length of output: 999


🌐 Web query:

OpenRouter @preset/glm-4-7 GLM-4.7 preset documentation

💡 Result:

I couldn't find a public OpenRouter documentation page specifically for a builtin preset named "@preset/glm-4-7". OpenRouter's presets feature docs (how to reference presets like @preset/ in API requests) are here: [1]. For GLM‑4.7 model details you can refer to the GLM project/announcements (example: GLM-4.7 overview). [2]

If you want the exact preset config for @preset/glm-4-7 (provider routing, system prompt, params, fallbacks), check your OpenRouter dashboard Presets page (organization presets) or ask the OpenRouter team/support to export the preset — presets are managed via the web app and the API as described in the docs. [1][2]

Sources:
[1] OpenRouter — Presets documentation.
[2] GLM‑4.7 model overview (GLM project / OpenLM.ai coverage).


Model key "glm-4-6" should be renamed to "glm-4-7" to match the preset version.

The key is currently "glm-4-6" while the mapped preset is "@preset/glm-4-7", creating a confusing mismatch. Since no references to this key exist elsewhere in the codebase, renaming is safe.

Suggested fix
 			"models": {
-				"glm-4-6": {
+				"glm-4-7": {
 					"id": "@preset/glm-4-7",
 					"name": "Preset GLM-4.7 (via OpenRouter)"
 				}
 			}

Ensure @preset/glm-4-7 is configured in your OpenRouter dashboard.

📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
"glm-4-6": {
"id": "@preset/glm-4-6",
"name": "Preset GLM-4.6 (via OpenRouter)"
"id": "@preset/glm-4-7",
"name": "Preset GLM-4.7 (via OpenRouter)"
}
"glm-4-7": {
"id": "@preset/glm-4-7",
"name": "Preset GLM-4.7 (via OpenRouter)"
}
🤖 Prompt for AI Agents
In @config/opencode/opencode.jsonc around lines 199 - 202, The config entry uses
the object key "glm-4-6" while the mapped preset id is "@preset/glm-4-7"; rename
the object key from "glm-4-6" to "glm-4-7" so the key matches the preset id
(update the JSON object key where the entry with id "@preset/glm-4-7" is
defined) and verify the "@preset/glm-4-7" preset is configured in your
OpenRouter dashboard.

@shunkakinoki
shunkakinoki merged commit a6fe34c into main Jan 10, 2026
39 checks passed
@shunkakinoki
shunkakinoki deleted the chore/update-opencode-config branch January 10, 2026 06:15
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.

2 participants