Skip to content

refactor!: rename openkakao to Alden, with one release of compatibility - #66

Merged
twoimo merged 5 commits into
mainfrom
rename/openkakao-to-alden
Nov 23, 2026
Merged

twoimo merged 5 commits into
mainfrom
rename/openkakao-to-alden

Conversation

@twoimo

@twoimo twoimo commented Nov 23, 2026 •

Copy link
Copy Markdown
Owner

Why

The owner asked for every openkakao name in this project to become Alden, with none left out. The project is named Alden, but the crate, the binary, the environment variables, the state directory and the launchd labels still carried the upstream name. A production host on the owner's Mac runs under the old names, so the change is source only and the next bake needs a migration that cannot lose the reply queue.

What changed

  • scripts/dev/rename_openkakao_to_alden.py renames the tree and lists every place the old name stays, each with a reason. The second commit is its output and nothing else.
  • A pre-rename install keeps working for one release. The old directories are used in place, OPENKAKAO_* is read as ALDEN_*, hooks and webhooks get both names, and the launchd scripts retire an old label or refuse to run beside it.
  • docs/migrating-from-openkakao.md has the operator steps for the next bake. CI now fails on a new occurrence of the old name.

Scope

  • Covers the Rust crates, the Python and shell runtime, the Swift menu extra, the Tauri app, the workflows and the live docs.
  • Leaves out the installed /Applications/Alden.app and its com.openkakao.alden.* agents. They come from the unmerged codex/alden-* lineage. Nothing was baked, installed, restarted or signalled.
  • Leaves "Jarvis" alone. The desktop app is Alden Jarvis.app here, and becomes Alden.app when that lineage is rebased.
  • Follow-ups: regenerate the four Archify bundles named openkakao-*, delete the compatibility code in the release after the first Alden-named one, and stop the staged CLI from loading its scripts from the build checkout.

Tradeoffs

  • No automatic move or symlink of the state directory. The state-root walk opens every path component with O_NOFOLLOW, so the host refuses a state root under a symlink, and a rename under a running host cuts it off from its queue. The old directory is used in place instead, and the operator renames it by hand with every host stopped.
  • The old directory wins while it exists. If the new name won, one stray mkdir of alden would switch every component to an empty queue.
  • Helpers are inlined in 45 scripts instead of one shared module. A shared module needs an entry in three hand-kept bundle lists, and a miss there is an import error in the frozen runtime. The tool holds the one copy of each helper and check fails when a script's copy differs.
  • io.github.twoimo.alden.*, not com.alden.*. Apple asks for reverse-DNS identifiers, and the project controls twoimo.github.io, not alden.com. The prefix is one rule in the tool if the owner prefers another.

Blast Radius

The stable CLI loads its Python runtime from the checkout it was built in, so pulling this change into that checkout under a running pre-rename host stops its sends until the bake. Pull only in the bake window. The bake itself changes the stable CLI path, its signing identifier and every launchd label, so macOS asks for Accessibility, Full Disk Access and Automation approval again, and the host sends nothing until the operator grants it. A webhook receiver, a hook or a launcher that uses the old names keeps working for one release and breaks in the one after.

Verification

All runs used nice, one suite at a time, an empty scratch HOME and a cleared environment.

  • Baseline on 2432ed7, the pure rename commit, and the tip all pass the CI commands. cargo test 1173 → 1173 → 1191, the CI Python list 1383 → 1383 → 1399 (9 skipped each time), desktop cargo test 86 → 86 → 89, desktop npm test 204. cargo fmt --check, cargo clippy -D warnings and the launchd harness pass at each point. Hosted Actions pass too.
  • The migration tests fail on the test-only commit (6 of 9 Rust tests, 12 of 16 Python tests) and pass on the next one. They build a temp HOME with old-style directories, old variable names and old LaunchAgent plists, and run the launchd scripts against a fake launchctl.
  • verify rebuilds the rename commit from its parent: 512 files compared, 0 differ. verify and check fail on each of 22 planted mutations, and verify fails on an empty comparison. Neither can tell whether the keep list itself is right, so the four frozen values each have a known-answer test.

Names

