Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions .claude-plugin/marketplace.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,43 +5,43 @@
},
"metadata": {
"description": "Choose the model providers to use inside Claude Code.",
"version": "0.4.1"
"version": "0.4.2"
},
"plugins": [
{
"name": "multi-core",
"source": "./",
"version": "0.4.1",
"version": "0.4.2",
"description": "Shared Multi gateway, setup, status and reversible Claude startup integration."
},
{
"name": "multi-openai",
"source": "./plugins/multi-openai",
"version": "0.4.1",
"version": "0.4.2",
"description": "ChatGPT models through Codex login"
},
{
"name": "multi-cursor",
"source": "./plugins/multi-cursor",
"version": "0.4.1",
"version": "0.4.2",
"description": "Official Cursor SDK coding harness"
},
{
"name": "multi-zen",
"source": "./plugins/multi-zen",
"version": "0.4.1",
"version": "0.4.2",
"description": "OpenCode Zen direct API models"
},
{
"name": "multi-antigravity",
"source": "./plugins/multi-antigravity",
"version": "0.4.1",
"version": "0.4.2",
"description": "Official Antigravity CLI harness"
},
{
"name": "multi-grok",
"source": "./plugins/multi-grok",
"version": "0.4.1",
"version": "0.4.2",
"description": "Official Grok Build CLI harness"
}
]
Expand Down
2 changes: 1 addition & 1 deletion .claude-plugin/plugin.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "0.4.1",
"version": "0.4.2",
"author": {
"name": "greenpolo",
"url": "https://github.com/greenpolo"
Expand Down
24 changes: 24 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,30 @@ Entries record changes when they were made, including superseded decisions.
See [ARCHITECTURE.md](ARCHITECTURE.md) for current direction and
[README.md](README.md) for current capabilities.

## 0.4.2 — 2026-11-26

Workers get Claude's whole toolset, and arbitrary limits on agents are removed.

- **Workers get Claude's whole toolset.** Every provider worker was registered with a
fixed list of six tools (Read, Grep, Glob, Bash, Edit, Write), so GPT and Gemini
workers had no MCP, web search, web fetch or skills. Workers now list no tools and
inherit the session's, as a Claude subagent does.
- **Arbitrary limits removed across providers.** Cursor now loads your Cursor setup
(MCP servers, rules, hooks, plugins) and keeps its subagents and web tools. Grok runs
with its full toolset when no Claude rule applies. The Antigravity and Grok prompts
no longer forbid subagents, and Antigravity no longer refuses custom provider settings.
An effort or output size a model does not offer now runs at the nearest supported
value instead of failing, an image or document no longer fails a CLI worker, content
OpenAI cannot represent is passed as text, and Plan without a reviewer allows web
lookups as Claude's Plan does. Hidden agent types, run, concurrency, compaction and
usage-query caps, the 256-rule cut-off, the agent-definition size and count limits,
the slow-gateway worker denial and two limiting lines in the OpenAI instructions are
gone. agy's config-folder write guard applies only while a Claude rule is in force. agy
no longer runs with `--disable-slash-commands`, which also switched off its own `--mode plan`.
- **A busy CLI worker queues instead of refusing.** A new prompt sent to a Cursor, Antigravity
or Grok worker mid-turn used to fail with "already running"; it now waits for the turn
and then runs.

## 0.4.1 — 2026-11-26

External CLIs keep their own MCP servers and agents, and Claude's rules reach Gemini on Windows.
Expand Down
5 changes: 3 additions & 2 deletions docs/antigravity.md
Original file line number Diff line number Diff line change
Expand Up @@ -130,8 +130,9 @@ continuing. Non-success terminal results are reported as errors and are retried
by a later identical request.

One turn runs at a time per worker and workspace. A different prompt sent while
a turn is running is refused rather than queued, so a paid turn never runs twice;
send it again once the answer lands.
a turn is running waits for it and then runs. A resent copy of the running request
(Claude Code retrying after a dropped connection) reattaches to the running turn
instead of starting the same native actions again.

## Config and hook paths per OS

Expand Down
10 changes: 6 additions & 4 deletions docs/cursor.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,9 @@ exit code, file content, diff), in the `/model` Cursor session or inside the Cur
worker's transcript. The transcript also keeps streamed text, context-compaction
notices, and one closing summary of action counts, changed files, and failed or
denied actions. External actions are displayed and never replayed as executable
Claude tools. Cursor task, child-agent, and MCP
capabilities are disabled.
Claude tools. Cursor loads your own Cursor setup (its MCP servers, rules, hooks and
plugins) and keeps its subagents; Claude's deny rules remove the matching Cursor
tools, and Plan removes shell, edits, subagents, MCP and image generation.

