sideby 0.24.0 → 0.25.0
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/README.md +2 -1
- package/dist/build.json +1 -1
- package/dist/src/cli/commands.js +7 -5
- package/dist/src/cli/json-schemas.js +1 -0
- package/dist/src/cli/main.js +3 -3
- package/dist/src/core/ask.d.ts +10 -6
- package/dist/src/core/ask.js +47 -9
- package/dist/src/families/agy/index.js +4 -1
- package/dist/src/families/claude/index.js +4 -1
- package/dist/src/families/codex/index.js +8 -1
- package/dist/src/families/grok/index.js +4 -1
- package/dist/src/families/pi/index.js +4 -1
- package/dist/src/panel/handler.js +1 -1
- package/dist/src/types.d.ts +7 -0
- package/package.json +2 -2
- package/schemas/try.json +4 -0
- package/skills/sideby/SKILL.md +2 -2
- package/skills/sideby/references/ai-tasks.md +1 -0
package/README.md
CHANGED
|
@@ -92,7 +92,8 @@ cc-switch's docs describe that switch: it writes the live settings file ([README
|
|
|
92
92
|
| Find the cheapest auto-compact size from your own sessions, and use it in one click | `sideby tune` (or the panel's Context tuning tab) | [Context tuning](docs/guide/usage.md#context-tuning) |
|
|
93
93
|
| See each account's model and effort, and set them per account | `sideby model <account>` (or click the model in the panel) | [Model and effort](docs/guide/usage.md#model-and-effort) |
|
|
94
94
|
| Choose whether Claude sessions connect to claude.ai by themselves (Remote Control), for every account at once | `sideby remote-control off` or `on` (or the panel's Settings) | [Remote Control](docs/guide/usage.md#remote-control) |
|
|
95
|
-
| Pin the accounts you use most
|
|
95
|
+
| Pin the accounts you use most, put tools and accounts in your own order, and hide the ones you never use | `sideby pin claude:work`, `sideby order`, `sideby hide grok` (or the panel's Settings) | [Your own order](docs/guide/usage.md#your-own-order) |
|
|
96
|
+
| Give the panel other colors: five built-in Themes, your own color, or one your AI writes | **Settings › Theme** in the panel, or `sideby theme use leaf` | [Themes](docs/guide/panel.md#themes) |
|
|
96
97
|
| Move on when an account hits its limit | `sideby next claude` | [Handoff](docs/guide/usage.md#when-an-account-hits-its-limit) |
|
|
97
98
|
| Let a running task move to the next account by itself when quota runs low (off by default; see the risk) | `sideby handoff enable` (or the panel) | [Auto Handoff](docs/guide/usage.md#auto-handoff) |
|
|
98
99
|
| Short commands such as `ccw` | `sideby alias add ccw claude:work` | [Shell functions](docs/guide/configuration.md#shell-functions) |
|
package/dist/build.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"id":"
|
|
1
|
+
{"id":"20261026T102043-565ca8"}
|
package/dist/src/cli/commands.js
CHANGED
|
@@ -2429,19 +2429,21 @@ export async function cmdKey(a, io, runtime) {
|
|
|
2429
2429
|
export async function cmdTry(a, io) {
|
|
2430
2430
|
const { tryAccount, tryPreview } = await import('../core/ask.js');
|
|
2431
2431
|
if (a.positionals.length !== 1 || a.rest.length)
|
|
2432
|
-
throw new UsageError('Use sideby try <account> [--yes] [--json].');
|
|
2432
|
+
throw new UsageError('Use sideby try <account> [--model <model>] [--yes] [--json].');
|
|
2433
|
+
const model = a.flags.get('model');
|
|
2433
2434
|
const rt = await createRuntime();
|
|
2434
|
-
const
|
|
2435
|
+
const ref = a.positionals[0];
|
|
2436
|
+
const { account, command } = await tryPreview(rt, ref, model);
|
|
2435
2437
|
if (!a.flags.has('yes')) {
|
|
2436
2438
|
if (a.flags.has('json'))
|
|
2437
|
-
json(io, { account: account.ref, command, confirmed: false });
|
|
2439
|
+
json(io, { account: account.ref, ...(model === undefined ? {} : { model }), command, confirmed: false });
|
|
2438
2440
|
else
|
|
2439
2441
|
io.out(`This spends a few tokens: ${command.map((v) => JSON.stringify(v)).join(' ')}. Run again with --yes to continue.`);
|
|
2440
2442
|
return 10;
|
|
2441
2443
|
}
|
|
2442
|
-
const { account:
|
|
2444
|
+
const { account: done, command: _command, ...result } = await tryAccount(rt, ref, undefined, model);
|
|
2443
2445
|
if (a.flags.has('json'))
|
|
2444
|
-
json(io, { account:
|
|
2446
|
+
json(io, { account: done, confirmed: true, ...result });
|
|
2445
2447
|
else
|
|
2446
2448
|
io.out(result.ok ? 'OK' : result.output || 'The Host did not reply; check the account and try again.');
|
|
2447
2449
|
return result.ok ? 0 : 1;
|
|
@@ -1285,6 +1285,7 @@ export const OUTPUT_SCHEMAS = {
|
|
|
1285
1285
|
try: Type.Object({
|
|
1286
1286
|
schemaVersion: Version,
|
|
1287
1287
|
account: Str,
|
|
1288
|
+
model: Type.Optional(Type.String({ description: 'The model `--model` chose, when given.' })),
|
|
1288
1289
|
confirmed: Type.Boolean(),
|
|
1289
1290
|
command: Type.Optional(Type.Array(Str)),
|
|
1290
1291
|
ok: Type.Optional(Type.Boolean()),
|
package/dist/src/cli/main.js
CHANGED
|
@@ -10,7 +10,7 @@ Usage:
|
|
|
10
10
|
sideby ask [<text>] [--print] let your AI handle a sideby task
|
|
11
11
|
sideby terminal [--set <id>|--custom <t>|--unset] choose your terminal
|
|
12
12
|
sideby key <account> [--var <NAME>] enter an API key without echo
|
|
13
|
-
sideby try <account> [--
|
|
13
|
+
sideby try <account> [--model <m>] try the Host with a short paid request
|
|
14
14
|
sideby list accounts (same as \`sideby list\`)
|
|
15
15
|
sideby list --all also list hidden families and accounts
|
|
16
16
|
sideby run <account> [-- args] start the host CLI for one account
|
|
@@ -153,7 +153,7 @@ const COMMAND_HELP = {
|
|
|
153
153
|
ask: 'sideby ask [<text>] [--task free|fix|quota|account|host|plugin|terminal|handoff|theme|menubar|hotkey] [--account <ref>] [--terminal <id>] [--attach <file>]... [--print] [--json]\nsideby ask --run <id> [--state-dir <dir>]\nsideby ask --spec - [--print] --json\nsideby ask --choices --json\nOpen a task in your terminal. --spec reads a Task Spec (one JSON object, at most 1 MB) from stdin, as a Portal sends it; --choices lists the accounts and terminals a task can use. --attach adds an image (PNG, JPEG, GIF, WebP; up to 20 MB) or a video (MP4, MOV, WebM; up to 200 MB), at most 5. --print prints only the prompt. If opening fails, paste the command into a terminal.',
|
|
154
154
|
terminal: "sideby terminal [--set <id>|--custom '<program> … {cwd} … {cmd}'|--unset] [--json]\nList terminals or save your preference; --custom saves and selects your own launch command.",
|
|
155
155
|
key: 'sideby key <account> [--var <NAME>] [--json]\nEnter an API key without echo. Run in a terminal or use the Panel key box.',
|
|
156
|
-
try: 'sideby try <account> [--yes] [--json]\nSend a short request through the Host. This spends a few tokens. Exit 10 waits for --yes.',
|
|
156
|
+
try: 'sideby try <account> [--model <model>] [--yes] [--json]\nSend a short request through the Host. This spends a few tokens. Exit 10 waits for --yes.\n<account> may be a short command; its arguments apply as in sideby run. --model tries another model once.',
|
|
157
157
|
plugins: 'sideby plugins [--json]\nsideby plugins new <id> [--json]\nsideby plugins check <id|path> [--json]\nPlugins run as you, with your permissions. Only load plugins you trust.',
|
|
158
158
|
new: `sideby new <family> <name> [--api] [--alias <short>] [--json]
|
|
159
159
|
sideby new <family> --next [--api] [--alias <short>] [--json]
|
|
@@ -493,7 +493,7 @@ const COMMANDS = {
|
|
|
493
493
|
},
|
|
494
494
|
terminal: { flags: ['json', 'unset'], valued: ['set', 'custom'] },
|
|
495
495
|
key: { flags: ['json'], valued: ['var'] },
|
|
496
|
-
try: { flags: ['json', 'yes'] },
|
|
496
|
+
try: { flags: ['json', 'yes'], valued: ['model'] },
|
|
497
497
|
autostart: { flags: ['json', 'yes', 'refresh'] },
|
|
498
498
|
menubar: { flags: ['json', 'yes', 'refresh'], valued: ['lang', 'hotkey', 'hotkey-label', 'icon'] },
|
|
499
499
|
config: { flags: ['json', 'yes'] },
|
package/dist/src/core/ask.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { taskPrompt } from '../panel/page-logic.ts';
|
|
2
2
|
import type { Runtime } from '../runtime.ts';
|
|
3
|
-
import type { Account, Env } from '../types.ts';
|
|
3
|
+
import type { Account, Env, FamilyDef } from '../types.ts';
|
|
4
4
|
import { type Attachment } from './attachments.ts';
|
|
5
5
|
import { UserError } from './errors.ts';
|
|
6
6
|
import { type Paths } from './paths.ts';
|
|
@@ -213,12 +213,14 @@ export declare function openPickInTerminal(rt: Runtime, name: string): Promise<{
|
|
|
213
213
|
detail?: string | undefined;
|
|
214
214
|
}>;
|
|
215
215
|
/**
|
|
216
|
-
* What `try` will run for an Account, computed as `sideby run` would (Family defaults, config arguments
|
|
217
|
-
* reading its Secret File or running `launch.before` hooks: nothing runs before the
|
|
216
|
+
* What `try` will run for an Account, computed as `sideby run` would (Family defaults, config arguments, a short
|
|
217
|
+
* command's arguments) but without reading its Secret File or running `launch.before` hooks: nothing runs before the
|
|
218
|
+
* user agrees. `model` replaces the model those arguments choose.
|
|
218
219
|
*/
|
|
219
|
-
export declare function tryPreview(rt: Runtime, ref: string): Promise<{
|
|
220
|
+
export declare function tryPreview(rt: Runtime, ref: string, model?: string): Promise<{
|
|
220
221
|
account: Account;
|
|
221
|
-
family:
|
|
222
|
+
family: FamilyDef;
|
|
223
|
+
probe: string[];
|
|
222
224
|
command: string[];
|
|
223
225
|
}>;
|
|
224
226
|
/**
|
|
@@ -226,12 +228,14 @@ export declare function tryPreview(rt: Runtime, ref: string): Promise<{
|
|
|
226
228
|
* folder under the task directory that is removed afterwards. The caller has already said it spends a few tokens. The
|
|
227
229
|
* launch is prepared once here, so `launch.before` hooks run once, and the command returned is what actually ran.
|
|
228
230
|
* `spawn` replaces the process start (tests); by default the Host runs with stdin ignored and is killed at the timeout.
|
|
231
|
+
* `ref` may be a short command, whose arguments apply as in `sideby run`; `model` replaces the model they choose.
|
|
229
232
|
*/
|
|
230
|
-
export declare function tryAccount(rt: Runtime, ref: string, spawn?: ProbeDeps['spawn']): Promise<{
|
|
233
|
+
export declare function tryAccount(rt: Runtime, ref: string, spawn?: ProbeDeps['spawn'], model?: string): Promise<{
|
|
231
234
|
ok: boolean;
|
|
232
235
|
exitCode: number | null;
|
|
233
236
|
output: string;
|
|
234
237
|
timedOut: boolean;
|
|
235
238
|
account: string;
|
|
239
|
+
model?: string | undefined;
|
|
236
240
|
command: string[];
|
|
237
241
|
}>;
|
package/dist/src/core/ask.js
CHANGED
|
@@ -3,6 +3,7 @@ import { constants } from 'node:fs';
|
|
|
3
3
|
import { lstat, mkdtemp, open, readdir, realpath, rm, stat, unlink } from 'node:fs/promises';
|
|
4
4
|
import { userInfo } from 'node:os';
|
|
5
5
|
import { dirname, isAbsolute, join, sep } from 'node:path';
|
|
6
|
+
import { MODEL_NAME, takeFlag } from '../families/shared/model-args.js';
|
|
6
7
|
import { AI_TASK_KINDS, stripSecrets, taskPrompt } from '../panel/page-logic.js';
|
|
7
8
|
import { checkAttachmentFiles, copyAttachments, MAX_ATTACHMENTS, privateDir, removeOldAttachments, stagedAttachments, takeStaged, } from './attachments.js';
|
|
8
9
|
import { editConfigAsk, editConfigTerminal } from './config.js';
|
|
@@ -454,33 +455,70 @@ export async function openPickInTerminal(rt, name) {
|
|
|
454
455
|
throw new UserError(`No short command "${name}" picks an account; add one in the Panel or with \`sideby alias add ${name} --pick <family>\`.`);
|
|
455
456
|
return openTask(rt, { kind: 'run', account: name, cwd: rt.paths.home });
|
|
456
457
|
}
|
|
458
|
+
/** The probe arguments for `model`, or the plain probe; refuses a model the Family cannot choose or a malformed name. */
|
|
459
|
+
function probeArgs(family, model) {
|
|
460
|
+
const probe = family.probe;
|
|
461
|
+
if (model === undefined)
|
|
462
|
+
return probe.args;
|
|
463
|
+
if (!probe.model)
|
|
464
|
+
throw new UserError(`${family.title} cannot be tried with another model; leave out --model.`, {
|
|
465
|
+
code: 'no-model-choice',
|
|
466
|
+
});
|
|
467
|
+
if (!MODEL_NAME.test(model))
|
|
468
|
+
throw new UserError('A model name uses letters, digits and ._:/[]- only (at most 100); check the name.', {
|
|
469
|
+
code: 'model-invalid',
|
|
470
|
+
});
|
|
471
|
+
return probe.model.args(model);
|
|
472
|
+
}
|
|
473
|
+
/**
|
|
474
|
+
* With `--model`, the model options of the arguments before the probe's (the Account's and the short command's) are
|
|
475
|
+
* taken out, so the Host gets one model. Arguments a hook added around them stay; if the probe's own arguments
|
|
476
|
+
* cannot be found, nothing changes.
|
|
477
|
+
*/
|
|
478
|
+
function oneModel(args, probe, family, model) {
|
|
479
|
+
if (model === undefined || !family.probe?.model)
|
|
480
|
+
return args;
|
|
481
|
+
for (let at = args.length - probe.length; at >= 0; at--)
|
|
482
|
+
if (probe.every((v, i) => args[at + i] === v))
|
|
483
|
+
return [...takeFlag(args.slice(0, at), family.probe.model.flags).rest, ...args.slice(at)];
|
|
484
|
+
return args;
|
|
485
|
+
}
|
|
457
486
|
/**
|
|
458
|
-
* What `try` will run for an Account, computed as `sideby run` would (Family defaults, config arguments
|
|
459
|
-
* reading its Secret File or running `launch.before` hooks: nothing runs before the
|
|
487
|
+
* What `try` will run for an Account, computed as `sideby run` would (Family defaults, config arguments, a short
|
|
488
|
+
* command's arguments) but without reading its Secret File or running `launch.before` hooks: nothing runs before the
|
|
489
|
+
* user agrees. `model` replaces the model those arguments choose.
|
|
460
490
|
*/
|
|
461
|
-
export async function tryPreview(rt, ref) {
|
|
491
|
+
export async function tryPreview(rt, ref, model) {
|
|
462
492
|
const account = await rt.resolve(ref);
|
|
463
493
|
const family = rt.families.get(account.family);
|
|
464
494
|
if (!family?.probe)
|
|
465
495
|
throw new UserError(`This tool cannot be tried; use \`sideby run ${account.ref}\` instead.`, {
|
|
466
496
|
code: 'no-probe',
|
|
467
497
|
});
|
|
468
|
-
const
|
|
469
|
-
|
|
498
|
+
const probe = probeArgs(family, model);
|
|
499
|
+
const { bin, args } = await rt.launchCommand(ref, probe, 'run');
|
|
500
|
+
return { account, family, probe, command: [bin, ...oneModel(args, probe, family, model)] };
|
|
470
501
|
}
|
|
471
502
|
/**
|
|
472
503
|
* `sideby try` and the Panel (spec §3.28): runs the Family's probe once the way Launch starts the Host, in a temp
|
|
473
504
|
* folder under the task directory that is removed afterwards. The caller has already said it spends a few tokens. The
|
|
474
505
|
* launch is prepared once here, so `launch.before` hooks run once, and the command returned is what actually ran.
|
|
475
506
|
* `spawn` replaces the process start (tests); by default the Host runs with stdin ignored and is killed at the timeout.
|
|
507
|
+
* `ref` may be a short command, whose arguments apply as in `sideby run`; `model` replaces the model they choose.
|
|
476
508
|
*/
|
|
477
|
-
export async function tryAccount(rt, ref, spawn = spawnProbe) {
|
|
478
|
-
const { account, family } = await tryPreview(rt, ref);
|
|
479
|
-
const
|
|
509
|
+
export async function tryAccount(rt, ref, spawn = spawnProbe, model) {
|
|
510
|
+
const { account, family, probe } = await tryPreview(rt, ref, model);
|
|
511
|
+
const prepared = await rt.prepareLaunch(ref, probe, 'run');
|
|
512
|
+
const launch = { ...prepared, args: oneModel(prepared.args, probe, family, model) };
|
|
480
513
|
const cwd = await mkdtemp(join(await taskWorkDir(rt.paths), 'probe-'));
|
|
481
514
|
try {
|
|
482
515
|
const result = await runProbe(account, { family, baseEnv: rt.env, cwd, launch, spawn });
|
|
483
|
-
return {
|
|
516
|
+
return {
|
|
517
|
+
account: account.ref,
|
|
518
|
+
...(model === undefined ? {} : { model }),
|
|
519
|
+
command: [launch.bin, ...launch.args],
|
|
520
|
+
...result,
|
|
521
|
+
};
|
|
484
522
|
}
|
|
485
523
|
finally {
|
|
486
524
|
await rm(cwd, { recursive: true, force: true });
|
|
@@ -28,7 +28,10 @@ export const agyFamily = {
|
|
|
28
28
|
],
|
|
29
29
|
apiVars: [],
|
|
30
30
|
// `-p` is one non-interactive prompt (agy 1.4.4 --help, 2026-10-21).
|
|
31
|
-
probe: {
|
|
31
|
+
probe: {
|
|
32
|
+
args: ['-p', 'Reply with OK'],
|
|
33
|
+
model: { flags: ['--model'], args: (m) => ['--model', m, '-p', 'Reply with OK'] },
|
|
34
|
+
},
|
|
32
35
|
// agy reads a prompt only from -p, -i or stdin: "unexpected argument" otherwise (agy 1.4.4, 2026-10-21).
|
|
33
36
|
promptArg: '--prompt-interactive',
|
|
34
37
|
aiTaskArgs: (args) => args.includes(SKIP_PERMISSIONS) ? args.filter((a) => a !== SKIP_PERMISSIONS) : [...args],
|
|
@@ -108,7 +108,10 @@ export const claudeFamily = {
|
|
|
108
108
|
apiVars: ['ANTHROPIC_BASE_URL', 'ANTHROPIC_AUTH_TOKEN', 'ANTHROPIC_MODEL'],
|
|
109
109
|
secretVar: 'ANTHROPIC_AUTH_TOKEN',
|
|
110
110
|
// `-p` is one non-interactive prompt (Claude Code 2.1.301 --help, 2026-10-17).
|
|
111
|
-
probe: {
|
|
111
|
+
probe: {
|
|
112
|
+
args: ['-p', 'Reply with OK'],
|
|
113
|
+
model: { flags: ['--model'], args: (m) => ['--model', m, '-p', 'Reply with OK'] },
|
|
114
|
+
},
|
|
112
115
|
aiTaskArgs: claudeAiTaskArgs,
|
|
113
116
|
settingsFile: 'settings.json',
|
|
114
117
|
sharedItems: [
|
|
@@ -36,7 +36,14 @@ export const codexFamily = {
|
|
|
36
36
|
secretVar: 'OPENAI_API_KEY',
|
|
37
37
|
// `exec` refuses to run outside a git repo unless this flag is set (Codex 0.163.0 --help:
|
|
38
38
|
// allow running outside a Git repository). The probe's cwd is a temp directory.
|
|
39
|
-
probe: {
|
|
39
|
+
probe: {
|
|
40
|
+
args: ['exec', '--skip-git-repo-check', 'Reply with OK'],
|
|
41
|
+
// `exec` reads its own `-m`; a `-m` before the subcommand does not reach it.
|
|
42
|
+
model: {
|
|
43
|
+
flags: ['-m', '--model'],
|
|
44
|
+
args: (m) => ['exec', '--skip-git-repo-check', '-m', m, 'Reply with OK'],
|
|
45
|
+
},
|
|
46
|
+
},
|
|
40
47
|
// `-i, --image <FILE>...` takes several values (Codex 0.163.0 --help); AI Tasks pass `--image=<path>`, one value
|
|
41
48
|
// per flag, so the prompt after it stays a positional argument.
|
|
42
49
|
imageArg: '--image',
|
|
@@ -51,7 +51,10 @@ export const grokFamily = {
|
|
|
51
51
|
apiVars: ['GROK_MODELS_BASE_URL', 'XAI_API_KEY'],
|
|
52
52
|
secretVar: 'XAI_API_KEY',
|
|
53
53
|
// `-p` is one non-interactive prompt (Grok Build 1.0.60 --help, 2026-10-17).
|
|
54
|
-
probe: {
|
|
54
|
+
probe: {
|
|
55
|
+
args: ['-p', 'Reply with OK'],
|
|
56
|
+
model: { flags: ['-m', '--model'], args: (m) => ['--model', m, '-p', 'Reply with OK'] },
|
|
57
|
+
},
|
|
55
58
|
settingsFile: 'config.toml',
|
|
56
59
|
sharedItems: [
|
|
57
60
|
{ path: 'skills', mode: 'link' },
|
|
@@ -44,7 +44,10 @@ export const piFamily = {
|
|
|
44
44
|
// First key in the proxy.env template `new --api` writes. The OpenAI key is still set with `--var`.
|
|
45
45
|
secretVar: 'ANTHROPIC_API_KEY',
|
|
46
46
|
// `-p` is one non-interactive prompt (pi 1.3.0 --help, 2026-10-17).
|
|
47
|
-
probe: {
|
|
47
|
+
probe: {
|
|
48
|
+
args: ['-p', 'Reply with OK'],
|
|
49
|
+
model: { flags: ['--model'], args: (m) => ['--model', m, '-p', 'Reply with OK'] },
|
|
50
|
+
},
|
|
48
51
|
settingsFile: 'settings.json',
|
|
49
52
|
sharedItems: [
|
|
50
53
|
{ path: 'AGENTS.md', mode: 'link' },
|
|
@@ -1081,7 +1081,7 @@ export function createPanelHandler(opts) {
|
|
|
1081
1081
|
const account = optString(body, 'account');
|
|
1082
1082
|
if (!account)
|
|
1083
1083
|
throw new HttpError(400, '"account" is required');
|
|
1084
|
-
return tryAccount(await getRuntime(), account);
|
|
1084
|
+
return tryAccount(await getRuntime(), account, undefined, optString(body, 'model'));
|
|
1085
1085
|
},
|
|
1086
1086
|
},
|
|
1087
1087
|
// Themes (spec §3.34): `use` a Theme, `undo` the last switch, `accent` saves and uses the Theme File custom.json
|
package/dist/src/types.d.ts
CHANGED
|
@@ -189,9 +189,16 @@ export interface FamilyDef {
|
|
|
189
189
|
* Arguments for one short non-interactive check of an Account (`sideby try`, spec §3.28).
|
|
190
190
|
* sideby runs `bin` with these arguments and no others. Public contract, additive only:
|
|
191
191
|
* leaving it out means this tool cannot be tried.
|
|
192
|
+
* `model` lets `sideby try --model` choose the model: `flags` are the Host options that choose one (every
|
|
193
|
+
* earlier occurrence is taken out of the account's and short command's arguments) and `args(model)` replaces
|
|
194
|
+
* `args`. Leaving it out means `--model` is refused for this tool.
|
|
192
195
|
*/
|
|
193
196
|
probe?: {
|
|
194
197
|
args: string[];
|
|
198
|
+
model?: {
|
|
199
|
+
flags: string[];
|
|
200
|
+
args(model: string): string[];
|
|
201
|
+
};
|
|
195
202
|
};
|
|
196
203
|
/**
|
|
197
204
|
* The Host option that attaches an image to the first prompt, such as Codex's `--image` (spec §3.28 "附件").
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "sideby",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.25.0",
|
|
4
4
|
"description": "Run work, personal and API-key accounts at the same time, without their configs drifting apart.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Adonis0123 (https://github.com/Adonis0123)",
|
|
@@ -84,5 +84,5 @@
|
|
|
84
84
|
},
|
|
85
85
|
"packageManager": "pnpm@10.15.0",
|
|
86
86
|
"readmeFilename": "README.md",
|
|
87
|
-
"readme": "<p align=\"center\">\n <img alt=\"sideby: work, personal and API-key accounts, one terminal each, one shared config\" src=\"https://raw.githubusercontent.com/Adonis0123/sideby/main/docs/assets/banner.jpg\" width=\"880\">\n</p>\n\n<p align=\"center\">\n <b>Run work, personal and API-key accounts at the same time, without their configs drifting apart.</b><br>\n Each account is its own directory and its own terminal. Skills, hooks and settings stay linked to your main account. Claude Code, Codex, Grok Build and pi.\n</p>\n\n<p align=\"center\">\n <a href=\"https://www.npmjs.com/package/sideby\"><img alt=\"npm\" src=\"https://img.shields.io/npm/v/sideby\"></a>\n <a href=\"https://github.com/Adonis0123/sideby/actions/workflows/ci.yml\"><img alt=\"CI\" src=\"https://github.com/Adonis0123/sideby/actions/workflows/ci.yml/badge.svg\"></a>\n <img alt=\"Node 22.18+\" src=\"https://img.shields.io/badge/node-%E2%89%A522.18-339933\">\n <a href=\"LICENSE\"><img alt=\"MIT\" src=\"https://img.shields.io/badge/license-MIT-blue\"></a>\n</p>\n\n<p align=\"center\">English | <a href=\"README.zh-CN.md\">中文</a></p>\n\n## Quick start\n\nRequires Node 22.18+ and at least one Host CLI (Claude Code, Codex, Grok Build or pi) installed. AI agents: follow the setup steps in [`llms.txt`](llms.txt) (\"Set up sideby for a user\") instead.\n\n```sh\nnpm i -g sideby\nsideby new claude work # create ~/.claude-work, sharing ~/.claude's skills and hooks\nsideby login claude:work # sign in once\nsideby run work # Claude Code on the work account\nsideby quota setup claude --yes # Claude quota in the panel; undo: sideby quota teardown claude\nsideby ui --background # every account's quota at http://127.0.0.1:17420, still there after you close the terminal\n```\n\n`sideby app install` adds a Dock icon that opens the panel, and `sideby autostart on` has it ready each time you log in. `sideby update` installs a newer sideby when there is one; sideby says so after a command and in the panel. `sideby run claude:main` keeps using `~/.claude` in another terminal at the same time. Arguments after `--` go to the Host: `sideby run work -- --resume`. To try it without installing, run `npx sideby`.\n\n## Set up with your AI agent\n\nPaste this into Claude Code, Codex or any coding agent:\n\n```text\nInstall the sideby CLI (npm package `sideby`) and its agent skill, then set up a second Claude Code account for me.\nFollow \"Set up sideby for a user\" in https://raw.githubusercontent.com/Adonis0123/sideby/main/llms.txt\n```\n\nThe agent checks Node and your Host CLIs, installs sideby and the skill, creates the account, tells you what it shares with your main one and makes its short command work. You sign in once in your browser; the agent gives you that one command. Once the skill is installed, short requests work too: \"add another Claude account, cc008\", \"what do my Codex accounts share?\", \"which account still has quota?\".\n\n## What it looks like\n\nThe 25-second story: one account buried in tasks, then accounts side by side sharing one setup, and a task moving on when one runs out.\n\nhttps://github.com/user-attachments/assets/d1d7e8dd-1df1-4881-ac88-e468c2dd4a1d\n\n<img alt=\"Two terminals: the personal account and the work account running at the same time, both linked to the main account's skills and settings, then the local quota panel, and at 95% Auto Handoff moving work's session to the next account\" src=\"https://raw.githubusercontent.com/Adonis0123/sideby/main/docs/assets/demo.gif\" width=\"1280\">\n\n<picture>\n <source media=\"(prefers-color-scheme: dark)\" srcset=\"https://raw.githubusercontent.com/Adonis0123/sideby/main/docs/assets/panel-dark.png\">\n <source media=\"(prefers-color-scheme: light)\" srcset=\"https://raw.githubusercontent.com/Adonis0123/sideby/main/docs/assets/panel.png\">\n <img alt=\"sideby panel: every account's 5h and 7d quota, 7-day token usage and health in one page\" src=\"https://raw.githubusercontent.com/Adonis0123/sideby/main/docs/assets/panel.png\" width=\"1280\">\n</picture>\n\nOn macOS, the same quota sits in the menu bar (`sideby menubar on`): click or press `⌥X` to open it, and click an account to start it in the terminal.\n\n<picture>\n <source media=\"(prefers-color-scheme: dark)\" srcset=\"https://raw.githubusercontent.com/Adonis0123/sideby/main/docs/assets/menubar-dark.png\">\n <source media=\"(prefers-color-scheme: light)\" srcset=\"https://raw.githubusercontent.com/Adonis0123/sideby/main/docs/assets/menubar.png\">\n <img alt=\"sideby macOS menu bar dropdown: a status card, each tool with 5-hour and weekly quota bars, reset times, and the suggested account marked\" src=\"https://raw.githubusercontent.com/Adonis0123/sideby/main/docs/assets/menubar.png\" width=\"468\">\n</picture>\n\n## Why not just an alias?\n\n`CLAUDE_CONFIG_DIR` plus a shell alias already starts a second account. It does not keep skills and settings in one place, and it does not show quota for every account. [Does this break a provider's terms?](docs/guide/faq.md#terms)\n\n| | At the same time | Skills, hooks, settings | Quota and usage | Setup |\n|---|---|---|---|---|\n| `CLAUDE_CONFIG_DIR` and an alias | Yes. Each terminal exports the variable. | Each directory is its own copy. They drift unless you symlink by hand. | That session's status line | One alias per account |\n| [cc-switch](https://github.com/farion1231/cc-switch) | Enabling a provider writes the host's live config, so open sessions share that switch. | Plugin settings are copied across providers as a separate step. | The active provider, from its quota endpoint | Install the desktop app |\n| sideby | Yes. `sideby run` selects the directory for that process and leaves your shell alone. | Linked to the main account. `sideby doctor --fix` repairs copies. Sign-in and sessions stay separate. | Every account, from local files. Claude needs `quota setup`. | `npm i -g sideby`, then `sideby new` and sign in |\n\ncc-switch's docs describe that switch: it writes the live settings file ([README](https://github.com/farion1231/cc-switch#readme)). [#1105](https://github.com/farion1231/cc-switch/issues/1105) and [#2908](https://github.com/farion1231/cc-switch/issues/2908) ask for several sessions at once. [#1106](https://github.com/farion1231/cc-switch/issues/1106) is closed; the maintainer says Claude Code's \"open terminal\" can start one provider without changing the global config.\n\n## What else it does\n\n| You want to | Run | Guide |\n|---|---|---|\n| Find any past session of any account by what you remember, grouped by project, read it and continue it where it was | **Sessions › History** in the panel, or `sideby history \"fix login\" --project .` | [History](docs/guide/panel.md#history) |\n| See what every account is running right now and copy one session for another AI | **Sessions › Running** in the panel, or `sideby sessions` | [Sessions](docs/guide/panel.md#sessions) |\n| Send a running session a message, screenshots included | **Send to it** on a running session, or `sideby send claude:work \"run the tests\"` | [Send to a session](docs/guide/panel.md#send-to-a-session) |\n| Hand a task to your own AI from the panel: set up an account, fix a problem, support a new tool | **Let AI do it** in the panel, or `sideby ask` | [Let AI do it](docs/guide/panel.md#let-ai-do-it) |\n| See quota at a glance in the macOS menu bar | **Settings › Startup** in the panel, or `sideby menubar on` | [Quota in the menu bar](docs/guide/usage.md#quota-in-the-menu-bar) |\n| Have the panel ready in the background whenever you log in | **Settings › Startup** in the panel, or `sideby autostart on` | [Start at login](docs/guide/usage.md#start-at-login) |\n| Add an API key account (DeepSeek, a gateway, …) | `sideby new claude deepseek --api` | [API accounts](docs/guide/usage.md#api-accounts) |\n| Find and fix config drift between accounts | `sideby doctor --fix` | [Doctor](docs/guide/usage.md#doctor) |\n| See Claude quota (Codex needs no setup) | `sideby quota setup claude --yes` | [Claude quota](docs/guide/usage.md#claude-quota) |\n| Find the cheapest auto-compact size from your own sessions, and use it in one click | `sideby tune` (or the panel's Context tuning tab) | [Context tuning](docs/guide/usage.md#context-tuning) |\n| See each account's model and effort, and set them per account | `sideby model <account>` (or click the model in the panel) | [Model and effort](docs/guide/usage.md#model-and-effort) |\n| Choose whether Claude sessions connect to claude.ai by themselves (Remote Control), for every account at once | `sideby remote-control off` or `on` (or the panel's Settings) | [Remote Control](docs/guide/usage.md#remote-control) |\n| Pin the accounts you use most and put tools and accounts in your own order | `sideby pin claude:work`, `sideby order` (or the panel's Settings) | [Your own order](docs/guide/usage.md#your-own-order) |\n| Move on when an account hits its limit | `sideby next claude` | [Handoff](docs/guide/usage.md#when-an-account-hits-its-limit) |\n| Let a running task move to the next account by itself when quota runs low (off by default; see the risk) | `sideby handoff enable` (or the panel) | [Auto Handoff](docs/guide/usage.md#auto-handoff) |\n| Short commands such as `ccw` | `sideby alias add ccw claude:work` | [Shell functions](docs/guide/configuration.md#shell-functions) |\n| Reopen a session from Orca and the like in the account that holds it | `\"resumeRouting\": true` in config | [Resuming from other tools](docs/guide/configuration.md#resuming-from-other-tools) |\n| Open Claude Desktop or the Codex app as one account, several side by side (macOS) | `sideby desktop claude:work` (or the panel) | [Desktop apps](docs/guide/usage.md#desktop-apps) |\n| Keep several Grok Bot windows open, each signed in to its own account (macOS) | `sideby desktop grok-bot:002` (or the panel) | [Grok Bot windows](docs/guide/usage.md#grok-bot-windows) |\n| Open the panel from the Dock or app menu | `sideby app install` | [Panel app](docs/guide/panel.md#panel-app) |\n| Show the panel inside your own local page | `createPanelHandler()` | [Embed the panel](docs/guide/panel.md#embed-the-panel) |\n| Add a Host, a pre-launch check, or your own project categories for History | a local plugin | [Plugins](docs/guide/plugins.md) |\n\n## Supported hosts\n\n| Host | Account directories | Sign-in | Quota | Usage (7 days) |\n|---|---|---|---|---|\n| Claude Code | `~/.claude`, `~/.claude-<name>` | `claude auth login` | ✓ after `quota setup claude` | ✓ |\n| Codex CLI | `~/.codex`, `~/.codex-<name>` | `codex login` | ✓ | ✓ |\n| Grok Build | `~/.grok`, `~/.grok-<name>` | `grok login` | weekly, asked from the `grok` CLI | no public source |\n| pi | `~/.pi/agent`, `~/.pi-<name>/agent` | `/login` inside pi | no public source | no public source |\n| Antigravity CLI | `~/.gemini/antigravity-cli` (main account only) | sign in with Google inside `agy` | 5-hour and weekly per model group, asked from the `agy` CLI | no public source |\n\nsideby starts the official binary on your `PATH` and never patches it. Tested versions and per-Host notes are in the [guide](docs/guide/usage.md#host-notes).\n\n## Platforms\n\nmacOS and Linux. CI runs the suite on `ubuntu-latest` and `macos-latest`, Node 22 and 24. **Windows is untested.** `sideby app` only installs a launcher on macOS and Linux. Linked items are symlinks, `sideby shell-init` prints bash and zsh functions, and the Claude quota wrapper runs `/bin/sh`.\n\n## Roadmap\n\n**Gemini CLI.** Gemini can point at another config directory with `GEMINI_CONFIG_DIR`. Older docs use `GEMINI_CLI_HOME`; current builds treat that name as deprecated, and exit on startup if it is set together with an exact directory override. A sideby family still needs a tested Gemini version, a login check that does not read tokens, and a list of which files to link or copy. That is more than a small patch, so it is not in this version.\n\n## Safe by design\n\n- It never edits a Host's global config to switch accounts. It moves a task to another account only when you turn on Auto Handoff, and never proxies requests or pools logins.\n- It never reads, prints or sends a credential value. Nothing about your accounts leaves your machine: the only request sideby makes on its own is a daily check of the npm registry for its newest version (off with `NO_UPDATE_NOTIFIER=1`; see [Updates](docs/guide/configuration.md#updates)).\n- `doctor --fix` never replaces a real file and never changes where a link points.\n- The panel answers only on `127.0.0.1` and refuses web pages from other sites, but it trusts every user of this computer. On a shared Mac, do not leave it running in the background ([details](docs/guide/panel.md#who-can-reach-the-panel)).\n\nDetails and the terms-of-service question are in the [FAQ](docs/guide/faq.md).\n\nUsage questions and ideas go in [Discussions](https://github.com/Adonis0123/sideby/discussions).\n\n## Docs\n\n- [Using sideby](docs/guide/usage.md): accounts, API accounts, Doctor, quota, Handoff, Host notes\n- [Commands](docs/guide/commands.md): every command, exit codes and `--json`\n- [Configuration](docs/guide/configuration.md): `config.json`, aliases, shell functions\n- [Panel](docs/guide/panel.md): the panel, sessions and their history, panel app and embedding\n- [Plugins](docs/guide/plugins.md): write your own Family, launch hook or project categories\n- [FAQ](docs/guide/faq.md): terms of service, data locations, alternatives, uninstall\n- [Changelog](https://github.com/Adonis0123/sideby/releases)\n\n## For AI agents\n\n- [`llms.txt`](llms.txt): setup steps, commands, JSON contract and plugin API in one index. `sideby families --json` states what each Host's accounts share.\n- [`skills/sideby/SKILL.md`](skills/sideby/SKILL.md): one Agent Skill for seeing, repairing and creating accounts and for moving on when one hits its limit. Install with `npx skills add Adonis0123/sideby -g`; `sideby doctor` warns when the installed copy is for another sideby version.\n- [`AGENTS.md`](AGENTS.md): rules for agents working on this repository.\n\n## License\n\n[MIT](LICENSE)\n"
|
|
87
|
+
"readme": "<p align=\"center\">\n <img alt=\"sideby: work, personal and API-key accounts, one terminal each, one shared config\" src=\"https://raw.githubusercontent.com/Adonis0123/sideby/main/docs/assets/banner.jpg\" width=\"880\">\n</p>\n\n<p align=\"center\">\n <b>Run work, personal and API-key accounts at the same time, without their configs drifting apart.</b><br>\n Each account is its own directory and its own terminal. Skills, hooks and settings stay linked to your main account. Claude Code, Codex, Grok Build and pi.\n</p>\n\n<p align=\"center\">\n <a href=\"https://www.npmjs.com/package/sideby\"><img alt=\"npm\" src=\"https://img.shields.io/npm/v/sideby\"></a>\n <a href=\"https://github.com/Adonis0123/sideby/actions/workflows/ci.yml\"><img alt=\"CI\" src=\"https://github.com/Adonis0123/sideby/actions/workflows/ci.yml/badge.svg\"></a>\n <img alt=\"Node 22.18+\" src=\"https://img.shields.io/badge/node-%E2%89%A522.18-339933\">\n <a href=\"LICENSE\"><img alt=\"MIT\" src=\"https://img.shields.io/badge/license-MIT-blue\"></a>\n</p>\n\n<p align=\"center\">English | <a href=\"README.zh-CN.md\">中文</a></p>\n\n## Quick start\n\nRequires Node 22.18+ and at least one Host CLI (Claude Code, Codex, Grok Build or pi) installed. AI agents: follow the setup steps in [`llms.txt`](llms.txt) (\"Set up sideby for a user\") instead.\n\n```sh\nnpm i -g sideby\nsideby new claude work # create ~/.claude-work, sharing ~/.claude's skills and hooks\nsideby login claude:work # sign in once\nsideby run work # Claude Code on the work account\nsideby quota setup claude --yes # Claude quota in the panel; undo: sideby quota teardown claude\nsideby ui --background # every account's quota at http://127.0.0.1:17420, still there after you close the terminal\n```\n\n`sideby app install` adds a Dock icon that opens the panel, and `sideby autostart on` has it ready each time you log in. `sideby update` installs a newer sideby when there is one; sideby says so after a command and in the panel. `sideby run claude:main` keeps using `~/.claude` in another terminal at the same time. Arguments after `--` go to the Host: `sideby run work -- --resume`. To try it without installing, run `npx sideby`.\n\n## Set up with your AI agent\n\nPaste this into Claude Code, Codex or any coding agent:\n\n```text\nInstall the sideby CLI (npm package `sideby`) and its agent skill, then set up a second Claude Code account for me.\nFollow \"Set up sideby for a user\" in https://raw.githubusercontent.com/Adonis0123/sideby/main/llms.txt\n```\n\nThe agent checks Node and your Host CLIs, installs sideby and the skill, creates the account, tells you what it shares with your main one and makes its short command work. You sign in once in your browser; the agent gives you that one command. Once the skill is installed, short requests work too: \"add another Claude account, cc008\", \"what do my Codex accounts share?\", \"which account still has quota?\".\n\n## What it looks like\n\nThe 25-second story: one account buried in tasks, then accounts side by side sharing one setup, and a task moving on when one runs out.\n\nhttps://github.com/user-attachments/assets/d1d7e8dd-1df1-4881-ac88-e468c2dd4a1d\n\n<img alt=\"Two terminals: the personal account and the work account running at the same time, both linked to the main account's skills and settings, then the local quota panel, and at 95% Auto Handoff moving work's session to the next account\" src=\"https://raw.githubusercontent.com/Adonis0123/sideby/main/docs/assets/demo.gif\" width=\"1280\">\n\n<picture>\n <source media=\"(prefers-color-scheme: dark)\" srcset=\"https://raw.githubusercontent.com/Adonis0123/sideby/main/docs/assets/panel-dark.png\">\n <source media=\"(prefers-color-scheme: light)\" srcset=\"https://raw.githubusercontent.com/Adonis0123/sideby/main/docs/assets/panel.png\">\n <img alt=\"sideby panel: every account's 5h and 7d quota, 7-day token usage and health in one page\" src=\"https://raw.githubusercontent.com/Adonis0123/sideby/main/docs/assets/panel.png\" width=\"1280\">\n</picture>\n\nOn macOS, the same quota sits in the menu bar (`sideby menubar on`): click or press `⌥X` to open it, and click an account to start it in the terminal.\n\n<picture>\n <source media=\"(prefers-color-scheme: dark)\" srcset=\"https://raw.githubusercontent.com/Adonis0123/sideby/main/docs/assets/menubar-dark.png\">\n <source media=\"(prefers-color-scheme: light)\" srcset=\"https://raw.githubusercontent.com/Adonis0123/sideby/main/docs/assets/menubar.png\">\n <img alt=\"sideby macOS menu bar dropdown: a status card, each tool with 5-hour and weekly quota bars, reset times, and the suggested account marked\" src=\"https://raw.githubusercontent.com/Adonis0123/sideby/main/docs/assets/menubar.png\" width=\"468\">\n</picture>\n\n## Why not just an alias?\n\n`CLAUDE_CONFIG_DIR` plus a shell alias already starts a second account. It does not keep skills and settings in one place, and it does not show quota for every account. [Does this break a provider's terms?](docs/guide/faq.md#terms)\n\n| | At the same time | Skills, hooks, settings | Quota and usage | Setup |\n|---|---|---|---|---|\n| `CLAUDE_CONFIG_DIR` and an alias | Yes. Each terminal exports the variable. | Each directory is its own copy. They drift unless you symlink by hand. | That session's status line | One alias per account |\n| [cc-switch](https://github.com/farion1231/cc-switch) | Enabling a provider writes the host's live config, so open sessions share that switch. | Plugin settings are copied across providers as a separate step. | The active provider, from its quota endpoint | Install the desktop app |\n| sideby | Yes. `sideby run` selects the directory for that process and leaves your shell alone. | Linked to the main account. `sideby doctor --fix` repairs copies. Sign-in and sessions stay separate. | Every account, from local files. Claude needs `quota setup`. | `npm i -g sideby`, then `sideby new` and sign in |\n\ncc-switch's docs describe that switch: it writes the live settings file ([README](https://github.com/farion1231/cc-switch#readme)). [#1105](https://github.com/farion1231/cc-switch/issues/1105) and [#2908](https://github.com/farion1231/cc-switch/issues/2908) ask for several sessions at once. [#1106](https://github.com/farion1231/cc-switch/issues/1106) is closed; the maintainer says Claude Code's \"open terminal\" can start one provider without changing the global config.\n\n## What else it does\n\n| You want to | Run | Guide |\n|---|---|---|\n| Find any past session of any account by what you remember, grouped by project, read it and continue it where it was | **Sessions › History** in the panel, or `sideby history \"fix login\" --project .` | [History](docs/guide/panel.md#history) |\n| See what every account is running right now and copy one session for another AI | **Sessions › Running** in the panel, or `sideby sessions` | [Sessions](docs/guide/panel.md#sessions) |\n| Send a running session a message, screenshots included | **Send to it** on a running session, or `sideby send claude:work \"run the tests\"` | [Send to a session](docs/guide/panel.md#send-to-a-session) |\n| Hand a task to your own AI from the panel: set up an account, fix a problem, support a new tool | **Let AI do it** in the panel, or `sideby ask` | [Let AI do it](docs/guide/panel.md#let-ai-do-it) |\n| See quota at a glance in the macOS menu bar | **Settings › Startup** in the panel, or `sideby menubar on` | [Quota in the menu bar](docs/guide/usage.md#quota-in-the-menu-bar) |\n| Have the panel ready in the background whenever you log in | **Settings › Startup** in the panel, or `sideby autostart on` | [Start at login](docs/guide/usage.md#start-at-login) |\n| Add an API key account (DeepSeek, a gateway, …) | `sideby new claude deepseek --api` | [API accounts](docs/guide/usage.md#api-accounts) |\n| Find and fix config drift between accounts | `sideby doctor --fix` | [Doctor](docs/guide/usage.md#doctor) |\n| See Claude quota (Codex needs no setup) | `sideby quota setup claude --yes` | [Claude quota](docs/guide/usage.md#claude-quota) |\n| Find the cheapest auto-compact size from your own sessions, and use it in one click | `sideby tune` (or the panel's Context tuning tab) | [Context tuning](docs/guide/usage.md#context-tuning) |\n| See each account's model and effort, and set them per account | `sideby model <account>` (or click the model in the panel) | [Model and effort](docs/guide/usage.md#model-and-effort) |\n| Choose whether Claude sessions connect to claude.ai by themselves (Remote Control), for every account at once | `sideby remote-control off` or `on` (or the panel's Settings) | [Remote Control](docs/guide/usage.md#remote-control) |\n| Pin the accounts you use most, put tools and accounts in your own order, and hide the ones you never use | `sideby pin claude:work`, `sideby order`, `sideby hide grok` (or the panel's Settings) | [Your own order](docs/guide/usage.md#your-own-order) |\n| Give the panel other colors: five built-in Themes, your own color, or one your AI writes | **Settings › Theme** in the panel, or `sideby theme use leaf` | [Themes](docs/guide/panel.md#themes) |\n| Move on when an account hits its limit | `sideby next claude` | [Handoff](docs/guide/usage.md#when-an-account-hits-its-limit) |\n| Let a running task move to the next account by itself when quota runs low (off by default; see the risk) | `sideby handoff enable` (or the panel) | [Auto Handoff](docs/guide/usage.md#auto-handoff) |\n| Short commands such as `ccw` | `sideby alias add ccw claude:work` | [Shell functions](docs/guide/configuration.md#shell-functions) |\n| Reopen a session from Orca and the like in the account that holds it | `\"resumeRouting\": true` in config | [Resuming from other tools](docs/guide/configuration.md#resuming-from-other-tools) |\n| Open Claude Desktop or the Codex app as one account, several side by side (macOS) | `sideby desktop claude:work` (or the panel) | [Desktop apps](docs/guide/usage.md#desktop-apps) |\n| Keep several Grok Bot windows open, each signed in to its own account (macOS) | `sideby desktop grok-bot:002` (or the panel) | [Grok Bot windows](docs/guide/usage.md#grok-bot-windows) |\n| Open the panel from the Dock or app menu | `sideby app install` | [Panel app](docs/guide/panel.md#panel-app) |\n| Show the panel inside your own local page | `createPanelHandler()` | [Embed the panel](docs/guide/panel.md#embed-the-panel) |\n| Add a Host, a pre-launch check, or your own project categories for History | a local plugin | [Plugins](docs/guide/plugins.md) |\n\n## Supported hosts\n\n| Host | Account directories | Sign-in | Quota | Usage (7 days) |\n|---|---|---|---|---|\n| Claude Code | `~/.claude`, `~/.claude-<name>` | `claude auth login` | ✓ after `quota setup claude` | ✓ |\n| Codex CLI | `~/.codex`, `~/.codex-<name>` | `codex login` | ✓ | ✓ |\n| Grok Build | `~/.grok`, `~/.grok-<name>` | `grok login` | weekly, asked from the `grok` CLI | no public source |\n| pi | `~/.pi/agent`, `~/.pi-<name>/agent` | `/login` inside pi | no public source | no public source |\n| Antigravity CLI | `~/.gemini/antigravity-cli` (main account only) | sign in with Google inside `agy` | 5-hour and weekly per model group, asked from the `agy` CLI | no public source |\n\nsideby starts the official binary on your `PATH` and never patches it. Tested versions and per-Host notes are in the [guide](docs/guide/usage.md#host-notes).\n\n## Platforms\n\nmacOS and Linux. CI runs the suite on `ubuntu-latest` and `macos-latest`, Node 22 and 24. **Windows is untested.** `sideby app` only installs a launcher on macOS and Linux. Linked items are symlinks, `sideby shell-init` prints bash and zsh functions, and the Claude quota wrapper runs `/bin/sh`.\n\n## Roadmap\n\n**Gemini CLI.** Gemini can point at another config directory with `GEMINI_CONFIG_DIR`. Older docs use `GEMINI_CLI_HOME`; current builds treat that name as deprecated, and exit on startup if it is set together with an exact directory override. A sideby family still needs a tested Gemini version, a login check that does not read tokens, and a list of which files to link or copy. That is more than a small patch, so it is not in this version.\n\n## Safe by design\n\n- It never edits a Host's global config to switch accounts. It moves a task to another account only when you turn on Auto Handoff, and never proxies requests or pools logins.\n- It never reads, prints or sends a credential value. Nothing about your accounts leaves your machine: the only request sideby makes on its own is a daily check of the npm registry for its newest version (off with `NO_UPDATE_NOTIFIER=1`; see [Updates](docs/guide/configuration.md#updates)).\n- `doctor --fix` never replaces a real file and never changes where a link points.\n- The panel answers only on `127.0.0.1` and refuses web pages from other sites, but it trusts every user of this computer. On a shared Mac, do not leave it running in the background ([details](docs/guide/panel.md#who-can-reach-the-panel)).\n\nDetails and the terms-of-service question are in the [FAQ](docs/guide/faq.md).\n\nUsage questions and ideas go in [Discussions](https://github.com/Adonis0123/sideby/discussions).\n\n## Docs\n\n- [Using sideby](docs/guide/usage.md): accounts, API accounts, Doctor, quota, Handoff, Host notes\n- [Commands](docs/guide/commands.md): every command, exit codes and `--json`\n- [Configuration](docs/guide/configuration.md): `config.json`, aliases, shell functions\n- [Panel](docs/guide/panel.md): the panel, sessions and their history, panel app and embedding\n- [Plugins](docs/guide/plugins.md): write your own Family, launch hook or project categories\n- [FAQ](docs/guide/faq.md): terms of service, data locations, alternatives, uninstall\n- [Changelog](https://github.com/Adonis0123/sideby/releases)\n\n## For AI agents\n\n- [`llms.txt`](llms.txt): setup steps, commands, JSON contract and plugin API in one index. `sideby families --json` states what each Host's accounts share.\n- [`skills/sideby/SKILL.md`](skills/sideby/SKILL.md): one Agent Skill for seeing, repairing and creating accounts and for moving on when one hits its limit. Install with `npx skills add Adonis0123/sideby -g`; `sideby doctor` warns when the installed copy is for another sideby version.\n- [`AGENTS.md`](AGENTS.md): rules for agents working on this repository.\n\n## License\n\n[MIT](LICENSE)\n"
|
|
88
88
|
}
|
package/schemas/try.json
CHANGED
package/skills/sideby/SKILL.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
name: sideby
|
|
3
3
|
description: Use when the user runs, or wants to run, several AI coding accounts (Claude Code, Codex, Grok Build, pi) side by side. Covers installing sideby and setting up a new account ("install sideby", "set up another Claude account", "add cc008", "配置一个 cc00x", "再加一个 Codex 账号"), explaining what accounts share and what stays separate ("what do my accounts share?", "这些账号共享了什么"), showing which account a session is ("show [cc001] in the status line", "加上账号标识"), finding a past session of any account ("找一下我上周改登录页的那个会话"), seeing accounts, quota and usage, moving on when one hits its 5-hour or weekly limit, moving the current task to another account ("用 cc008 继续", "交回 cc008"), adding a short command (alias) or a pick command that starts whichever account has the most quota ("加个 cc"), adding an API account from a vendor's docs ("加一个 DeepSeek API 账号"), supporting a new tool, and repairing drifted account directories (skills, hooks, rules or settings not shared, wrong symlinks, credential file permissions). Drives the `sideby` CLI with `--json`; the agent does every step except browser sign-in, filling in secrets and starting interactive sessions, which it hands to the user as one command (inside an Auto Handoff session, `sideby handoff ready --to` moves the task itself).
|
|
4
4
|
metadata:
|
|
5
|
-
version: "0.
|
|
5
|
+
version: "0.25.0"
|
|
6
6
|
requires:
|
|
7
7
|
bins: [sideby, node]
|
|
8
8
|
cliHelp: sideby --help
|
|
@@ -66,7 +66,7 @@ Account refs are `<family>:<name>`; a bare `<name>` works only when it is unique
|
|
|
66
66
|
| Short commands say "command not found" in a new terminal ("cc 用不了", "短命令不生效") | `sideby shell-init setup --json` (exit 10 first) | `references/setup.md` |
|
|
67
67
|
| Do something in sideby as an AI Task (the first message came from sideby or the Panel's "Let AI do it") | follow the task it names | `references/ai-tasks.md` |
|
|
68
68
|
| A Portal starts AI Tasks through sideby, or one of its tasks failed (`spec-version`, `bad-cwd`, "which account would it use?") | `sideby ask --choices --json`, `sideby ask --spec - --print --json` (read only) | `references/ai-tasks.md` |
|
|
69
|
-
| Add an API account from a vendor's address or docs link, enter its key, check it works | `sideby new <family> --next --api --json`, then the user runs `sideby key <ref>`; `sideby try <ref> --json` (exit 10 first) | `references/ai-tasks.md` |
|
|
69
|
+
| Add an API account from a vendor's address or docs link, enter its key, check it works (also with a given model: "用 glm-5.3 试一下 pi") | `sideby new <family> --next --api --json`, then the user runs `sideby key <ref>`; `sideby try <ref|short command> [--model <m>] --json` (exit 10 first) | `references/ai-tasks.md` |
|
|
70
70
|
| Support a tool sideby does not list yet, or write a plugin | `sideby plugins new <id> --json`, `sideby plugins check <id> --json` | `references/ai-tasks.md` |
|
|
71
71
|
| Choose the terminal the Panel opens for AI Tasks and sign-in | `sideby terminal --json`, `sideby terminal --set <id> --json` | — |
|
|
72
72
|
| Tune the auto-compact threshold ("which compaction setting costs the fewest tokens"), use the suggestion or undo it | `sideby tune --json`, `sideby tune apply` (exit 10 first), `sideby tune undo` | `references/diagnose.md` |
|
|
@@ -61,6 +61,7 @@ sideby ships no list of vendors, addresses or model names. Take every fact from
|
|
|
61
61
|
3. Set every variable except the key: show the user the lines you will add to `proxy.env` and add them after they agree. Do not read the file's other lines, and never write a key into it.
|
|
62
62
|
4. Tell the user to run `sideby key <ref>` in their own terminal (or click **Enter key** in the Panel). Add `--var <NAME>` when the key belongs in a variable other than the Family's default. Wait until they say it is done.
|
|
63
63
|
5. Offer `sideby try <ref> --json`: it exits 10 and says which command it runs and that it costs a few tokens. After they agree, run it with `--yes`. Exit 0 means the Host answered. On 1, read the Host's message it shows and check the mistakes below.
|
|
64
|
+
- To check one model, add `--model <model>` (for pi `provider/id`, optionally `:<thinking>`). It replaces the model the account's settings choose, this once, and writes nothing. To check a short command the user made (such as one with its own model), pass the short command instead of the ref: its arguments apply as in `sideby run`. Do not run the Host by hand to test a model.
|
|
64
65
|
|
|
65
66
|
Common mistakes:
|
|
66
67
|
|