Surface Before After Convention
Cargo package, binary openkakao-cli alden-cli Cargo package names use hyphens. The codex/alden-* lineage already chose it, and a bare alden collides with Alden.app on a case-insensitive volume.
Library crate openkakao_cli alden_cli Cargo derives it from the package name.
Second binary openkakao-auto-reply-health alden-auto-reply-health
Rust types OpenKakaoConfig, OpenKakaoError, OpenKakaoState AldenConfig, AldenError, AldenState UpperCamelCase.
Python projects openkakao-jarvis-browser, openkakao-jarvis-voice alden-jarvis-browser, alden-jarvis-voice Lowercase with hyphens. Python identifiers stay snake_case (_resolve_alden_bin).
Environment OPENKAKAO_* ALDEN_* Uppercase with underscores.
Config directory ~/.config/openkakao ~/.config/alden Lowercase, as before.
State directory ~/Library/Application Support/openkakao ~/Library/Application Support/alden One lowercase spelling for config, state and logs.
Bundle IDs, launchd labels, signing identifiers com.openkakao.* io.github.twoimo.alden.* Reverse-DNS under a domain the project controls.
Desktop app OpenKakao Jarvis.app, openkakao-jarvis-desktop Alden Jarvis.app, alden-jarvis-desktop
Webhook headers X-OpenKakao-Timestamp, X-OpenKakao-Signature X-Alden-Timestamp, X-Alden-Signature
Send prefix [Sent via openkakao] [Sent via Alden]
Release asset openkakao-cli-darwin-<arch> alden-cli-darwin-<arch>

Three values a user can see or a server receives changed and have no fallback: the send prefix, the User-Agent of link fetches (alden-auto-reply/1.0), and one seeded knowledge-graph description that said "오픈카카오 봇".

Migration

  • Directories. One helper per language returns the old directory while it exists as a real directory, and alden otherwise. Both builds then open the same queue database (schema v3) and take the same owner locks.
  • Environment. Each entry point renames OPENKAKAO_* to ALDEN_* in its own process before it reads anything, and prints one deprecation note per adopted name. An ALDEN_* value wins.
  • Hooks and webhooks. Hook programs get each event variable under both names. Signed webhooks carry both header pairs.
  • Labels. scripts/rebake-and-restart.sh and the session-monitor uninstall boot out com.openkakao.auto-reply.session-monitor and set its plist aside. The watch and health installer retires its old pair. The status probe and the desktop and direct-service installers refuse to run while an old plist is installed.
  • Not automated. The directories are not moved, and install-swift-auto-reply-menubar.sh does not check for its old label. The doc gives the commands for both.
  • Review. Five independent passes by fresh agents. The first found that the staged CLI loads its scripts from the build checkout and that the launchd scripts ignored old labels. Both are handled here, and the later passes corrected the operator procedure against the code.

Remaining occurrences

git grep -i openkakao went from 2,681 occurrences in 228 files to 953 in 101. Each one is covered by a row below. python3 scripts/dev/rename_openkakao_to_alden.py check prints this table and fails on anything else.

Two kinds go beyond the three the task named. "Frozen persisted value" covers hash inputs and the device name sent to Kakao's login API. Renaming them would re-key stored data or change what the client sends to Kakao. The Archify bundles count as dated records, because each receipt pins the SHA-256 and the file names of its bundle.

