reasonix 0.26.1 → 0.27.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 +8 -0
- package/README.zh-CN.md +8 -0
- package/dashboard/app.css +14 -3
- package/dashboard/dist/app.js +315 -21
- package/dashboard/dist/app.js.map +1 -1
- package/dist/cli/index.js +2187 -916
- package/dist/cli/index.js.map +1 -1
- package/dist/index.d.ts +4 -0
- package/dist/index.js +12 -0
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -446,6 +446,8 @@ declare class ImmutablePrefix {
|
|
|
446
446
|
toMessages(): ChatMessage[];
|
|
447
447
|
tools(): ToolSpec[];
|
|
448
448
|
addTool(spec: ToolSpec): boolean;
|
|
449
|
+
/** Mirror of addTool for MCP hot-unbridge. Same cache-miss cost — prefix changes shape. */
|
|
450
|
+
removeTool(name: string): boolean;
|
|
449
451
|
get fingerprint(): string;
|
|
450
452
|
/** Dev/test only — throws on cache drift, which always means a non-`addTool` mutation slipped in. */
|
|
451
453
|
verifyFingerprint(): string;
|
|
@@ -619,6 +621,8 @@ declare class ToolRegistry {
|
|
|
619
621
|
/** At most one interceptor active; calling twice replaces. */
|
|
620
622
|
setToolInterceptor(fn: ToolInterceptor | null): void;
|
|
621
623
|
register<A, R>(def: ToolDefinition<A, R>): this;
|
|
624
|
+
/** Drop a registered tool. Returns true if the name was present. Used by MCP hot-unbridge. */
|
|
625
|
+
unregister(name: string): boolean;
|
|
622
626
|
has(name: string): boolean;
|
|
623
627
|
get(name: string): ToolDefinition | undefined;
|
|
624
628
|
get size(): number;
|
package/dist/index.js
CHANGED
|
@@ -981,6 +981,10 @@ var ToolRegistry = class {
|
|
|
981
981
|
this._tools.set(def.name, internal);
|
|
982
982
|
return this;
|
|
983
983
|
}
|
|
984
|
+
/** Drop a registered tool. Returns true if the name was present. Used by MCP hot-unbridge. */
|
|
985
|
+
unregister(name) {
|
|
986
|
+
return this._tools.delete(name);
|
|
987
|
+
}
|
|
984
988
|
has(name) {
|
|
985
989
|
return this._tools.has(name);
|
|
986
990
|
}
|
|
@@ -1645,6 +1649,14 @@ var ImmutablePrefix = class {
|
|
|
1645
1649
|
this._fingerprintCache = null;
|
|
1646
1650
|
return true;
|
|
1647
1651
|
}
|
|
1652
|
+
/** Mirror of addTool for MCP hot-unbridge. Same cache-miss cost — prefix changes shape. */
|
|
1653
|
+
removeTool(name) {
|
|
1654
|
+
const idx = this._toolSpecs.findIndex((t) => t.function?.name === name);
|
|
1655
|
+
if (idx < 0) return false;
|
|
1656
|
+
this._toolSpecs.splice(idx, 1);
|
|
1657
|
+
this._fingerprintCache = null;
|
|
1658
|
+
return true;
|
|
1659
|
+
}
|
|
1648
1660
|
get fingerprint() {
|
|
1649
1661
|
if (this._fingerprintCache !== null) return this._fingerprintCache;
|
|
1650
1662
|
this._fingerprintCache = this.computeFingerprint();
|