@caupulican/pi-adaptative 0.80.50 → 0.80.52
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/CHANGELOG.md +4 -0
- package/dist/core/agent-session.d.ts +6 -0
- package/dist/core/agent-session.d.ts.map +1 -1
- package/dist/core/agent-session.js +15 -0
- package/dist/core/agent-session.js.map +1 -1
- package/dist/modes/interactive/interactive-mode.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-mode.js +1 -1
- package/dist/modes/interactive/interactive-mode.js.map +1 -1
- package/docs/docs.json +8 -0
- package/docs/index.md +2 -0
- package/docs/resources.md +178 -0
- package/docs/self-adaptation.md +68 -0
- package/examples/extensions/custom-provider-anthropic/package-lock.json +2 -2
- package/examples/extensions/custom-provider-anthropic/package.json +1 -1
- package/examples/extensions/custom-provider-gitlab-duo/package.json +1 -1
- package/examples/extensions/sandbox/package-lock.json +2 -2
- package/examples/extensions/sandbox/package.json +1 -1
- package/examples/extensions/with-deps/package-lock.json +2 -2
- package/examples/extensions/with-deps/package.json +1 -1
- package/npm-shrinkwrap.json +12 -12
- package/package.json +4 -4
|
@@ -2114,6 +2114,15 @@ export class AgentSession {
|
|
|
2114
2114
|
},
|
|
2115
2115
|
});
|
|
2116
2116
|
}
|
|
2117
|
+
/**
|
|
2118
|
+
* Resolve the active resource-profile tool allow/block filter from current settings.
|
|
2119
|
+
* Mirrors the construction-time derivation (settingsManager.getResourceProfileFilter("tools"))
|
|
2120
|
+
* so reload() can re-apply it after a live settings/profile edit.
|
|
2121
|
+
*/
|
|
2122
|
+
_deriveToolProfileFilter() {
|
|
2123
|
+
const filter = this.settingsManager.getResourceProfileFilter("tools");
|
|
2124
|
+
return { allow: filter.allow ?? [], block: filter.block ?? [] };
|
|
2125
|
+
}
|
|
2117
2126
|
_refreshToolRegistry(options) {
|
|
2118
2127
|
const previousRegistryNames = new Set(this._toolRegistry.keys());
|
|
2119
2128
|
const previousActiveToolNames = this.getActiveToolNames();
|
|
@@ -2309,6 +2318,12 @@ export class AgentSession {
|
|
|
2309
2318
|
let newRunner;
|
|
2310
2319
|
try {
|
|
2311
2320
|
await this.settingsManager.reload();
|
|
2321
|
+
// Re-derive the resource-profile tool filter from the freshly reloaded settings.
|
|
2322
|
+
// Unlike skills/prompts/themes (which re-filter through the resource loader on every
|
|
2323
|
+
// reload), the tool filter is held on the session, so without this a live edit to the
|
|
2324
|
+
// active profile's tools allow/block — or switching the active profile — would not
|
|
2325
|
+
// apply on /reload and allowed tools would stay missing.
|
|
2326
|
+
this._toolProfileFilter = this._deriveToolProfileFilter();
|
|
2312
2327
|
await this._resourceLoader.reload({ failOnExtensionErrors: true, deferExtensionDispose: true });
|
|
2313
2328
|
resetApiProviders();
|
|
2314
2329
|
this._buildRuntime({
|