Every remaining occurrence, by reason
Kind Where Hits Why it stays
dated record CHANGELOG.md 69 in 1 files release history, and the entry that announces this rename
dated record STATUS.md 1 in 1 files session status, overwritten on main after each merge
dated record docs/engineering-status.md 59 in 1 files point-in-time verification history
dated record docs/rag-quality-analysis-20260826.md 2 in 1 files analysis of the 2026-08-27 runtime
dated record docs/architecture/* 425 in 48 files Archify bundles and live proofs; each receipt pins the SHA-256 and file names of its bundle
dated record README*.md docs/architecture/[\w.-]*openkakao[\w.-]* 4 in 2 files link to an Archify bundle whose file name its receipt pins
dated record voice/models/hey_jarvis_ko_ridge.onnx 1 in 1 files trained wake model; its producer_name metadata changes only by retraining
upstream project * JungHoonGhae/(?:homebrew-)?openkakao(?:-cli)? 2 in 2 files the upstream repository this project was derived from
frozen persisted value src/local_db.rs openkakao-local-account-v1 1 in 1 files hash input of the account fingerprint that binds context databases and checkpoints
frozen persisted value scripts/auto_reply_ondevice.py openkakao/ondevice/probe/v1 1 in 1 files hash input of the gateway probe session id
frozen persisted value scripts/auto-reply-worker.py session_lane = "openkakao-bujamentor"|session/v1\\0openkakao-bujamentor" 1 in 1 files hash input of the provider session id
frozen persisted value scripts/auto_reply_reference_store.py "자동답변", "openkakao" 1 in 1 files topic keyword matched against chat text that already says it
migration code scripts/status-auto-reply-service.sh com\.openkakao\.bujamentor\.session-monitor 2 in 1 files label an older install registered; the status probe still finds it
migration code scripts/uninstall-auto-reply-session-monitor.sh com\.openkakao\.bujamentor\.session-monitor 1 in 1 files label an older install registered; uninstall still boots it out
dated record scripts/build-swift-auto-reply-menubar.sh signed as com\.openkakao\.menubar 1 in 1 files comment on the identifier an earlier build was signed with
frozen persisted value src/commands/auth.rs, src/model.rs, src/credentials.rs DEVICE_NAME: &str = "openkakao-cli"|"openkakao-cli"\.to_string\(\)|device_name, "openkakao-cli" 3 in 2 files device name in the login request to Kakao's servers, in credentials.json and in KakaoTalk's device list
migration code src/pre_rename.rs 16 in 1 files the CLI's one-release compatibility module
migration code desktop/src-tauri/src/pre_rename.rs 8 in 1 files the desktop app's copy of that module
migration code macos/AutoReplyMenu/main.swift pre-rename openkakao directory|base \+ "/openkakao" 2 in 1 files the menu extra's copy of the directory shim
migration code src/commands/watch.rs "X-OpenKakao-(?:Timestamp|Signature)", (?:timestamp|signature)\),|X-OpenKakao-* pair|"X-Alden", "X-OpenKakao" 4 in 1 files webhook signature headers, sent under both names for one release
migration code scripts/* PRE_RENAME_[A-Z]+="[^"\n]*com\.openkakao\.auto-reply\.[a-z-]+(?:\.plist)?"|for pre_rename_label in com\.openkakao\.[a-z.-]+ com\.openkakao\.[a-z.-]+; do 15 in 9 files launchd labels from before the rename, which a script retires or refuses to run beside
migration code tests/pre_rename_migration.rs, tests/test_pre_rename_adoption.py 31 in 2 files tests that build a pre-rename HOME and environment
migration code tests/cli_test.rs, tests/auto_reply_hermetic.py \|\| key_text\.starts_with\("OPENKAKAO_"\)|"ALDEN", "OPENKAKAO"\) 2 in 2 files test isolation clears the pre-rename variables too
migration code docs/migrating-from-openkakao.md 37 in 1 files operator steps for a Mac that ran a pre-rename build
migration code * migrating-from-openkakao\.md 10 in 9 files pointer to those operator steps
migration code AGENTS.md keeps both under openkakao`` 1 in 1 files safety rule for the directories a pre-rename Mac still has
rename tool * rename_openkakao_to_alden\.py 2 in 2 files command line that runs this script
rename tool scripts/dev/rename_openkakao_to_alden.py 55 in 1 files this script
migration code scripts/*, voice/run-voice.sh (13 line patterns) 231 in 45 files line of a one-release shim, identical in every script that has it

Outside the repository, the three frozen menu-bar .pyc files on the owner's Mac still embed the old default state root.

🤖 Generated with Claude Code

@twoimo
twoimo force-pushed the rename/openkakao-to-alden branch 4 times, most recently from ad82687 to 382ea07 Compare November 23, 2026 06:16
twoimo and others added 5 commits November 23, 2026 15:18
The project is named Alden, but the crate, binary, environment variables,
state directory and launchd labels still carry the upstream name. Renaming
2,100 occurrences in 190 files by hand cannot be reviewed or repeated.

`scripts/dev/rename_openkakao_to_alden.py` holds the naming table (`RULES`)
and the complete list of places where the old name must stay (`KEEP`), each
with a reason.

- `apply` rewrites the tree. A second run changes nothing.
- `shims` gives the runtime scripts the helpers that keep a pre-rename
  install working for one release. The helper texts live only in the tool.
- `check` fails on any occurrence that `KEEP` does not cover, on any `KEEP`
  entry that matches nothing, and on a script whose helper copy differs.
- `verify BASE REV` rebuilds a commit from its base, so a reviewer can
  confirm that the rename commit is tool output and nothing else.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This commit is the output of `scripts/dev/rename_openkakao_to_alden.py apply`
and nothing else. Reproduce it with
`python3 scripts/dev/rename_openkakao_to_alden.py verify HEAD~1 HEAD`.

Each name follows its surface's convention:

- Cargo package and binary `alden-cli`, library crate `alden_cli`, second
  binary `alden-auto-reply-health`. Cargo package names use hyphens and the
  library name is the same with underscores. The closed `codex/alden-*`
  lineage already chose `alden-cli`, and a bare `alden` would collide with
  `Alden.app` on a case-insensitive volume.
- Types `AldenConfig`, `AldenError`, `AldenState`.
- Environment variables `ALDEN_*`.
- Directories `~/.config/alden` and `~/Library/Application Support/alden`,
  one lowercase spelling for both.
- Bundle IDs, launchd labels and codesign identifiers under
  `io.github.twoimo.alden.`. Apple asks for reverse-DNS names, and
  `twoimo.github.io` is the domain this project controls.
- The Tauri app `Alden Jarvis.app` with executable `alden-jarvis-desktop`,
  and the Python projects `alden-jarvis-browser` and `alden-jarvis-voice`.
- Webhook headers `X-Alden-Timestamp` and `X-Alden-Signature`, the send
  prefix `[Sent via Alden]`, and the release asset `alden-cli-darwin-<arch>`.

`cargo fmt` re-wrapped the lines the shorter names changed, and the three
lockfiles were re-sorted by package name.

The tool's `KEEP` list names what stays: dated records, the upstream
repository's URLs, hash inputs of persisted identities, and the device name
sent to Kakao's login API.

BREAKING CHANGE: every name above changed. The next commits keep a
pre-rename install working for one release.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
The first Alden-named release will run on Macs whose files and launchers
still carry the `openkakao` names. These tests build such a HOME or
environment and state what must happen there:

- The pre-rename config and state directories are used in place while they
  exist, a stray `alden` directory beside them is ignored, and a symlink at
  the old name is not adopted.
- `OPENKAKAO_*` variables are read as `ALDEN_*` with a deprecation note, and
  the `ALDEN_*` name wins when both are set.
- A hook program receives each event variable under both names.
- The launchd scripts find the pre-rename state root, and each one either
  retires a LaunchAgent that still has its old label or refuses to run
  beside it.
- The two gateway session ids keep their values.

They fail on this commit: the renamed build looks only under the new names.
The next commit makes them pass.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
A Mac that ran an `openkakao-cli` build keeps its reply queue, owner locks
and context database under `~/Library/Application Support/openkakao`, sets
`OPENKAKAO_*` variables in its launchers, has LaunchAgents loaded under
`com.openkakao.*` labels, and has hooks and webhook receivers written against
the old names. The renamed build would have started from an empty `alden`
directory, ignored those variables, and run beside the old agents.

- Directories. Every default path goes through one helper per language. It
  returns the pre-rename directory while that directory exists, and `alden`
  otherwise. Nothing is moved or linked. The state-root walk opens every
  path component with `O_NOFOLLOW`, so the host refuses a state root under a
  symlink, and a rename under a running host would cut it off from its queue. Because the old directory wins, a stray `alden`
  directory cannot split the queue.
- Environment. Each entry point renames `OPENKAKAO_*` to `ALDEN_*` in its own
  process before it reads anything, and prints one deprecation note per
  adopted name. An `ALDEN_*` value wins.
- Hooks and webhooks. Hook programs receive each event variable under both
  names, and signed webhooks carry both header pairs.
- Labels. `rebake-and-restart.sh` and the session-monitor uninstall boot out
  the pre-rename monitor label and set its plist aside. The watch and health
  installer retires its old pair. The status probe and the desktop and
  direct-service installers refuse to run while an old plist is installed,
  because they cannot vouch for it or would start a second agent beside it.
- Frozen values. The account fingerprint, the Kakao device name and the two
  gateway session ids keep their pre-rename inputs. Each now has a
  known-answer test, so a later rename of the input fails a test instead of
  re-keying stored data without notice.

The Rust side lives in `src/pre_rename.rs`, with a counterpart in the desktop
crate. The script helpers are the output of
`rename_openkakao_to_alden.py shims`, and `check` requires all 45 copies to
equal the text in the tool. Everything here except the frozen values is meant
to be deleted in the release after the first Alden-named one.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…e in CI

`docs/migrating-from-openkakao.md` is the procedure for the first bake on a
Mac that ran a pre-rename build. It leads with the two things an operator
cannot skip:

- Do not pull this change into the checkout a running host was built in. The
  stable binary loads its Python runtime from that checkout, and an old
  binary cannot drive the renamed scripts.
- The stable CLI path and its signing identifier changed, so macOS asks for
  Accessibility, Full Disk Access and Automation approval again.

It then covers the launchd label switch, the way back, and the optional move
of the directories to their new names.

The launchd runbook, both READMEs and `AGENTS.md` point to it, and the
CHANGELOG lists the operator steps under a BREAKING entry.
`CONTRIBUTING.md` now clones this repository instead of the upstream one.

CI runs `rename_openkakao_to_alden.py check`, so a new occurrence of the old
name fails the build unless `KEEP` lists it with a reason. CI also runs the
new `tests.test_pre_rename_adoption` module.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@twoimo
twoimo force-pushed the rename/openkakao-to-alden branch from 382ea07 to 7620d92 Compare November 23, 2026 06:18
@twoimo
twoimo merged commit 9ffc8f0 into main Nov 23, 2026
4 checks passed
twoimo added a commit that referenced this pull request Nov 23, 2026
PR #66 merged. The status now names the procedure for the first
Alden-named bake, the two follow-up issues, and the one thing that can stop
the running host before that bake: a pull into the checkout its binary was
built in.

Hosted Actions ran on the PR, so the billing blocker is removed.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
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