docs(mcp): clarify DeepSeek catalog refresh compatibility (#13041)

* docs(mcp): describe the DeepSeek in-task refresh limit

* test(setup): preserve DeepSeek catalog profile choices
This commit is contained in:
Kaoru0822 authored and GitHub committed 2026-11-21 00:47:50 -08:00
1 parent 88d829bc0d
commit baad68f437
2 files changed
+86 -1

No files matched your search

+9 -1
View File
@@ -118,7 +118,7 @@ unfamiliar prefix. The unavailable fork reported in
## Hot/cold catalogs
For a client that supports MCP catalog refresh, set
For a client that can call newly listed tools during an active task, set
`REA_MCP_TOOL_CATALOG_PROFILE=hot-cold` in REA's server environment and restart
the connection. REA then advertises a small initial catalog and loads other
named tools through `discover_tools`. Setup can record the explicit choice:
@@ -1037,6 +1037,14 @@ in `~/.agents/skills` (`$DSH_AGENTS_HOME/skills` when configured); Harness
discovers that directory, and its native `skill` tool can load
`reverse-engineer-anything`.
Keep the default `full` catalog with Harness 0.2.0-rc.2. In a headless
loopback-model probe, `discover_tools` activated the requested tool. Harness
re-fetched `tools/list` and received the new definition, but its next model
request still omitted that tool. Verify that an active task can call a newly
listed tool before opting into hot/cold on another Harness version. To restore
upfront advertisement, run `rea setup --client dsh --tool-catalog-profile full`
and restart Harness.
REA's optional [native client verification](../development/testing.md#end-to-end-integration-and-golden-evidence)
checks headless chat, skill loading, all tool input schemas and actual analysis
using the installed Harness and a local model fixture. This establishes the
@@ -2,6 +2,7 @@ import { access, mkdir, readFile, readdir, writeFile } from "node:fs/promises";
import { dirname, join } from "node:path";
import { parse as parseToml } from "smol-toml";
import { expect } from "vitest";
import { parseDshCordisDocument } from "../../../src/application/DshCordisPatch.js";
import { createTestTempDirectory } from "../../fixtures/temporaryDirectory.js";
import { cliTest } from "../../support/cli/cliFixture.js";
@@ -125,3 +126,79 @@ cliTest.for(["codex", "cursor"] as const)(
);
},
);
cliTest(
"keeps DeepSeek Harness upfront by default and restores it by explicit selection",
async ({ cli }) => {
const home = await createTestTempDirectory("rea-dsh-catalog-");
const dshHome = join(home, "harness");
const config = join(dshHome, "cordis.patch.yml");
const original =
"- id: agent-default-model\n config:\n model: caller-choice\n";
await mkdir(dshHome);
await writeFile(config, original);
const setup = (approval: string, profile?: string) =>
cli.run({
arguments: [
"setup",
"--client",
"dsh",
"--no-skill",
approval,
"--json",
...(profile === undefined ? [] : ["--tool-catalog-profile", profile]),
],
cwd: home,
environment: {
HOME: home,
USERPROFILE: home,
DSH_HOME: dshHome,
REA_MCP_TOOL_CATALOG_PROFILE: undefined,
},
});
const read = () => readFile(config, "utf8");
const setting = "env.REA_MCP_TOOL_CATALOG_PROFILE";
const upfront = await setup("--yes");
expect(upfront.exitCode, upfront.stderr).toBe(0);
const initial = await read();
const registration = parseDshCordisDocument(initial).servers.rea;
expect(registration).toMatchObject({ transport: "stdio" });
expect(registration).not.toHaveProperty(setting);
expect(initial).toContain(original);
const preview = await setup("--dry-run", "hot-cold");
expect(preview.exitCode, preview.stderr).toBe(0);
expect(preview.json).toMatchObject({
plannedActions: [
expect.objectContaining({
detail: expect.stringContaining(
"REA_MCP_TOOL_CATALOG_PROFILE=hot-cold",
),
}),
],
});
expect(await read()).toBe(initial);
const optedIn = await setup("--yes", "hot-cold");
expect(optedIn.exitCode, optedIn.stderr).toBe(0);
const saved = await read();
expect(parseDshCordisDocument(saved).servers.rea).toHaveProperty(
setting,
"hot-cold",
);
const repeated = await setup("--yes");
expect(repeated.exitCode, repeated.stderr).toBe(0);
expect(repeated.json).toMatchObject({ appliedActions: [] });
expect(await read()).toBe(saved);
const restored = await setup("--yes", "full");
expect(restored.exitCode, restored.stderr).toBe(0);
const full = await read();
expect(parseDshCordisDocument(full).servers.rea).toHaveProperty(
setting,
"full",
);
expect(full).toContain(original);
},
);