Skip to content

feat(kin): the owner edits the standing rules on web and phone - #1104

Merged
GLDRoger merged 7 commits into
kinfrom
train-19-1129/step-3
Nov 29, 2026
Merged

GLDRoger merged 7 commits into
kinfrom
train-19-1129/step-3

Conversation

@GLDRoger

Copy link
Copy Markdown
Owner

The owner could change the standing rules only by editing a file outside the app. The server now has owner-only calls to read and save them, but no screen used them.

  • Settings → Standing rules is shown to the company owner alone. On web it sits beside Memory and in the command palette, and desktop gets it through web. On the phone it is in Settings. Co-owners and teammates see no page, row or palette entry.
  • A plain-text editor covers every state: loading, no rules yet, unsaved changes (leaving asks first), saving, and saved ("Your agents follow these from their next turn"). If the rules changed after the owner opened them, the draft stays, the current rules show with who changed them, and replacing them asks first. Rules too large to show can be replaced after a question. Emptying the rules asks first. Every failure keeps the draft.
  • The shared logic and copy live in client-runtime, alongside the read and save commands, a feature-map entry and a Standing rules section in the user guide.

People-change: The owner can read and change the standing rules every agent follows from Settings on web and phone, and agents follow a saved change from their next turn.

Checked as part of train 19's one check at the tip.

An independent review by Claude Opus 5.5 found the screens LAND AFTER FIXES. Its fix is on this branch, with one later commit that asks before replacing changed rules.

🤖 Generated with Claude Code

GLDRoger and others added 7 commits November 29, 2026 22:46
Settings → Standing rules, beside Memory on web (and in the command palette) and under Agents
in the phone's Settings, for the owner alone. The owner reads the rules, edits them as plain text
and saves over the revision opened. A save that finds them changed keeps the draft and shows the
current rules above it; only the owner's next Save replaces them. Emptying them asks first, text
over 256 KiB says how far over, and leaving with a draft asks before discarding it.

People-change: The owner can read and change the standing rules every agent follows from Settings on web and phone, and agents follow a saved change from their next turn.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Use the contract's KinMemoryRulesPairAgain and KinMemoryRulesTooLarge in place of the placeholder.
Pair again shows the host's sentence (with This phone on the phone); the development token's plain
refusal stays plain. Rules too large to show open a blank replacement editor: Replace rules asks
first, says the current rules can't be shown, and sends the revision the refusal named; a repeated
refusal is shown, never retried. The no-publish refusal shows the host's sentence without a retry.

People-change: When standing rules are too large to show, the owner can replace them with shorter ones from Settings, and a device that needs pairing again is told so.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…'t seen

After a save finds the standing rules changed, the page shows the current
rules and the owner's next Save goes over them. A held Cmd/Ctrl+S kept
repeating keydown events, so the repeat itself sent that next save at once,
replacing rules the owner had not read. Key repeats are now ignored; only a
fresh press saves.

People-change: Holding Cmd/Ctrl+S on Standing rules saves once; it never replaces rules someone else just changed without the owner seeing them.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…hen agents are stopped

After a save finds the standing rules changed, the next Save asks "Replace the current rules with
your text?" (with who changed them), on web and phone; a fast second tap can no longer replace
rules the owner hasn't read. Save is available whenever the draft differs from the current rules,
so the owner can put the opened text back. The phone keeps its leave guard while a save is in
flight. Rules too large to show now say that agents can't work until they're replaced.

People-change: Saving over standing rules someone else just changed asks first, and the owner is told that oversized rules stop the agents until they're replaced.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
People-change: none

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
People-change: none

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@GLDRoger
GLDRoger merged commit b6ec4a9 into kin Nov 29, 2026
13 of 17 checks passed
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 29, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-29T22:28:25.146053Z 2f5730e PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions

Copy link
Copy Markdown

This PR changes the test suite by +16 test cases (browser +2, unit +14, server 0).

New browser test files: apps/web/src/kin/settings/KinRulesPage.browser.test.tsx.
Each browser test file costs CI seconds of module loading before its first test runs; a unit test costs milliseconds.

Keep tests that would fail for a real reason, and test logic below the UI where it can be. See Testing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant