@wrongstack/core 0.300.0 → 0.302.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/dist/chronicle/index.d.ts +2 -0
- package/dist/chronicle/index.js +297 -10
- package/dist/chronicle/project-server.js +253 -15
- package/dist/chronicle/sqlite-compaction.d.ts +20 -0
- package/dist/chronicle/sqlite-journal.d.ts +57 -0
- package/dist/coordination/agents/capability-manifest.d.ts +7 -0
- package/dist/coordination/agents/index.d.ts +3 -2
- package/dist/coordination/agents/index.js +818 -570
- package/dist/coordination/agents/project-agent-identity.d.ts +6 -6
- package/dist/coordination/agents/role-skills.d.ts +1 -1
- package/dist/coordination/agents/types.d.ts +6 -0
- package/dist/coordination/director.d.ts +2 -2
- package/dist/coordination/index.js +6787 -6447
- package/dist/coordination/mail-tools.d.ts +3 -3
- package/dist/coordination/mailbox-project-server.js +3 -4
- package/dist/coordination/mailbox-types.d.ts +6 -0
- package/dist/core/agent-response.d.ts +5 -1
- package/dist/core/agent-tools.d.ts +3 -0
- package/dist/core/context.d.ts +20 -0
- package/dist/core/index.d.ts +8 -7
- package/dist/core/index.js +893 -284
- package/dist/core/instruction-template.d.ts +6 -3
- package/dist/core/next-steps-slot.d.ts +88 -0
- package/dist/core/system-prompt-builder.d.ts +5 -3
- package/dist/core/system-prompt-memory-skills.d.ts +1 -0
- package/dist/core/system-prompt-skill-bodies.d.ts +3 -3
- package/dist/defaults/index.js +9797 -8898
- package/dist/design/index.js +11 -3
- package/dist/execution/auto-compaction-middleware.d.ts +17 -0
- package/dist/execution/autonomy-brain.d.ts +8 -2
- package/dist/execution/brain-runtime.d.ts +3 -1
- package/dist/execution/compaction-core.d.ts +41 -2
- package/dist/execution/council-brain.d.ts +37 -2
- package/dist/execution/council-orchestrator.d.ts +2 -2
- package/dist/execution/index.d.ts +11 -10
- package/dist/execution/index.js +5179 -4078
- package/dist/execution/tool-executor.d.ts +4 -1
- package/dist/execution/topic-shift-advisor.d.ts +53 -0
- package/dist/extension/index.js +8 -2
- package/dist/extension/registry.d.ts +8 -1
- package/dist/goal/index.js +11 -3
- package/dist/hooks/index.js +42 -9
- package/dist/hooks/runner.d.ts +12 -1
- package/dist/hq/index.js +41 -17
- package/dist/hq/publisher.d.ts +21 -3
- package/dist/index.d.ts +21 -20
- package/dist/index.js +10901 -8067
- package/dist/infrastructure/index.js +108 -21
- package/dist/kernel/events/session-events.d.ts +13 -0
- package/dist/kernel/events/tool-events.d.ts +3 -3
- package/dist/models/index.d.ts +1 -0
- package/dist/models/index.js +17 -0
- package/dist/models/provider-credentials.d.ts +54 -0
- package/dist/plugin/index.d.ts +1 -0
- package/dist/plugin/index.js +2024 -502
- package/dist/plugins/auto-review-plugin.d.ts +3 -0
- package/dist/plugins/cloud-config-sync-plugin.d.ts +22 -0
- package/dist/plugins/review-claim-registry.d.ts +23 -8
- package/dist/plugins/review-types.d.ts +2 -0
- package/dist/registry/index.js +109 -74
- package/dist/registry/tool-registry.d.ts +15 -0
- package/dist/security/capabilities.d.ts +2 -0
- package/dist/security/index.d.ts +1 -1
- package/dist/security/index.js +9 -2
- package/dist/security/readonly-permission-policy.d.ts +20 -0
- package/dist/session-registry-atomic-file.d.ts +32 -5
- package/dist/session-registry-types.d.ts +17 -0
- package/dist/session-registry.d.ts +1 -1
- package/dist/skills/frontmatter.d.ts +6 -0
- package/dist/skills/index.js +22 -5
- package/dist/storage/cloud-config-sync/sanitize.d.ts +54 -0
- package/dist/storage/cloud-config-sync.d.ts +87 -0
- package/dist/storage/index.d.ts +2 -1
- package/dist/storage/index.js +854 -66
- package/dist/tools/index.d.ts +1 -1
- package/dist/tools/index.js +511 -234
- package/dist/tools/one-shot-llm-tool.d.ts +1 -0
- package/dist/tools/plugin-manager.d.ts +27 -0
- package/dist/types/config/mcp-features.d.ts +18 -11
- package/dist/types/config/root.d.ts +8 -1
- package/dist/types/config/runtime.d.ts +20 -6
- package/dist/types/config/skills-fleet-brain.d.ts +12 -4
- package/dist/types/config/tools.d.ts +16 -0
- package/dist/types/context-window.d.ts +1 -0
- package/dist/types/hooks.d.ts +14 -0
- package/dist/types/index.d.ts +2 -2
- package/dist/types/index.js +1 -0
- package/dist/types/multi-agent.d.ts +2 -0
- package/dist/types/one-shot-llm.d.ts +16 -0
- package/dist/types/provider.d.ts +16 -0
- package/dist/types/runtime-capability-manifest.d.ts +168 -0
- package/dist/types/skill.d.ts +5 -0
- package/dist/types/system-prompt.d.ts +3 -1
- package/dist/types/tool-executor.d.ts +8 -1
- package/dist/utils/context-breakdown.d.ts +8 -2
- package/dist/utils/index.d.ts +1 -1
- package/dist/utils/index.js +141 -31
- package/dist/utils/regex-guard.d.ts +16 -2
- package/dist/utils/sage-output-block.d.ts +7 -10
- package/dist/utils/wstack-paths.d.ts +11 -3
- package/instructions/agents/browser.md +1 -4
- package/instructions/agents/e2e.md +17 -15
- package/instructions/agents/ios.md +3 -3
- package/instructions/agents/search.md +1 -1
- package/instructions/autonomy/goal-preamble.md +4 -4
- package/instructions/coordination/director-preamble.md +2 -3
- package/instructions/coordination/subagent-baseline.md +3 -1
- package/instructions/leader-after-task.md +12 -0
- package/instructions/llm/chimera-review.md +1 -1
- package/instructions/modes/audit-lite.md +1 -1
- package/instructions/sections/tool/common-patterns.md +18 -2
- package/instructions/sections/tool/mailbox-compact.md +1 -1
- package/instructions/sections/tool/mailbox-full.md +1 -1
- package/instructions/system-lite.md +10 -0
- package/instructions/system-pro.md +23 -14
- package/instructions/system.md +22 -13
- package/package.json +3 -3
- package/skills/api-design/SKILL.md +3 -0
- package/skills/audit-log/SKILL.md +2 -0
- package/skills/auto-review/SKILL.md +6 -1
- package/skills/bug-hunter/SKILL.md +4 -1
- package/skills/chimera/SKILL.md +3 -0
- package/skills/data-governance/SKILL.md +3 -0
- package/skills/design-system/SKILL.md +5 -2
- package/skills/docker-deploy/SKILL.md +2 -0
- package/skills/git-flow/SKILL.md +2 -0
- package/skills/mailbox-bridge/SKILL.md +3 -0
- package/skills/mnemosyne/SKILL.md +2 -0
- package/skills/multi-agent/SKILL.md +4 -1
- package/skills/node-modern/SKILL.md +4 -1
- package/skills/observability/SKILL.md +3 -0
- package/skills/output-standards/SKILL.md +2 -0
- package/skills/plugin-author/SKILL.md +4 -1
- package/skills/prompt-engineering/SKILL.md +3 -1
- package/skills/react-modern/SKILL.md +6 -3
- package/skills/refactor-planner/SKILL.md +2 -0
- package/skills/research-web/SKILL.md +3 -0
- package/skills/sdd/SKILL.md +3 -1
- package/skills/security-scanner/SKILL.md +3 -0
- package/skills/skill-creator/SKILL.md +2 -0
- package/skills/tech-stack/SKILL.md +3 -0
- package/skills/testing/SKILL.md +4 -1
- package/skills/typescript-strict/SKILL.md +4 -1
- package/skills/wrongstack-kanban/SKILL.md +6 -3
- package/skills/wrongstack-mailbox/SKILL.md +4 -1
- package/skills/wrongstack-mailbox-mcp/SKILL.md +10 -8
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
export { applyNamespacePayload, buildNamespacePayloads, CLOUD_SYNC_CONTRACT, CLOUD_SYNC_NAMESPACES, LOCAL_ONLY_TOP_LEVEL, NAMESPACE_SCHEMA_VERSIONS, stripSecretMaterial, } from './cloud-config-sync/sanitize.js';
|
|
2
|
+
/**
|
|
3
|
+
* CloudConfigSync — synchronizes the profile config with my.wrongstack.com over the
|
|
4
|
+
* namespaced sync API v1 (server repo: docs/CLIENT_SYNC_CONTRACT.md).
|
|
5
|
+
*
|
|
6
|
+
* Distinct from the legacy GitHub `CloudSync` (whole-file categories to a private repo)
|
|
7
|
+
* and from the local HQ command center: this speaks the portal's revisioned,
|
|
8
|
+
* schema-validated, secret-free namespace protocol.
|
|
9
|
+
*
|
|
10
|
+
* A sync pass is pull-then-push:
|
|
11
|
+
* 1. `GET /config?since=<cursor>` — apply changed namespaces at contract granularity
|
|
12
|
+
* (locally-kept fields the contract does not own are never clobbered).
|
|
13
|
+
* 2. For each namespace whose projected payload hash differs from the last synced
|
|
14
|
+
* hash: `PUT /config/<ns>` with `baseRevision` + a persisted `mutationId`, so a
|
|
15
|
+
* crash-and-retry of the same logical change is idempotent server-side.
|
|
16
|
+
* 3. `POST /heartbeat` with the cursor and revision map for fleet observability.
|
|
17
|
+
*
|
|
18
|
+
* Conflicts (409) resolve by three-way merge at owned-top-level-key granularity: keys the
|
|
19
|
+
* local machine did not change since its last sync adopt the server value; keys it did
|
|
20
|
+
* change keep the local value and are re-pushed on top of the server revision.
|
|
21
|
+
*/
|
|
22
|
+
export interface CloudConfigSyncSettings {
|
|
23
|
+
enabled: boolean;
|
|
24
|
+
/** Portal base URL, e.g. https://my.wrongstack.com — no trailing slash needed. */
|
|
25
|
+
url: string;
|
|
26
|
+
/** Machine bearer token (wst_…), already decrypted. */
|
|
27
|
+
token: string;
|
|
28
|
+
}
|
|
29
|
+
export interface CloudConfigSyncDeps {
|
|
30
|
+
/** State file location, e.g. `<profileDir>/cloud-sync-state.json`. */
|
|
31
|
+
statePath: string;
|
|
32
|
+
/** Reads the decrypted profile config object (the file layer, not env/CLI merges). */
|
|
33
|
+
readLocalConfig(): Promise<Record<string, unknown>>;
|
|
34
|
+
/**
|
|
35
|
+
* Atomically mutates the profile config file. The mutator receives the decrypted
|
|
36
|
+
* object and returns the replacement; the writer re-encrypts secrets and persists.
|
|
37
|
+
*/
|
|
38
|
+
writeLocalConfig(mutator: (config: Record<string, unknown>) => Record<string, unknown>): Promise<void>;
|
|
39
|
+
/** Resolved cloud-sync settings, or null when unconfigured/disabled. */
|
|
40
|
+
getSettings(): CloudConfigSyncSettings | null;
|
|
41
|
+
fetchImpl?: typeof fetch | undefined;
|
|
42
|
+
appVersion?: string | undefined;
|
|
43
|
+
logger?: {
|
|
44
|
+
info(msg: string): void;
|
|
45
|
+
warn(msg: string): void;
|
|
46
|
+
} | undefined;
|
|
47
|
+
randomUUID?: (() => string) | undefined;
|
|
48
|
+
/** Request timeout per HTTP call. Default 15s. */
|
|
49
|
+
requestTimeoutMs?: number | undefined;
|
|
50
|
+
}
|
|
51
|
+
export interface CloudSyncPassSummary {
|
|
52
|
+
ok: boolean;
|
|
53
|
+
skipped: boolean;
|
|
54
|
+
pulled: string[];
|
|
55
|
+
pushed: string[];
|
|
56
|
+
conflicted: string[];
|
|
57
|
+
rejected: string[];
|
|
58
|
+
message: string;
|
|
59
|
+
}
|
|
60
|
+
export declare class CloudConfigSync {
|
|
61
|
+
private readonly deps;
|
|
62
|
+
private state;
|
|
63
|
+
private readonly fetchImpl;
|
|
64
|
+
private readonly uuid;
|
|
65
|
+
private readonly timeoutMs;
|
|
66
|
+
constructor(deps: CloudConfigSyncDeps);
|
|
67
|
+
/** One full pull-then-push-then-heartbeat pass. Never throws; failures are summarized. */
|
|
68
|
+
syncOnce(): Promise<CloudSyncPassSummary>;
|
|
69
|
+
/** Human-readable status for the slash command. */
|
|
70
|
+
statusText(): Promise<string>;
|
|
71
|
+
private pullChanges;
|
|
72
|
+
private applySnapshot;
|
|
73
|
+
private dirtyNamespaces;
|
|
74
|
+
private pushDirty;
|
|
75
|
+
private putNamespace;
|
|
76
|
+
/**
|
|
77
|
+
* Three-way merge at owned-top-level-key granularity: keys unchanged locally since the
|
|
78
|
+
* last sync adopt the server value; locally-changed keys win and are re-pushed on top
|
|
79
|
+
* of the server revision with a fresh mutation id.
|
|
80
|
+
*/
|
|
81
|
+
private resolveConflict;
|
|
82
|
+
private heartbeat;
|
|
83
|
+
private request;
|
|
84
|
+
private loadState;
|
|
85
|
+
private saveState;
|
|
86
|
+
}
|
|
87
|
+
//# sourceMappingURL=cloud-config-sync.d.ts.map
|
package/dist/storage/index.d.ts
CHANGED
|
@@ -20,7 +20,7 @@ export { ReplayLogStore, type ReplayEntry, type ReplayLogStoreOptions, } from '.
|
|
|
20
20
|
export { SessionRecovery, type StaleSession, type RecoveryPlan, } from './session-recovery.js';
|
|
21
21
|
export { ToolAuditLog, type AuditEntry, type ToolAuditLogOptions, type VerifyResult, } from './tool-audit-log.js';
|
|
22
22
|
export { SessionAnalyzer } from './session-analyzer.js';
|
|
23
|
-
export { SessionRegistry, getSessionRegistry, hasSessionRegistry, type SessionRegistryEntry, type AgentEntry, type AgentLiveStatus, type SessionLiveStatus, } from '../session-registry.js';
|
|
23
|
+
export { SessionRegistry, getSessionRegistry, hasSessionRegistry, type SessionRegistryEntry, type SessionWebUIEndpointHint, type AgentEntry, type AgentLiveStatus, type SessionLiveStatus, } from '../session-registry.js';
|
|
24
24
|
export { AgentStatusTracker, type AgentStatusTrackerOptions, } from '../agent-status-tracker.js';
|
|
25
25
|
export { FleetNotifier, type FleetNotifierOptions, } from '../fleet-notifier.js';
|
|
26
26
|
export { DefaultSessionRewinder, type SessionRewinderOptions, } from './session-rewinder.js';
|
|
@@ -38,6 +38,7 @@ export { DefaultPromptStore, migratePromptEntry, promptChecksum, type PromptStor
|
|
|
38
38
|
export { PromptUsageStore, type PromptUsage } from './prompt-usage-store.js';
|
|
39
39
|
export { InputHistoryStore, INPUT_HISTORY_DEFAULT_MAX, } from './input-history-store.js';
|
|
40
40
|
export { CloudSync, type SyncResult, ALL_SYNC_CATEGORIES, } from './cloud-sync.js';
|
|
41
|
+
export { applyNamespacePayload, buildNamespacePayloads, CLOUD_SYNC_CONTRACT, CLOUD_SYNC_NAMESPACES, CloudConfigSync, type CloudConfigSyncDeps, type CloudConfigSyncSettings, type CloudSyncPassSummary, LOCAL_ONLY_TOP_LEVEL, NAMESPACE_SCHEMA_VERSIONS, stripSecretMaterial, } from './cloud-config-sync.js';
|
|
41
42
|
export { createSessionEventBridge, resolveAuditLevel, resolveSessionLoggingConfig, type SessionEventBridge, type AuditLevel, type SessionEventBridgeOptions, type SessionSamplingOptions, type ToolProgressSamplingOptions, CORE_RECONSTRUCT_EVENTS, STANDARD_AUDIT_EVENTS, } from './session-event-bridge.js';
|
|
42
43
|
export type { SyncConfig, SyncCategory } from '../types/config.js';
|
|
43
44
|
//# sourceMappingURL=index.d.ts.map
|