@causyne/agent 1.20.121 → 1.20.122
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 +3 -3
- package/package.json +1 -1
- package/src/acp/agentCatalog.js +81 -26
- package/src/acp/agentCatalog.ts +73 -29
- package/src/acp/client.js +210 -53
- package/src/acp/client.ts +202 -52
- package/src/acp/peerProfiles.js +55 -22
- package/src/acp/peerProfiles.ts +51 -22
- package/src/acp/protocol.js +37 -8
- package/src/acp/protocol.ts +30 -8
- package/src/acp/server.js +123 -25
- package/src/acp/server.ts +124 -24
- package/src/agent/errorClassifier.js +6 -2
- package/src/agent/errorClassifier.ts +6 -2
- package/src/agentLoop.js +11 -5
- package/src/agentLoop.ts +11 -5
- package/src/approvalGrants.js +19 -7
- package/src/approvalGrants.ts +20 -7
- package/src/approvalPolicy.js +48 -15
- package/src/approvalPolicy.ts +46 -15
- package/src/autoUpdate.js +5 -2
- package/src/autoUpdate.ts +5 -2
- package/src/browser/causyneBrowser.js +3 -2
- package/src/browser/causyneBrowser.ts +3 -2
- package/src/browser/searchProviders.js +1 -1
- package/src/browser/searchProviders.ts +1 -1
- package/src/config.js +287 -250
- package/src/config.ts +342 -0
- package/src/configVault.js +84 -17
- package/src/configVault.ts +77 -17
- package/src/continuum/compactor.js +2 -1
- package/src/continuum/compactor.ts +2 -1
- package/src/continuum/sanitizer.js +10 -3
- package/src/continuum/sanitizer.ts +9 -3
- package/src/continuum/ui/continuumPickerView.js +3 -2
- package/src/continuum/ui/continuumPickerView.ts +3 -2
- package/src/cortex/vectorDb.js +26 -15
- package/src/cortex/vectorDb.ts +26 -16
- package/src/creative/liveBridge.js +7 -5
- package/src/creative/liveBridge.ts +7 -5
- package/src/creative/studioScripts.js +16 -5
- package/src/creative/studioScripts.ts +14 -5
- package/src/decisionPolicy.js +16 -4
- package/src/decisionPolicy.ts +14 -4
- package/src/documentEngine/antiSlopAuditor.js +10 -5
- package/src/documentEngine/antiSlopAuditor.ts +11 -5
- package/src/documentEngine/documentForge.js +47 -15
- package/src/documentEngine/documentForge.ts +43 -14
- package/src/engines/design.js +2 -1
- package/src/engines/design.ts +2 -1
- package/src/engines/film.js +4 -4
- package/src/engines/film.ts +2 -2
- package/src/engines/light.js +2 -1
- package/src/engines/light.ts +2 -1
- package/src/engines/registry.js +1 -1
- package/src/engines/registry.ts +1 -1
- package/src/engines/reverseHarness.js +4 -3
- package/src/engines/reverseHarness.ts +4 -3
- package/src/headlessCli.js +2 -1
- package/src/headlessCli.ts +2 -1
- package/src/historyPruner.js +3 -2
- package/src/historyPruner.ts +3 -2
- package/src/hooks.js +3 -0
- package/src/hooks.ts +3 -0
- package/src/implementationPlan.js +21 -11
- package/src/implementationPlan.ts +21 -11
- package/src/infra/atomicWriter.js +4 -1
- package/src/infra/atomicWriter.ts +4 -1
- package/src/launchIntent.js +1 -1
- package/src/launchIntent.ts +1 -1
- package/src/memory/scopedFacts.js +1 -1
- package/src/memory/scopedFacts.ts +1 -1
- package/src/memory/symbolFolder.js +1 -1
- package/src/memory/symbolFolder.ts +1 -1
- package/src/modelRouter.js +1 -1
- package/src/modelRouter.ts +1 -1
- package/src/observer/evidence.js +10 -4
- package/src/observer/evidence.ts +10 -4
- package/src/osKeychain.js +62 -8
- package/src/osKeychain.ts +50 -8
- package/src/perception.js +3 -2
- package/src/perception.ts +3 -2
- package/src/planCache.js +2 -2
- package/src/planCache.ts +2 -2
- package/src/pluginsFactory/pluginsFactory.js +19 -11
- package/src/pluginsFactory/pluginsFactory.ts +18 -11
- package/src/promptMentions.js +2 -2
- package/src/promptMentions.ts +2 -2
- package/src/providers/acp.js +1 -1
- package/src/providers/acp.ts +1 -1
- package/src/providers/anthropic.js +327 -401
- package/src/providers/anthropic.ts +386 -0
- package/src/providers/antigravity.js +10 -4
- package/src/providers/antigravity.ts +10 -4
- package/src/providers/base.js +221 -319
- package/src/providers/base.ts +340 -0
- package/src/providers/byokHttp.js +58 -15
- package/src/providers/byokHttp.ts +59 -16
- package/src/providers/byokStream.js +142 -51
- package/src/providers/byokStream.ts +146 -42
- package/src/providers/dashscope-byok.js +97 -89
- package/src/providers/dashscope-byok.ts +114 -0
- package/src/providers/deepseek.js +73 -72
- package/src/providers/deepseek.ts +99 -0
- package/src/providers/factory.js +35 -28
- package/src/providers/factory.ts +40 -0
- package/src/providers/gemini.js +227 -278
- package/src/providers/gemini.ts +261 -0
- package/src/providers/loopGuard.js +9 -5
- package/src/providers/loopGuard.ts +10 -5
- package/src/providers/moonshot.js +70 -72
- package/src/providers/moonshot.ts +93 -0
- package/src/providers/muse.js +82 -152
- package/src/providers/muse.ts +122 -0
- package/src/providers/ollama.js +114 -106
- package/src/providers/ollama.ts +135 -0
- package/src/providers/openai-compatible.js +113 -96
- package/src/providers/openai-compatible.ts +139 -0
- package/src/providers/openai.js +22 -15
- package/src/providers/openai.ts +30 -0
- package/src/providers/openrouter.js +136 -74
- package/src/providers/openrouter.ts +133 -72
- package/src/providers/pi.js +6 -0
- package/src/providers/pi.ts +6 -0
- package/src/providers/qwen-byok.js +96 -87
- package/src/providers/qwen-byok.ts +113 -0
- package/src/providers/toolContracts.js +40 -14
- package/src/providers/toolContracts.ts +35 -14
- package/src/providers/wireNormalizer.js +78 -11
- package/src/providers/wireNormalizer.ts +68 -12
- package/src/providers/xai.js +73 -72
- package/src/providers/xai.ts +97 -0
- package/src/reliability/assetEvidence.js +4 -2
- package/src/reliability/assetEvidence.ts +4 -2
- package/src/sandbox.js +489 -554
- package/src/sandbox.ts +552 -0
- package/src/sandboxPolicy.js +95 -16
- package/src/sandboxPolicy.ts +97 -16
- package/src/sessionJournal.js +8 -3
- package/src/sessionJournal.ts +9 -3
- package/src/skills/skillResourceSafety.js +19 -8
- package/src/skills/skillResourceSafety.ts +16 -7
- package/src/skillsManager.js +3 -3
- package/src/skillsManager.ts +3 -3
- package/src/smartToolsUse.js +28 -4
- package/src/smartToolsUse.ts +29 -7
- package/src/stallGuard.js +45 -22
- package/src/stallGuard.ts +46 -22
- package/src/subagentJournal.js +6 -4
- package/src/subagentJournal.ts +6 -4
- package/src/textDiff.js +6 -1
- package/src/textDiff.ts +6 -1
- package/src/timeMachine.js +7 -1
- package/src/timeMachine.ts +7 -1
- package/src/tokenTracker.js +43 -28
- package/src/tokenTracker.ts +44 -30
- package/src/toolPacks.js +3 -1
- package/src/toolPacks.ts +3 -1
- package/src/tools/archive.js +245 -35
- package/src/tools/archive.ts +244 -35
- package/src/tools/computerUse.js +7 -3
- package/src/tools/computerUse.ts +7 -3
- package/src/tools/creativeApps.js +13 -8
- package/src/tools/creativeApps.ts +22 -9
- package/src/tools/deferredMcpSearch.js +26 -14
- package/src/tools/deferredMcpSearch.ts +26 -14
- package/src/tools/desktopOpen.js +69 -10
- package/src/tools/desktopOpen.ts +70 -11
- package/src/tools/documentForge.js +167 -82
- package/src/tools/documentForge.ts +169 -84
- package/src/tools/fsEdit.js +101 -30
- package/src/tools/fsEdit.ts +105 -32
- package/src/tools/fsFind.js +8 -5
- package/src/tools/fsFind.ts +7 -4
- package/src/tools/fsRead.js +119 -13
- package/src/tools/fsRead.ts +124 -13
- package/src/tools/fsWrite.js +17 -5
- package/src/tools/fsWrite.ts +17 -7
- package/src/tools/generateMediaViaApi.js +82 -19
- package/src/tools/generateMediaViaApi.ts +80 -19
- package/src/tools/memoryRecall.js +62 -11
- package/src/tools/memoryRecall.ts +70 -13
- package/src/tools/memoryWrite.js +27 -14
- package/src/tools/memoryWrite.ts +30 -14
- package/src/tools/multiEdit.js +100 -30
- package/src/tools/multiEdit.ts +104 -32
- package/src/tools/nativeEngine.js +33 -18
- package/src/tools/nativeEngine.ts +31 -18
- package/src/tools/openSourceToolProvisioner.js +49 -14
- package/src/tools/openSourceToolProvisioner.ts +54 -15
- package/src/tools/osSandbox.js +54 -14
- package/src/tools/osSandbox.ts +48 -14
- package/src/tools/payloadSanitizer.js +40 -8
- package/src/tools/payloadSanitizer.ts +39 -8
- package/src/tools/peerAgent.js +96 -34
- package/src/tools/peerAgent.ts +114 -37
- package/src/tools/pluginsFactory.js +38 -6
- package/src/tools/pluginsFactory.ts +42 -6
- package/src/tools/readNativeSkill.js +10 -8
- package/src/tools/readNativeSkill.ts +10 -8
- package/src/tools/requestDecision.js +10 -3
- package/src/tools/requestDecision.ts +10 -3
- package/src/tools/resolveAutomator.js +91 -17
- package/src/tools/resolveAutomator.ts +102 -17
- package/src/tools/reverseEngineering.js +168 -41
- package/src/tools/reverseEngineering.ts +161 -41
- package/src/tools/sysRun.js +69 -29
- package/src/tools/sysRun.ts +66 -24
- package/src/tools/toolDispatch.js +24 -1
- package/src/tools/toolDispatch.ts +21 -1
- package/src/tools/toolOutputStore.js +62 -23
- package/src/tools/toolOutputStore.ts +56 -23
- package/src/tools/toolScanner.js +13 -10
- package/src/tools/toolScanner.ts +13 -10
- package/src/tools/toolSelfRepair.js +94 -28
- package/src/tools/toolSelfRepair.ts +96 -28
- package/src/tools/uiForge.js +71 -6
- package/src/tools/uiForge.ts +74 -6
- package/src/tools/viewImage.js +62 -17
- package/src/tools/viewImage.ts +57 -12
- package/src/tools/visionInspector.js +15 -3
- package/src/tools/visionInspector.ts +15 -3
- package/src/tools/walkerSafety.js +2 -0
- package/src/tools/walkerSafety.ts +1 -0
- package/src/tools/webFetch.js +105 -10
- package/src/tools/webFetch.ts +105 -11
- package/src/tui/banner.js +3 -2
- package/src/tui/banner.ts +3 -2
- package/src/tui/consoleGuard.js +12 -4
- package/src/tui/consoleGuard.ts +9 -4
- package/src/tui/messageInteraction.js +2 -3
- package/src/tui/messageInteraction.ts +2 -3
- package/src/tui/modelPicker.js +1 -0
- package/src/tui/modelPicker.ts +1 -0
- package/src/tui/overlay.js +3 -1
- package/src/tui/overlay.ts +3 -1
- package/src/tui/sessionPicker.js +3 -2
- package/src/tui/sessionPicker.ts +3 -2
- package/src/tui/sessionPickerView.js +7 -1
- package/src/tui/sessionPickerView.ts +6 -1
- package/src/tui/toolOutputNormalizer.js +2 -3
- package/src/tui/toolOutputNormalizer.ts +4 -3
- package/src/tui/viewport.js +4 -4
- package/src/tui/viewport.ts +5 -5
- package/src/tui/workspaceIdentity.js +2 -1
- package/src/tui/workspaceIdentity.ts +2 -1
- package/src/uncertainty.js +8 -3
- package/src/uncertainty.ts +8 -3
- package/src/utils/paths.js +8 -5
- package/src/utils/paths.ts +9 -7
- package/src/vfeTracker.js +9 -3
- package/src/vfeTracker.ts +9 -3
- package/src/config.d.ts +0 -2
- package/src/providers/base.d.ts +0 -94
- package/src/providers/factory.d.ts +0 -1
- package/src/sandbox.d.ts +0 -1
package/src/perception.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import fs from 'node:fs/promises';
|
|
2
2
|
import path from 'node:path';
|
|
3
3
|
import os from 'node:os';
|
|
4
|
+
import { resolveUserPath } from './utils/paths.js';
|
|
4
5
|
|
|
5
6
|
const SKIP_DIRECTORIES = new Set([
|
|
6
7
|
'node_modules', '.git', 'dist', 'build', 'out', 'target',
|
|
@@ -60,7 +61,7 @@ export interface WorkspaceContextData {
|
|
|
60
61
|
|
|
61
62
|
export class WorkspacePerception {
|
|
62
63
|
async buildContext(workspacePath: string): Promise<WorkspaceContextData> {
|
|
63
|
-
const resolvedPath = workspacePath
|
|
64
|
+
const resolvedPath = resolveUserPath(workspacePath);
|
|
64
65
|
|
|
65
66
|
const context: Partial<WorkspaceContextData> = {
|
|
66
67
|
cwd: resolvedPath,
|
|
@@ -437,7 +438,7 @@ export class WorkspacePerception {
|
|
|
437
438
|
}
|
|
438
439
|
|
|
439
440
|
async detectGitInfo(dir: string): Promise<GitInfo> {
|
|
440
|
-
let current = dir;
|
|
441
|
+
let current = path.resolve(dir);
|
|
441
442
|
for (let depth = 0; depth < 5; depth++) {
|
|
442
443
|
const gitDir = path.join(current, '.git');
|
|
443
444
|
try {
|
package/src/planCache.js
CHANGED
|
@@ -680,10 +680,10 @@ export function lookupAlternativeStep(query) {
|
|
|
680
680
|
for (const template of plans) {
|
|
681
681
|
if (archetype && template.archetype && template.archetype !== archetype)
|
|
682
682
|
continue;
|
|
683
|
-
const failedIdx = template.steps.findIndex((s) => s.tool.toLowerCase() === failedTool);
|
|
683
|
+
const failedIdx = template.steps.findIndex((s) => s.tool.toLowerCase() === failedTool && !s.ok && (!why || s.why === why));
|
|
684
684
|
if (failedIdx !== -1) {
|
|
685
685
|
const step = template.steps[failedIdx];
|
|
686
|
-
if (step
|
|
686
|
+
if (step) {
|
|
687
687
|
const nextStep = template.steps.slice(failedIdx + 1).find((s) => s.ok);
|
|
688
688
|
if (nextStep) {
|
|
689
689
|
return {
|
package/src/planCache.ts
CHANGED
|
@@ -817,10 +817,10 @@ export function lookupAlternativeStep(query: AlternativeStepQuery): AlternativeS
|
|
|
817
817
|
|
|
818
818
|
for (const template of plans) {
|
|
819
819
|
if (archetype && template.archetype && template.archetype !== archetype) continue;
|
|
820
|
-
const failedIdx = template.steps.findIndex((s) => s.tool.toLowerCase() === failedTool);
|
|
820
|
+
const failedIdx = template.steps.findIndex((s) => s.tool.toLowerCase() === failedTool && !s.ok && (!why || s.why === why));
|
|
821
821
|
if (failedIdx !== -1) {
|
|
822
822
|
const step = template.steps[failedIdx];
|
|
823
|
-
if (step
|
|
823
|
+
if (step) {
|
|
824
824
|
const nextStep = template.steps.slice(failedIdx + 1).find((s) => s.ok);
|
|
825
825
|
if (nextStep) {
|
|
826
826
|
return {
|
|
@@ -179,9 +179,19 @@ export class PluginsFactory {
|
|
|
179
179
|
error: `Target path escapes directory boundary: ${targetDir}`
|
|
180
180
|
};
|
|
181
181
|
}
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
182
|
+
const safeLstat = (p) => {
|
|
183
|
+
try {
|
|
184
|
+
return fs.lstatSync(p);
|
|
185
|
+
}
|
|
186
|
+
catch (err) {
|
|
187
|
+
if (err && err.code === 'ENOENT')
|
|
188
|
+
return null;
|
|
189
|
+
throw err;
|
|
190
|
+
}
|
|
191
|
+
};
|
|
192
|
+
const existingTargetStat = safeLstat(targetDir);
|
|
193
|
+
if (existingTargetStat) {
|
|
194
|
+
if (existingTargetStat.isSymbolicLink()) {
|
|
185
195
|
return {
|
|
186
196
|
success: false,
|
|
187
197
|
route,
|
|
@@ -191,7 +201,7 @@ export class PluginsFactory {
|
|
|
191
201
|
error: `Target path must not be a symlink: ${targetDir}`
|
|
192
202
|
};
|
|
193
203
|
}
|
|
194
|
-
if (!
|
|
204
|
+
if (!existingTargetStat.isDirectory()) {
|
|
195
205
|
return {
|
|
196
206
|
success: false,
|
|
197
207
|
route,
|
|
@@ -245,14 +255,12 @@ export class PluginsFactory {
|
|
|
245
255
|
for (const file of payload.files) {
|
|
246
256
|
const filePath = path.join(targetDir, file.relativePath);
|
|
247
257
|
const fileDir = path.dirname(filePath);
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
throw new Error(`Refusing to write through symlinked directory: ${fileDir}`);
|
|
252
|
-
}
|
|
258
|
+
const dirStat = safeLstat(fileDir);
|
|
259
|
+
if (dirStat?.isSymbolicLink()) {
|
|
260
|
+
throw new Error(`Refusing to write through symlinked directory: ${fileDir}`);
|
|
253
261
|
}
|
|
254
|
-
|
|
255
|
-
|
|
262
|
+
const fileStat = safeLstat(filePath);
|
|
263
|
+
if (fileStat) {
|
|
256
264
|
if (fileStat.isSymbolicLink()) {
|
|
257
265
|
throw new Error(`Refusing to overwrite symlinked file: ${filePath}`);
|
|
258
266
|
}
|
|
@@ -221,9 +221,18 @@ export class PluginsFactory {
|
|
|
221
221
|
};
|
|
222
222
|
}
|
|
223
223
|
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
224
|
+
const safeLstat = (p: string): fs.Stats | null => {
|
|
225
|
+
try {
|
|
226
|
+
return fs.lstatSync(p);
|
|
227
|
+
} catch (err: any) {
|
|
228
|
+
if (err && err.code === 'ENOENT') return null;
|
|
229
|
+
throw err;
|
|
230
|
+
}
|
|
231
|
+
};
|
|
232
|
+
|
|
233
|
+
const existingTargetStat = safeLstat(targetDir);
|
|
234
|
+
if (existingTargetStat) {
|
|
235
|
+
if (existingTargetStat.isSymbolicLink()) {
|
|
227
236
|
return {
|
|
228
237
|
success: false,
|
|
229
238
|
route,
|
|
@@ -233,7 +242,7 @@ export class PluginsFactory {
|
|
|
233
242
|
error: `Target path must not be a symlink: ${targetDir}`
|
|
234
243
|
};
|
|
235
244
|
}
|
|
236
|
-
if (!
|
|
245
|
+
if (!existingTargetStat.isDirectory()) {
|
|
237
246
|
return {
|
|
238
247
|
success: false,
|
|
239
248
|
route,
|
|
@@ -288,14 +297,12 @@ export class PluginsFactory {
|
|
|
288
297
|
for (const file of payload.files) {
|
|
289
298
|
const filePath = path.join(targetDir, file.relativePath);
|
|
290
299
|
const fileDir = path.dirname(filePath);
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
throw new Error(`Refusing to write through symlinked directory: ${fileDir}`);
|
|
295
|
-
}
|
|
300
|
+
const dirStat = safeLstat(fileDir);
|
|
301
|
+
if (dirStat?.isSymbolicLink()) {
|
|
302
|
+
throw new Error(`Refusing to write through symlinked directory: ${fileDir}`);
|
|
296
303
|
}
|
|
297
|
-
|
|
298
|
-
|
|
304
|
+
const fileStat = safeLstat(filePath);
|
|
305
|
+
if (fileStat) {
|
|
299
306
|
if (fileStat.isSymbolicLink()) {
|
|
300
307
|
throw new Error(`Refusing to overwrite symlinked file: ${filePath}`);
|
|
301
308
|
}
|
package/src/promptMentions.js
CHANGED
|
@@ -38,8 +38,8 @@ export function extractMentions(text) {
|
|
|
38
38
|
// Matches @ preceded by start-of-line or whitespace, not part of an email address
|
|
39
39
|
const unquotedRegex = /(?:^|\s)@([a-zA-Z0-9_.\-/\\]+)(?=$|\s|[.,;:?!)\]}])/g;
|
|
40
40
|
while ((match = unquotedRegex.exec(text)) !== null) {
|
|
41
|
-
const
|
|
42
|
-
const
|
|
41
|
+
const cleanPath = (match[1] ?? '').trim().replace(/([^./\\])\.+$/, '$1');
|
|
42
|
+
const raw = `@${cleanPath}`;
|
|
43
43
|
// Skip if already captured via quotes or if empty
|
|
44
44
|
if (!cleanPath || seen.has(cleanPath))
|
|
45
45
|
continue;
|
package/src/promptMentions.ts
CHANGED
|
@@ -60,8 +60,8 @@ export function extractMentions(text: string): Mention[] {
|
|
|
60
60
|
// Matches @ preceded by start-of-line or whitespace, not part of an email address
|
|
61
61
|
const unquotedRegex = /(?:^|\s)@([a-zA-Z0-9_.\-/\\]+)(?=$|\s|[.,;:?!)\]}])/g;
|
|
62
62
|
while ((match = unquotedRegex.exec(text)) !== null) {
|
|
63
|
-
const
|
|
64
|
-
const
|
|
63
|
+
const cleanPath = (match[1] ?? '').trim().replace(/([^./\\])\.+$/, '$1');
|
|
64
|
+
const raw = `@${cleanPath}`;
|
|
65
65
|
|
|
66
66
|
// Skip if already captured via quotes or if empty
|
|
67
67
|
if (!cleanPath || seen.has(cleanPath)) continue;
|
package/src/providers/acp.js
CHANGED
|
@@ -12,7 +12,7 @@ import { PEER_COLLABORATION_POLICY } from './collaborationPolicy.js';
|
|
|
12
12
|
import { extractToolCallJsonObjects, stripToolCallMarkup, resolveToolCallEnvelopeArguments } from '../implementationPlan.js';
|
|
13
13
|
import { canonicalizeToolName } from '../tools/toolSelfRepair.js';
|
|
14
14
|
function fingerprint(value) {
|
|
15
|
-
return createHash('sha256').update(JSON.stringify(value)).digest('hex');
|
|
15
|
+
return createHash('sha256').update(JSON.stringify(value) ?? 'undefined').digest('hex');
|
|
16
16
|
}
|
|
17
17
|
export function isAcpProvider(provider) {
|
|
18
18
|
if (!provider)
|
package/src/providers/acp.ts
CHANGED
|
@@ -26,7 +26,7 @@ interface AcpTransportSnapshot {
|
|
|
26
26
|
}
|
|
27
27
|
|
|
28
28
|
function fingerprint(value: unknown): string {
|
|
29
|
-
return createHash('sha256').update(JSON.stringify(value)).digest('hex');
|
|
29
|
+
return createHash('sha256').update(JSON.stringify(value) ?? 'undefined').digest('hex');
|
|
30
30
|
}
|
|
31
31
|
|
|
32
32
|
export function isAcpProvider(provider?: string | null): boolean {
|