agent-sin 0.1.1 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -15,6 +15,15 @@ See the [compatibility policy](https://agent.shingoirie.com/versioning) for deta
15
15
 
16
16
  ---
17
17
 
18
+ ## [0.1.2] — 2026-05-14
19
+
20
+ ### Fixed
21
+
22
+ - `agent-sin setup` no longer writes `defaults.locale` into `config.toml`. The locale is now resolved fresh on every run from `AGENT_SIN_LOCALE` or the OS-level Intl locale. This prevents a stale `locale = "ja"` from being pinned at first setup (for example via `curl ... install.sh | bash` on a Mac whose shell still inherits `LANG=ja_JP.UTF-8`) and surviving subsequent re-installs.
23
+ - Existing workspaces with the wrong locale: remove the `locale` line from `~/.agent-sin/config.toml`, or run with `AGENT_SIN_LOCALE=en`. `sed -i '' '/^locale = /d' ~/.agent-sin/config.toml` works on macOS.
24
+
25
+ ---
26
+
18
27
  ## [0.1.1] — 2026-05-14
19
28
 
20
29
  ### Fixed
@@ -131,35 +131,14 @@ export function defaultConfig(workspace = defaultWorkspace()) {
131
131
  event_log_retention_days: 90,
132
132
  defaults: {
133
133
  note_format: "daily_markdown",
134
- locale: detectInstallLocale(),
134
+ // locale is intentionally not persisted: every run detects it fresh from
135
+ // AGENT_SIN_LOCALE / Intl, so users who switch their OS language never
136
+ // get stuck with a stale ja/en pinned at first setup.
135
137
  },
136
138
  chat_model_id: "codex-low",
137
139
  builder_model_id: "codex-xhigh",
138
140
  };
139
141
  }
140
- function detectInstallLocale() {
141
- const explicit = (process.env.AGENT_SIN_LOCALE || "").trim().toLowerCase();
142
- if (explicit === "ja" || explicit === "en")
143
- return explicit;
144
- // Prefer the OS-level locale (Intl) over shell LANG: when a user switches the
145
- // macOS system language, the shell's LANG often keeps its old value, which
146
- // would otherwise persist a stale ja locale into config.toml.
147
- try {
148
- const intlLocale = (Intl.DateTimeFormat().resolvedOptions().locale || "").toLowerCase();
149
- if (/^ja(-|$)/.test(intlLocale))
150
- return "ja";
151
- if (/^en(-|$)/.test(intlLocale))
152
- return "en";
153
- }
154
- catch {
155
- // ignored
156
- }
157
- const lang = (process.env.LC_ALL || process.env.LANG || "").trim();
158
- if (lang) {
159
- return /^ja(_|$|-)/i.test(lang) ? "ja" : "en";
160
- }
161
- return undefined;
162
- }
163
142
  export function defaultModels() {
164
143
  return {
165
144
  roles: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agent-sin",
3
- "version": "0.1.1",
3
+ "version": "0.1.2",
4
4
  "description": "Program Skill-first personal AI agent OS CLI.",
5
5
  "type": "module",
6
6
  "license": "MIT",