Claude and OpenAI parents can spawn Cursor workers. Each worker has its own
SDK state. Worktree workers use their canonical workspace for SDK execution and
Expand Down Expand Up @@ -85,8 +86,9 @@ should continue and move the other out of the state directory. At most 32 SDK ag
released and resumed later from disk.

One turn runs at a time per worker and workspace. A different prompt sent while
a turn is running is refused rather than queued, so a paid turn never runs twice;
send it again once the answer lands.
a turn is running waits for it and then runs. A resent copy of the running request
(Claude Code retrying after a dropped connection) reattaches to the running turn
instead of starting the same native actions again.

## Compaction

Expand Down
9 changes: 6 additions & 3 deletions docs/grok.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,9 @@ installed.
| Bypass | `--permission-mode bypassPermissions`, explicit restrictions retained |
| Default, dontAsk | `--permission-mode auto`, with a one-line notice |

Restrictions are expressed three times on purpose. The native toolset is bounded
With no Claude rule and outside Plan, the run passes no `--tools`, so Grok keeps every
tool it has, including ones a newer build adds. When a rule applies, restrictions are
expressed three times on purpose. The native toolset is bounded
with `--tools`, every ungranted tool is *also* removed by name, because the CLI
adds its own planning, feedback and media tools to an allowlist, and execution is gated with `--deny` rules whose syntax matches Claude
Code's own (`Bash(git:*)`, `Write(path)`, `MCPTool(*)`). Deny rules outrank every
Expand Down Expand Up @@ -122,8 +124,9 @@ last assistant response, and outer history changes produce a notice and continue
on the native record. Native state is never rewound.

One turn runs at a time per worker and workspace. A different prompt sent while
a turn is running is refused rather than queued, so a paid turn never runs twice;
send it again once the answer lands.
a turn is running waits for it and then runs. A resent copy of the running request
(Claude Code retrying after a dropped connection) reattaches to the running turn
instead of starting the same native actions again.

A completed identical request replays its saved output. A run that ends without
a terminal event is never assumed complete: the next request resumes with an
Expand Down
7 changes: 4 additions & 3 deletions docs/permissions.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,9 @@ into it, and never hard-blocks the CLI's own. Those tools follow Claude's mode:

An explicit tool list (an agent type's `tools`, or `--tools`) admits only the tools it
names, `mcp__` entries included. Antigravity matches each MCP call by server and tool;
Grok's rule is coarse, so any MCP deny rule there turns off all of its MCP. Cursor
runs still load no Cursor MCP servers or settings.
Grok's and Cursor's rules are coarse, so any MCP deny rule there turns off all of their
MCP. Provider workers list no tools of their own, so they inherit the session's whole
toolset, as a Claude subagent does.

## Settings a native harness cannot enforce

Expand All @@ -57,7 +58,7 @@ restricts nothing there and is ignored.

| Provider or action | What enforces the permission |
| --- | --- |
| OpenAI direct models | Claude Code's Read, Grep, Glob, Bash, Edit, and Write tools run the tool loop. The originating OpenAI account reviews tool uses inline before the reply completes. Read-only tools on the core skip list need no review. Reviewer failure or timeout refuses the action; discovery failure at launch leaves Auto unreviewed, with that statement in the status line. |
| OpenAI direct models | Claude Code's own tools run the tool loop, the same set a Claude subagent gets: built-ins, MCP servers, web search and fetch, skills. The originating OpenAI account reviews tool uses inline before the reply completes. Read-only tools on the core skip list need no review. Reviewer failure or timeout refuses the action; discovery failure at launch leaves Auto unreviewed, with that statement in the status line. |
| Zen direct models | Claude Code runs and authorizes the tools. Zen auto mode is unreviewed like bypass; plan mode refuses actions that need review. Zen has no independent reviewer and never uses the OpenAI reviewer. |
| Cursor native harness | Native review belongs to the originating Cursor account and run. Cursor receives the prompt-boundary mode and capability restrictions. See [docs/cursor.md](cursor.md). |
| Antigravity native harness | A namespaced global pre-tool hook enforces Claude's denials while the native CLI runs. See [docs/antigravity.md](antigravity.md). |
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "cc-multi-cli-plugin",
"version": "0.4.1",
"version": "0.4.2",
"private": true,
"type": "module",
"description": "Claude Code plugin providing a native model gateway that runs external models inside one Claude Code session.",
Expand Down
4 changes: 2 additions & 2 deletions plugins/multi-antigravity/.claude-plugin/plugin.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "0.4.1",
"version": "0.4.2",
"author": {
"name": "greenpolo",
"url": "https://github.com/greenpolo"
Expand All @@ -10,7 +10,7 @@
"dependencies": [
{
"name": "multi-core",
"version": "~0.4.1"
"version": "~0.4.2"
}
]
}
2 changes: 1 addition & 1 deletion plugins/multi-antigravity/src/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,6 @@ function antigravityArguments(options: AntigravityRunOptions, promptOnStdin: boo
const args = promptOnStdin
? ['--input-format', 'stream-json', '--output-format', 'stream-json']
: ['-p', options.prompt, '--output-format', 'stream-json'];
args.push('--disable-slash-commands');
if (options.model) {
args.push('--model', options.model);
}
Expand Down Expand Up @@ -352,6 +351,7 @@ export function antigravityEnvironment(overrides?: NodeJS.ProcessEnv): NodeJS.Pr
'OPENAI_',
'CURSOR_',
'OPENCODE_',
// An API key here would move agy from the account login to metered API billing.
'GEMINI_API_KEY',
'GOOGLE_GEMINI_BASE_URL',
'MULTI_GATEWAY_TOKEN',
Expand Down
7 changes: 0 additions & 7 deletions plugins/multi-antigravity/src/hooks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import os from 'node:os';
import path from 'node:path';
import { fileURLToPath } from 'node:url';
import { atomicWriteFile } from '../../multi-core/src/gateway/atomic-write.ts';
import { HarnessSetupError } from '../../multi-core/src/gateway/harness-failure.ts';
import { lockStateFile } from '../../multi-core/src/gateway/state-lock.ts';

const namespace = 'multi-cli-antigravity';
Expand Down Expand Up @@ -118,12 +117,6 @@ export async function ensureAntigravityHooks(
if (JSON.stringify(hooks[namespace]) !== JSON.stringify(antigravityHookDefinition(platform))) {
await installAntigravityHook(globalFile, options);
}
const settings = await readHooks(files.settingsFile ?? antigravitySettingsFile(options));
if (settings.modelProvider !== undefined || settings.customModels !== undefined) {
throw new HarnessSetupError(
'Antigravity requires native account authentication and models; custom provider settings are unsupported.',
);
}
}

export function hookCommand(file: URL, platform: NodeJS.Platform = process.platform): string {
Expand Down
14 changes: 5 additions & 9 deletions plugins/multi-antigravity/src/models.ts
Original file line number Diff line number Diff line change
Expand Up @@ -165,18 +165,14 @@ export function selectAntigravityModel(
if (effort === undefined || PINNED_EFFORT.test(selected.id)) {
return selected;
}
if (effort !== 'low' && effort !== 'medium' && effort !== 'high') {
throw new Error('Antigravity effort must be an advertised low, medium or high variant.');
}
// agy's levels top out at high, so Claude's xhigh and max run as high.
const level = effort === 'low' || effort === 'medium' ? effort : 'high';
const base = selected.id.replace(/-(low|medium|high)$/, '');
if (base === selected.id) {
return { ...selected, effort };
}
const variant = models.find((option) => option.id === `${base}-${effort}`);
if (!variant) {
throw new Error(`Antigravity model ${selected.id} does not advertise ${effort} effort.`);
return { ...selected, effort: level };
}
return variant;
// A model without that variant runs at its default rather than failing.
return models.find((option) => option.id === `${base}-${level}`) ?? selected;
}

/**
Expand Down
5 changes: 5 additions & 0 deletions plugins/multi-antigravity/src/permissions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -356,6 +356,11 @@ export function antigravityToolDecision(
reason: 'Claude session policy excludes this native Antigravity tool.',
};
}
// The guard keeps a run from rewriting the hook that enforces the user's own rules, so
// it applies only while such a rule is in force; with none, agy may write anywhere.
if (!denied.length && allowed === undefined) {
return undefined;
}
const protectedRoots = options.protectedRoots ?? antigravityProtectedRoots();
// agy runs the hook from its config folder; relative paths belong to the workspace.
const target = { protectedRoots, cwd: hookCwd(input) };
Expand Down
3 changes: 1 addition & 2 deletions plugins/multi-antigravity/src/request.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@ import type { MessagesRequest } from '../../multi-core/src/gateway/messages.ts';
const PREAMBLE =
'You are the Antigravity coding agent displayed inside Claude Code. Complete the task ' +
'using your native tools and permissions, verify changes, and report results and any ' +
'denied actions. Previously recorded actions are complete; do not repeat them. Do not ' +
'spawn child agents or external coding CLIs.';
'denied actions. Previously recorded actions are complete; do not repeat them.';

/** Cache markers are transport metadata; moving them must not fork native history. */
export function antigravityHistoryHash(messages: MessagesRequest['messages']): string {
Expand Down
1 change: 0 additions & 1 deletion plugins/multi-core/hooks/desktop.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ export type Handshake = {
description: string;
prompt: string;
model: string;
tools: string[];
effort?: string;
}>;
frontDoor: boolean;
Expand Down
15 changes: 7 additions & 8 deletions plugins/multi-core/hooks/workers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -98,10 +98,8 @@ export const register = (on: Parameters<Register>[0], _options: Parameters<Regis
parentModel,
});
await classify($, event.agent, nativeClaude(response));
// Claude owns its own catalog. Only a positively identified harness worker
// is subject to Multi's settings-translation compatibility filter.
const hidden = response?.execution === 'harness' && response.isOffered === false;
const result = hidden ? { isOffered: false } : await next(event);
// Every agent type stays offered: an unknown one inherits the session's record.
const result = await next(event);
await markOffered($, event.agent, result.isOffered);
return result;
});
Expand Down Expand Up @@ -218,12 +216,13 @@ async function providerSpawn(
return { event, selection };
}
if (!selection) {
return {
deny: reportable(`The Multi gateway did not resolve the ${event.subagentType} model.`),
};
// A slow gateway never blocks a worker: it starts on its agent type's default model.
return { event, selection };
}
if (selection.refused || !selection.model) {
return { deny: selection.error ?? `The ${event.subagentType} model was not resolved.` };
return {
deny: reportable(selection.error ?? `The ${event.subagentType} model was not resolved.`),
};
}
// The task keeps the model's own description: the agent list names the CLI itself.
return { event: { ...event, model: selection.model }, selection };
Expand Down
13 changes: 1 addition & 12 deletions plugins/multi-core/src/gateway/agent-definitions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ export interface WorkerPermissions {
notice?: string;
}

const MAX_AGENT_FILES = 1000;
const MAX_AGENT_BYTES = 1024 * 1024;
const PERMISSION_MODES = new Set([
'default',
'acceptEdits',
Expand Down Expand Up @@ -116,18 +114,12 @@ async function agentFiles(directory: string): Promise<string[]> {
} else if (entry.isFile() && entry.name.endsWith('.md')) {
files.push(file);
}
if (files.length > MAX_AGENT_FILES) {
throw new Error(`Too many agent definitions under ${directory}`);
}
}
return files;
}

async function readDefinition(file: string): Promise<[string, WorkerPermissions]> {
const source = await readFile(file, 'utf8');
if (Buffer.byteLength(source) > MAX_AGENT_BYTES) {
throw new Error(`Agent definition ${file} exceeds ${MAX_AGENT_BYTES} bytes`);
}
const frontmatter = source.match(/^---\r?\n([\s\S]*?)\r?\n---(?:\r?\n|$)/);
if (!frontmatter) {
throw new Error(`Agent definition ${file} has no YAML frontmatter`);
Expand Down Expand Up @@ -208,7 +200,7 @@ export async function pluginPermissions(
childProcess.execFile(
invocation.command,
invocation.args,
{ cwd, timeout: 10000, maxBuffer: MAX_AGENT_BYTES, env: environment, ...invocation.options },
{ cwd, timeout: 10000, maxBuffer: 64 * 1024 * 1024, env: environment, ...invocation.options },
(error, output) => {
if (error) {
reject(error);
Expand Down Expand Up @@ -322,9 +314,6 @@ const reportedMalformed = new Set<string>();
*/
async function pluginDefinition(file: string): Promise<[string, WorkerPermissions]> {
const source = await readFile(file, 'utf8');
if (Buffer.byteLength(source) > MAX_AGENT_BYTES) {
throw new Error(`Agent definition ${file} exceeds size limit`);
}
const frontmatter = source.match(/^---\r?\n([\s\S]*?)\r?\n---(?:\r?\n|$)/);
const value = lenientFrontmatter(frontmatter?.[1] ?? '');
const name = typeof value?.name === 'string' ? value.name : path.basename(file, '.md');
Expand Down
Loading
Loading