@skaile/workspaces 1.8.1 → 1.9.1
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 +59 -0
- package/dist/app-sdk/index.js +1 -1
- package/dist/{asset-feeds-Y66NCOQZ.js → asset-feeds-LD6QKJ2R.js} +4 -4
- package/dist/{asset-feeds-Y66NCOQZ.js.map → asset-feeds-LD6QKJ2R.js.map} +1 -1
- package/dist/asset-manager/index.js +1 -1
- package/dist/{chunk-LLNSPJWB.js → chunk-5F3GULZT.js} +3 -3
- package/dist/{chunk-LLNSPJWB.js.map → chunk-5F3GULZT.js.map} +1 -1
- package/dist/{chunk-Y3UCU4ZK.js → chunk-5LPARFB5.js} +2 -2
- package/dist/{chunk-Y3UCU4ZK.js.map → chunk-5LPARFB5.js.map} +1 -1
- package/dist/{chunk-TITPPC54.js → chunk-6Q7CNVU3.js} +3 -3
- package/dist/{chunk-TITPPC54.js.map → chunk-6Q7CNVU3.js.map} +1 -1
- package/dist/{chunk-PP2LOT4W.js → chunk-A2CDJRRH.js} +3 -3
- package/dist/{chunk-PP2LOT4W.js.map → chunk-A2CDJRRH.js.map} +1 -1
- package/dist/{chunk-FK2L3MTF.js → chunk-HGLQYLZB.js} +336 -245
- package/dist/chunk-HGLQYLZB.js.map +1 -0
- package/dist/{chunk-VBRXFLIP.js → chunk-JCKGYBWY.js} +24 -16
- package/dist/chunk-JCKGYBWY.js.map +1 -0
- package/dist/{chunk-O3D4KYFG.js → chunk-JPKWPX5Q.js} +3 -3
- package/dist/{chunk-O3D4KYFG.js.map → chunk-JPKWPX5Q.js.map} +1 -1
- package/dist/{chunk-THJZ3JZE.js → chunk-MBGSJM7H.js} +6 -6
- package/dist/{chunk-THJZ3JZE.js.map → chunk-MBGSJM7H.js.map} +1 -1
- package/dist/{chunk-UPZGQZEJ.js → chunk-MW7GNYRT.js} +3 -3
- package/dist/{chunk-UPZGQZEJ.js.map → chunk-MW7GNYRT.js.map} +1 -1
- package/dist/{chunk-34U5UC6G.js → chunk-SBU73P7R.js} +6 -6
- package/dist/{chunk-34U5UC6G.js.map → chunk-SBU73P7R.js.map} +1 -1
- package/dist/{chunk-35OWUKOD.js → chunk-VWSR6K7C.js} +2 -2
- package/dist/{chunk-35OWUKOD.js.map → chunk-VWSR6K7C.js.map} +1 -1
- package/dist/{chunk-PK7Q7MC7.js → chunk-XJOPAGZX.js} +4 -4
- package/dist/{chunk-PK7Q7MC7.js.map → chunk-XJOPAGZX.js.map} +1 -1
- package/dist/cli/index.js +25 -25
- package/dist/connectors/index.js +1 -1
- package/dist/connectors/src/credential-helper-script.d.ts +8 -5
- package/dist/connectors/src/credential-helper-script.d.ts.map +1 -1
- package/dist/connectors/src/managed-gitconfig.d.ts +4 -2
- package/dist/connectors/src/managed-gitconfig.d.ts.map +1 -1
- package/dist/{ensure-sources-NXBYK5GP.js → ensure-sources-S6QBARWF.js} +4 -4
- package/dist/{ensure-sources-NXBYK5GP.js.map → ensure-sources-S6QBARWF.js.map} +1 -1
- package/dist/factory-assets/connectors/box.js +1 -1
- package/dist/factory-assets/connectors/deploy.js +1 -1
- package/dist/factory-assets/connectors/devserver.js +1 -1
- package/dist/factory-assets/connectors/flow/adapter.d.ts +3 -2
- package/dist/factory-assets/connectors/flow/adapter.d.ts.map +1 -1
- package/dist/factory-assets/connectors/flow/adapter.js +1 -1
- package/dist/factory-assets/connectors/flow/run-flow.js +2 -2
- package/dist/factory-assets/connectors/flow.js +1 -1
- package/dist/factory-assets/connectors/git/driver.d.ts.map +1 -1
- package/dist/factory-assets/connectors/git.js +1 -1
- package/dist/factory-assets/connectors/gmail.js +1 -1
- package/dist/factory-assets/connectors/googledrive.js +1 -1
- package/dist/factory-assets/connectors/local.js +1 -1
- package/dist/factory-assets/connectors/mattermost.js +1 -1
- package/dist/factory-assets/connectors/memory.js +1 -1
- package/dist/factory-assets/connectors/minio.js +1 -1
- package/dist/factory-assets/connectors/postgres.js +1 -1
- package/dist/factory-assets/connectors/s3.js +1 -1
- package/dist/factory-assets/connectors/sharepoint.js +1 -1
- package/dist/factory-assets/connectors/sqlite.js +1 -1
- package/dist/factory-assets/connectors/static-server.js +1 -1
- package/dist/factory-assets/connectors/tunnel.js +1 -1
- package/dist/factory-assets/connectors/webdav.js +1 -1
- package/dist/factory-assets/connectors/xstate-store.js +1 -1
- package/dist/factory-assets/connectors/xstate.js +1 -1
- package/dist/{helpers-DN4MWOHB.js → helpers-ZZZY7HUJ.js} +4 -4
- package/dist/{helpers-DN4MWOHB.js.map → helpers-ZZZY7HUJ.js.map} +1 -1
- package/dist/{library-publish-TPWFSO3Q.js → library-publish-NCMIFF3V.js} +6 -6
- package/dist/{library-publish-TPWFSO3Q.js.map → library-publish-NCMIFF3V.js.map} +1 -1
- package/dist/{open-library-ST2VFQTK.js → open-library-VFS6WIO7.js} +5 -5
- package/dist/{open-library-ST2VFQTK.js.map → open-library-VFS6WIO7.js.map} +1 -1
- package/dist/{project-4M6QXHCH.js → project-SC7TVEQ6.js} +5 -5
- package/dist/{project-4M6QXHCH.js.map → project-SC7TVEQ6.js.map} +1 -1
- package/dist/runner/index.js +4 -4
- package/dist/runner/src/serve.d.ts +67 -4
- package/dist/runner/src/serve.d.ts.map +1 -1
- package/dist/runner/src/session-capability-wiring.d.ts +49 -0
- package/dist/runner/src/session-capability-wiring.d.ts.map +1 -0
- package/dist/runner/src/session-resource-handlers.d.ts +1 -2
- package/dist/runner/src/session-resource-handlers.d.ts.map +1 -1
- package/dist/sdk/asset-manager.js +1 -1
- package/dist/sdk/index.js +4 -4
- package/dist/sdk/runner.js +4 -4
- package/dist/sdk/session.js +2 -2
- package/dist/sdk/types.js +1 -1
- package/dist/session/index.js +2 -2
- package/dist/{source-KUWAEJOO.js → source-Z5HNLF6J.js} +6 -6
- package/dist/{source-KUWAEJOO.js.map → source-Z5HNLF6J.js.map} +1 -1
- package/dist/{source-manifest-publish-FTSKRYPI.js → source-manifest-publish-FA2KLZJ6.js} +7 -7
- package/dist/{source-manifest-publish-FTSKRYPI.js.map → source-manifest-publish-FA2KLZJ6.js.map} +1 -1
- package/dist/tui/index.js +4 -4
- package/dist/types/index.js +1 -1
- package/dist/types/src/flow.d.ts +26 -28
- package/dist/types/src/flow.d.ts.map +1 -1
- package/dist/types/src/index.d.ts +1 -1
- package/dist/types/src/index.d.ts.map +1 -1
- package/dist/types/src/lifecycle.d.ts +0 -8
- package/dist/types/src/lifecycle.d.ts.map +1 -1
- package/dist/types/src/version.d.ts +17 -1
- package/dist/types/src/version.d.ts.map +1 -1
- package/dist/workspace-plugin/index.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-FK2L3MTF.js.map +0 -1
- package/dist/chunk-VBRXFLIP.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../types/src/mentions.ts","../types/src/reactions.ts","../types/src/capabilities.ts","../types/src/version.ts"],"names":[],"mappings":";AAmBO,IAAM,iBAAiB,CAAC,OAAA,EAAS,QAAA,EAAU,aAAA,EAAe,QAAQ,KAAK;;;ACevE,IAAM,eAAA,GAAkB;AAAA,EAC7B,WAAA;AAAA,EACA,WAAA;AAAA,EACA,QAAA;AAAA,EACA,cAAA;AAAA,EACA,WAAA;AAAA,EACA,WAAA;AAAA,EACA,WAAA;AAAA,EACA;AACF;;;AC8LO,SAAS,mBAAmB,GAAA,EAA0C;AAC3E,EAAA,OAAO,IAAI,MAAA,KAAW,MAAA;AACxB;AAsCO,SAAS,gBAAgB,GAAA,EAA0B;AACxD,EAAA,IAAI,GAAA,CAAI,aAAa,MAAA,EAAW;AAC9B,IAAA,OAAO,GAAA,CAAI,QAAA,CAAS,QAAA,CAAS,MAAM,CAAA;AAAA,EACrC;AACA,EAAA,IAAI,GAAA,CAAI,kBAAkB,MAAA,EAAW;AACnC,IAAA,OAAO,GAAA,CAAI,aAAA;AAAA,EACb;AACA,EAAA,QAAQ,GAAA,CAAI,OAAO,IAAA;AAAM,IACvB,KAAK,WAAA;AAAA,IAC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A8C,CAAA;AAAA,EAC9F;AACA,EAAA,OAAO,EAAE,KAAA,EAAO,KAAA,EAAO,KAAA,EAAM;AAC/B;AAiBO,SAAS,cAAc,CAAA,EAA4B;AACxD,EAAA,OAAO,CAAA,EAAG,EAAE,KAAK,CAAA,CAAA,EAAI,EAAE,KAAK,CAAA,CAAA,EAAI,EAAE,KAAK,CAAA,CAAA;AACzC","file":"chunk-PK7Q7MC7.js","sourcesContent":["/**\n * Mentions — types for @-mention support in session messages.\n *\n * A Mention records who was addressed in a message, whether a specific user\n * or a well-known group. Group mentions carry a resolved array of user IDs\n * so consumers can perform membership checks without the resolver.\n */\n\n// ---------------------------------------------------------------------------\n// Groups\n// ---------------------------------------------------------------------------\n\n/**\n * Well-known group mention targets as a `const` array.\n *\n * Use this for validation or exhaustive checks against `MentionGroup`.\n *\n * @docLink packages/types/messages#mention\n */\nexport const MENTION_GROUPS = [\"agent\", \"humans\", \"humans_here\", \"here\", \"all\"] as const;\n\n/**\n * A well-known group that can be `@`-mentioned: `'agent' | 'humans' | 'humans_here' | 'here' | 'all'`.\n *\n * @docLink packages/types/messages#mention\n */\nexport type MentionGroup = (typeof MENTION_GROUPS)[number];\n\n// ---------------------------------------------------------------------------\n// Mention discriminated union\n// ---------------------------------------------------------------------------\n\n/**\n * A parsed `@`-mention in a session message. Records who was addressed — either a\n * specific user or a well-known group — along with the source text position.\n *\n * Group mentions carry a resolved array of user IDs so consumers can perform\n * membership checks without needing the resolver.\n *\n * @docLink packages/types/messages#mention\n */\nexport type Mention =\n | {\n type: \"user\";\n userId: string;\n name: string;\n /** Position of the `@` character in the source text. */\n offset: number;\n /** Length of the full `@token` string including the `@`. */\n length: number;\n }\n | {\n type: \"group\";\n group: MentionGroup;\n /** User IDs resolved at parse time (e.g. all online users for `@here`). */\n resolved: string[];\n /** Position of the `@` character in the source text. */\n offset: number;\n /** Length of the full `@token` string including the `@`. */\n length: number;\n }\n | {\n type: \"custom\";\n /** Consumer-defined mention kind, e.g. \"assistant\". */\n kind: string;\n /** User IDs this mention resolves to (so isMentioned works); may be empty. */\n resolved: string[];\n /** Optional consumer payload, e.g. { sessionId, ownerId }. */\n data?: Record<string, unknown>;\n /** Position of the `@` character in the source text. */\n offset: number;\n /** Length of the full `@token` string including the `@`. */\n length: number;\n };\n","/**\n * Reactions -- emoji reactions on session messages.\n *\n * Any session participant (user or agent) can react to any message.\n * Reactions are persisted in a dedicated DB model and broadcast as\n * transient events for real-time updates.\n */\n\n/**\n * A single emoji reaction on a message, set by any session participant (user or agent).\n *\n * Reactions are persisted in a dedicated DB model and broadcast as transient events\n * for real-time updates.\n *\n * @docLink packages/types/messages#reaction\n */\nexport type Reaction = {\n /** Unicode emoji character (e.g. \"thumbs up\", not \":thumbsup:\"). */\n emoji: string;\n /** ID of the user (or \"agent\" for agent reactions). */\n userId: string;\n /** Display name at reaction time (avoids extra lookups for tooltip rendering). */\n userName: string;\n /** Unix epoch milliseconds. */\n timestamp: number;\n};\n\n/**\n * Quick-access emojis shown in the reaction bar picker.\n *\n * An `as const` array of eight Unicode emoji characters in display order.\n *\n * @docLink packages/types/messages#reaction\n */\nexport const QUICK_REACTIONS = [\n \"\\u{1F44D}\",\n \"\\u{1F440}\",\n \"\\u2705\",\n \"\\u2764\\uFE0F\",\n \"\\u{1F914}\",\n \"\\u{1FAE1}\",\n \"\\u{1F44F}\",\n \"\\u{1F389}\",\n] as const;\n","/**\n * Capability layer — Protocol v2's unified registry of LLM-invokable entry points.\n *\n * A {@link Capability} is a named, schema-typed entry point that the LLM can call\n * during a session. Capabilities are registered into a per-session\n * registry by either side (host platform via `side: 'client'` or runtime via\n * `side: 'agent'`) and routed by the bridge at invocation time.\n *\n * This module defines the wire types only; the runtime registry, the\n * `defineCapability` helper, and the per-handler logger live in\n * `@skaile/workspaces/runner`.\n *\n * @see {@link MessageV2} envelope that carries capability commands and events\n * @see {@link ProtocolVersion} for the version contract\n *\n * @category Capabilities\n * @since 2.0.0\n */\n\n// ---------------------------------------------------------------------------\n// Capability shape\n// ---------------------------------------------------------------------------\n\n/**\n * Visibility scope for a capability. Determines which surfaces the capability\n * appears on and which callers can invoke it.\n *\n * - `'llm'`: registered as an LLM tool, surfaced in the `<CAPABILITIES>` system\n * prompt section. The agent driver can invoke it.\n * - `'user'`: appears in user-facing surfaces — the command palette (cmdK),\n * debug menus, capability lists.\n * - `'runtime'`: invocable only by trusted runner / platform code paths. Never\n * reaches the LLM tool list. Never reaches the command palette. Used for\n * host RPCs (`host.refresh_credential`, `host.audit`, `host.notify_user`,\n * `host.persist_compaction_attempt`) and runner RPCs (`runner.add_mount`,\n * `runner.set_log_level`, `runner.lifecycle`, ...).\n *\n * Multiple audiences are allowed (e.g. `['llm', 'user']`). The default when\n * {@link Capability.audience} is omitted is `['llm', 'user']`, preserving the\n * v2.x default visibility for capabilities that haven't migrated yet.\n *\n * @category Capabilities\n * @since 3.0.0\n * @docLink packages/types/capabilities#capability-audience\n */\nexport type CapabilityAudience = \"llm\" | \"user\" | \"runtime\";\n\n/**\n * Source of truth for who registered a capability. Used for trust enforcement\n * (the bridge rejects mismatches between registering side and origin kind)\n * and for the `capability:<origin>:<name>` log taxonomy.\n *\n * Variants:\n * - `framework`: built-in (e.g. `__capabilities.list`)\n * - `client`: host platform (e.g. `platform.react`)\n * - `agent`: self-registered by the agent runtime\n * - `flow`: injected by an active flow execution\n * - `skill`: from a skill's MCP surface\n * - `mcp`: from a generic MCP server\n * - `connector`: from a connector (e.g. `postgres.query`)\n * - `mount`: surfaced by a filesystem mount\n * - `app`: from an embedded, agent-controllable app (carries the originating\n * `appId`). Handlers run in the app itself — see {@link Capability.side} `'app'`.\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability-origin\n */\nexport type CapabilityOrigin =\n | { kind: \"framework\" }\n | { kind: \"client\" }\n | { kind: \"agent\" }\n | { kind: \"flow\"; flowId: string }\n | { kind: \"skill\"; skillId: string }\n | { kind: \"mcp\"; serverId: string }\n | { kind: \"connector\"; connectorId: string }\n | { kind: \"mount\"; mountId: string }\n | { kind: \"app\"; appId: string };\n\n/**\n * Render contract for a capability that produces a UI surface when invoked.\n *\n * When the LLM invokes a capability whose `render` is set, the bridge emits\n * a {@link RenderInvokedEvent} carrying the capability name and props. The\n * client renders the configured `source` at the chosen `target`. Clients\n * without a render layer can fall back to the markdown `fallback` template.\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#render-spec\n */\nexport type RenderSpec = {\n /** Where the rendered component lives. */\n source: { kind: \"web-component\"; url: string; tagName: string } | { kind: \"iframe\"; url: string };\n /** Render placements supported by the component. */\n targets: (\"chat\" | \"preview\" | \"modal\" | \"input-extension\")[];\n /** Markdown template with `{{prop}}` placeholders for clients without a render layer. */\n fallback?: string;\n /** True when props may be partial during streaming. */\n streaming?: boolean;\n /** Interaction names the rendered component may fire back as state events. */\n interactions?: string[];\n};\n\n/**\n * A named, schema-typed entry point that the LLM can invoke during a session.\n *\n * Capabilities can be declared statically (via `ConfigureCommand.capabilities`)\n * or dynamically (via {@link CapabilityRegisterCommand} /\n * {@link CapabilityRegisterEvent}). They are cached for replay across\n * subscriber reconnects and session hibernation.\n *\n * @example Defining a client-side fire-and-forget tool (uses the runner's\n * `defineCapability` helper, which serializes a {@link Capability} to the wire):\n * ```ts\n * const reactTool = defineCapability({\n * name: 'platform.react',\n * description: 'Acknowledge a user message with a Unicode emoji.',\n * side: 'client',\n * origin: { kind: 'client' },\n * fireAndForget: true,\n * input: z.object({ emoji: z.string(), targetSeq: z.number().optional() }),\n * handler: async ({ emoji, targetSeq }, ctx) => { ... },\n * });\n * ```\n *\n * @see {@link RenderCapability} for capabilities that render UI components\n * @see {@link CapabilityOrigin} for who-registered-it metadata\n * @see {@link isRenderCapability} for the type-guard\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability\n */\nexport type Capability = {\n /** Unique within a session. Convention: namespaced as `<origin>.<name>` (e.g. `platform.react`, `ui.gif`). */\n name: string;\n /**\n * Human-readable label for user-facing surfaces (cmdK action palette,\n * capability menus, debug panels). Falls back to {@link Capability.name}\n * when omitted. Pure presentation — the LLM sees `name`, not `displayName`.\n */\n displayName?: string;\n /** Human/LLM-readable summary. Shown to the LLM as part of tool registration. */\n description: string;\n /** JSON Schema validating the invocation arguments. Authored as Zod, converted at register time. */\n inputSchema: Record<string, unknown>;\n /** Optional return shape. Omit for fire-and-forget effects. */\n outputSchema?: Record<string, unknown>;\n /** Where the handler runs. `client` = host platform, `agent` = runtime/skill/connector, `app` = embedded app. */\n side: \"client\" | \"agent\" | \"app\";\n /** Discriminated tag identifying who registered the capability. Used for trust enforcement and audit. */\n origin: CapabilityOrigin;\n /** Lifetime: `session` survives the whole session, `turn` is dropped at end-of-turn. */\n scope?: \"session\" | \"turn\";\n /** When true, the bridge auto-resolves with `{}` immediately and runs the handler in the background. */\n fireAndForget?: boolean;\n /** When true, the platform shows a confirm UI before dispatch and waits for {@link CapabilityApproveCommand}. */\n requiresApproval?: boolean;\n /** Documentation hint (not enforced) describing whether this is a side-effect, render, or pure query. */\n kind?: \"effect\" | \"render\" | \"query\";\n /**\n * Whether this capability should be exposed in user-facing surfaces (cmdK\n * action palette, capability menus). When omitted, the consumer applies a\n * default per-origin via {@link isUserInvokable}.\n *\n * - `true`: surface in cmdK and capability menus.\n * - `false`: hide from user surfaces (LLM-only or low-level).\n * - `undefined`: defer to {@link isUserInvokable}'s inference rules.\n *\n * @deprecated Set {@link Capability.audience} instead. `userInvokable` is\n * kept as a read-only shim for v2.x consumers and is honoured by\n * {@link isUserInvokable} when {@link Capability.audience} is absent.\n */\n userInvokable?: boolean;\n /**\n * Audience scoping for this capability. See {@link CapabilityAudience} for\n * the meaning of each value and combinations.\n *\n * When omitted, consumers treat the capability as `['llm', 'user']` (the\n * v2.x default). Host RPCs and runner RPCs MUST set this to `['runtime']`\n * so they never leak to the LLM tool list or the user-facing surfaces.\n *\n * @category Capabilities\n * @since 3.0.0\n */\n audience?: CapabilityAudience[];\n /** Appended to the system prompt's `<CAPABILITIES>` section. Use for usage hints the LLM should always see. */\n promptFragment?: string;\n /**\n * Per-capability override for how long the runner waits on the\n * `capability_result` round-trip before timing out. When omitted the\n * runner applies its default (`DEFAULT_CAPABILITY_CALL_TIMEOUT_MS`, 60s).\n *\n * Set this for capabilities that legitimately block far longer than a\n * normal tool call — e.g. `platform.ask_session` suspends the caller's\n * turn until a peer session answers, which can take minutes.\n *\n * @category Capabilities\n * @since 3.3.0\n */\n callTimeoutMs?: number;\n /** Present iff this is a render capability — see {@link RenderCapability}. */\n render?: RenderSpec;\n};\n\n/**\n * A {@link Capability} that produces a UI surface when invoked. The narrowed\n * type guarantees `render` is set, which simplifies frontend lookup.\n *\n * @see {@link isRenderCapability}\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#render-capability\n */\nexport type RenderCapability = Capability & { render: NonNullable<Capability[\"render\"]> };\n\n/**\n * Type-guard for {@link RenderCapability}. Use after {@link Capability}\n * lookup to narrow the type before reading `render`.\n *\n * @example\n * ```ts\n * for (const cap of registry.list()) {\n * if (isRenderCapability(cap)) console.log(cap.render.targets);\n * }\n * ```\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#is-render-capability\n */\nexport function isRenderCapability(cap: Capability): cap is RenderCapability {\n return cap.render !== undefined;\n}\n\n/**\n * Decide whether a capability should be surfaced in user-facing actions\n * (cmdK action palette, capability menus).\n *\n * Resolution order (first match wins):\n *\n * 1. {@link Capability.audience} is set — return `audience.includes('user')`.\n * Capabilities scoped to `'runtime'` only never appear in user surfaces.\n * 2. {@link Capability.userInvokable} is set (v2.x shim) — return that value.\n * 3. Default per-origin inference table below.\n *\n * Default-inference rules (when both `audience` and `userInvokable` are\n * omitted):\n * | Origin | Default |\n * | ------------ | ---------------------------------------------------------------------- |\n * | `framework` | `false` (LLM discovery surfaces, e.g. `__capabilities.list`) |\n * | `client` | `false` (platform ack tools — `platform.react`, `platform.pass`) |\n * | `agent` | `false` (agent-defined; assume internal unless flagged) |\n * | `flow` | `false` (per-cap opt-in) |\n * | `connector` | `false` (low-level FS / data ops) |\n * | `mount` | `false` (low-level FS ops) |\n * | `app` | `false` (LLM-only; app authors opt in via `audience: ['llm','user']`) |\n * | `mcp` | `true` if `kind === 'effect'`, else `false` |\n * | `skill` | `true` if `kind` ∈ {`effect`, `render`}, else `false` |\n *\n * @example\n * ```ts\n * for (const cap of capabilities.values()) {\n * if (isUserInvokable(cap)) registerCommandPaletteAction(cap);\n * }\n * ```\n *\n * @category Capabilities\n * @since 2.1.0\n * @docLink packages/types/capabilities#is-user-invokable\n */\nexport function isUserInvokable(cap: Capability): boolean {\n if (cap.audience !== undefined) {\n return cap.audience.includes(\"user\");\n }\n if (cap.userInvokable !== undefined) {\n return cap.userInvokable;\n }\n switch (cap.origin.kind) {\n case \"framework\":\n case \"client\":\n case \"agent\":\n case \"flow\":\n case \"connector\":\n case \"mount\":\n case \"app\":\n return false;\n case \"mcp\":\n return cap.kind === \"effect\";\n case \"skill\":\n return cap.kind === \"effect\" || cap.kind === \"render\";\n default:\n return false;\n }\n}\n\n// ---------------------------------------------------------------------------\n// Capability commands (client → agent)\n// ---------------------------------------------------------------------------\n\n/**\n * Register one or more capabilities mid-session (client → agent).\n *\n * The platform sends this when a new client-side tool becomes available\n * after `configure` has already returned (e.g. a user installs a new\n * extension during the session).\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability-register-command\n */\nexport type CapabilityRegisterCommand = {\n type: \"capability_register\";\n capabilities: Capability[];\n};\n\n/**\n * Deregister capabilities by name (client → agent). Names that are not\n * currently registered are ignored silently.\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability-deregister-command\n */\nexport type CapabilityDeregisterCommand = {\n type: \"capability_deregister\";\n names: string[];\n};\n\n/**\n * Return the result of a previously {@link CapabilityInvokedEvent | invoked} client-side\n * capability (client → agent). Bridges that registered the capability with\n * `fireAndForget: true` MAY skip this command; the bridge auto-resolves with `{}`.\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability-result-command\n */\nexport type CapabilityResultCommand = {\n type: \"capability_result\";\n /** Correlation token matching the {@link CapabilityInvokedEvent.callId}. */\n callId: string;\n /** Successful result payload, or an error envelope. */\n result: unknown | { error: string };\n};\n\n/**\n * Approve or reject a capability call that was invoked with\n * `requiresApproval: true` (client → agent). The platform shows a confirm\n * UI and forwards the user's decision via this command.\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability-approve-command\n */\nexport type CapabilityApproveCommand = {\n type: \"capability_approve\";\n /** Correlation token matching the {@link CapabilityInvokedEvent.callId}. */\n callId: string;\n /** User's decision. */\n decision: \"approved\" | \"rejected\";\n /** Optional rationale stored alongside the decision for audit. */\n feedback?: string;\n /** User ID of the decider (informational — framework enforces no policy). */\n decidedBy: string;\n};\n\n// ---------------------------------------------------------------------------\n// Capability events (agent → client)\n// ---------------------------------------------------------------------------\n\n/**\n * Register one or more capabilities mid-session (agent → client). Mirrors\n * {@link CapabilityRegisterCommand} for the agent-initiated direction; used\n * when the runtime adds a capability after `configure` (e.g. when a flow\n * starts and injects flow-scoped tools).\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability-register-event\n */\nexport type CapabilityRegisterEvent = {\n type: \"capability_register\";\n capabilities: Capability[];\n};\n\n/**\n * Deregister capabilities by name (agent → client).\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability-deregister-event\n */\nexport type CapabilityDeregisterEvent = {\n type: \"capability_deregister\";\n names: string[];\n};\n\n/**\n * Notify the client that a capability has been invoked by the LLM (agent →\n * client). For client-side capabilities the platform's handler runs in\n * response to this event and replies with {@link CapabilityResultCommand}.\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability-invoked-event\n */\nexport type CapabilityInvokedEvent = {\n type: \"capability_invoked\";\n /** Correlation token for the eventual {@link CapabilityResultCommand}. */\n callId: string;\n /** Name of the invoked {@link Capability}. */\n name: string;\n /** Validated input payload (already conforms to the capability's `inputSchema`). */\n input: unknown;\n /** In v2.0.0 the LLM is the only invoker. */\n invokedBy: \"agent\";\n};\n\n/**\n * Notify the client that a render capability should be drawn (agent →\n * client). Emitted alongside {@link CapabilityInvokedEvent} when the\n * invoked capability's `render` block is populated.\n *\n * Clients without a render layer can fall back to the capability's\n * `render.fallback` markdown template.\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#render-invoked-event\n */\nexport type RenderInvokedEvent = {\n type: \"render_invoked\";\n /** Name of the invoked render capability. */\n capabilityName: string;\n /** Props passed to the rendered component (already conforms to `inputSchema`). */\n props: unknown;\n /** Correlation token shared with the matching {@link CapabilityInvokedEvent}. */\n callId: string;\n};\n","/**\n * Protocol versioning primitives for Skaile Agent Protocol v2.\n *\n * The protocol is versioned by a structured {@link ProtocolVersion} record\n * (`major.minor.patch`). The compatibility rule applied at handshake is\n * **major-equality**: a runner emits {@link IncompatibleProtocolEvent} and\n * shuts down when its declared major does not match the platform's announced\n * major. Minor and patch differences ride through transparently because\n * unknown fields are preserved on round-trip (see `MessageMeta` round-trip\n * contract in `messaging.ts`).\n *\n * @category Protocol\n * @since 2.0.0\n */\n\n/**\n * Structured semantic version triple for the agent protocol.\n *\n * @example\n * ```ts\n * const v: ProtocolVersion = { major: 2, minor: 0, patch: 0 };\n * ```\n *\n * @category Protocol\n * @since 2.0.0\n * @docLink packages/types/protocol-v2#protocol-version\n */\nexport type ProtocolVersion = {\n /** Incremented on breaking wire-format changes (field removed, semantics changed, required field added). */\n major: number;\n /** Incremented on additive wire-format changes (new optional fields, new event types). */\n minor: number;\n /** Incremented on bug-fix or doc-only changes that do not affect the wire. */\n patch: number;\n};\n\n/**\n * The protocol version the framework currently speaks. Runners and platforms\n * compare this against the peer's announced version at session boot via\n * `SessionInitCommand.protocolVersion`.\n *\n * @example\n * ```ts\n * import { PROTOCOL_VERSION } from '@skaile/workspaces/types';\n * if (cmd.protocolVersion.major !== PROTOCOL_VERSION.major) {\n * emit({ type: 'incompatible_protocol', agentVersion: PROTOCOL_VERSION, platformVersion: cmd.protocolVersion });\n * }\n * ```\n *\n * @category Protocol\n * @since 3.0.0\n *\n * Changed in 3.4.0:\n * Additive embedded-app capability source. `CapabilityOrigin` gains a\n * `{ kind: 'app'; appId: string }` variant and `Capability.side` gains `'app'`\n * (\"the handler runs in the embedded app\"). Both are additive: a peer that does\n * not understand `origin:'app'` / `side:'app'` never produces or routes them, so\n * they ride through transparently under the major-equality rule. No new message\n * types — `capability_register` / `capability_invoked` / `capability_result` /\n * `capability_approve` / `render_invoked` are reused verbatim. Spec:\n * `_devlog/specs/2026-07-07-app-capability-source.md`.\n *\n * Changed in 3.3.0:\n * Additive agent-to-agent (session-to-session) communication extension.\n * `AgentEvent` gains an `a2a_message` variant carrying cross-session messages\n * (`direction`, `peerSessionId`, `peerName`, `exchangeId`, `text`). `Capability`\n * gains an optional `callTimeoutMs?: number` so a long-running capability call\n * (e.g. a 5-minute `platform.ask_session`) can exceed the default capability-call\n * timeout. Both are additive: a peer that does not understand them ignores the\n * event / falls back to the default timeout, so they ride through transparently\n * under the major-equality rule.\n *\n * Changed in 3.2.0:\n * Additive wake-time resume cascade. `AgentReconfigureOptions` gains optional\n * `resumeSessionId` and `expectedCapabilitySignature` fields driving the tier-1\n * native SDK resume path; `AgentEvent` gains `ResumeAttemptedEvent` and\n * `ResumeFailedEvent`. `FinishedEvent` gains optional `customType` /\n * `customData` for capability-routed custom payloads. All additive — clients\n * that omit the resume hint or ignore the new events keep working unchanged.\n *\n * Changed in 3.1.0:\n * Additive cost / token usage extension. `FinishedEvent` gains an optional\n * `tokens?: TokenUsage` field carrying per-turn input / output / cache-read /\n * cache-creation / reasoning token counts. `AgentDriver.getTokenUsage()` is\n * widened to return the same `TokenUsage` shape (existing consumers reading\n * `inputTokens` / `outputTokens` keep working unchanged). Drivers that do not\n * surface token usage continue to return `null` / omit the field.\n *\n * Changed in 3.0.0:\n * Major bump for the deterministic session bootstrap rewrite. `ConfigureCommandV2`,\n * `provision_secrets`, `request_access_token`, `add_resource`, `remove_resource`,\n * `set_log_level`, `state_action`, `lifecycle`, `remount_mount`, `compact`, and\n * `reconfigure_agent` are removed from the `AgentCommand` union. Their semantics\n * are reachable through:\n * - `session_init` (one deterministic envelope at session start that delivers\n * identity, resolved config, pre-minted credentials, secrets, capabilities,\n * shared state, active flows, resume hints, and logging config),\n * - `host.refresh_credential` (capability invocation that replaces the\n * refresh-on-401 path of `request_access_token`), and\n * - `runner.*` capabilities (`runner.add_mount`, `runner.add_connector`,\n * `runner.remove_resource`, `runner.update_credential`, `runner.set_log_level`,\n * `runner.set_state`, `runner.lifecycle`) invoked by the platform via the\n * bidirectional capability registry.\n *\n * Capabilities gain an `audience: ('llm' | 'user' | 'runtime')[]` field that\n * scopes visibility: host RPCs (`host.*`) and runner RPCs (`runner.*`) are\n * `['runtime']` and never reach the LLM tool list or the user-facing command\n * palette. v2.x capabilities without an explicit `audience` default to\n * `['llm', 'user']`, preserving prior behaviour.\n *\n * Spec: `_devlog/specs/2026-05-10-deterministic-session-bootstrap.md`.\n *\n * @docLink packages/types/protocol-v3#protocol-version\n */\nexport const PROTOCOL_VERSION: ProtocolVersion = { major: 3, minor: 4, patch: 0 };\n\n/**\n * String form of {@link PROTOCOL_VERSION}, kept in lock-step. Useful for\n * `package.json` version fields and HTTP `User-Agent` strings.\n *\n * @category Protocol\n * @since 3.0.0\n * @docLink packages/types/protocol-v3#protocol-version\n */\nexport const PROTOCOL_VERSION_STRING = \"3.4.0\";\n\n/**\n * Parse a `\"major.minor.patch\"` string into a {@link ProtocolVersion}.\n *\n * @param s - the version string to parse, exactly three dot-separated non-negative integers\n * @returns the parsed protocol version\n * @throws {Error} if the string is not exactly three dot-separated non-negative integers\n *\n * @example\n * ```ts\n * parseVersion('2.0.0'); // { major: 2, minor: 0, patch: 0 }\n * parseVersion('2.1'); // throws\n * ```\n *\n * @category Protocol\n * @since 2.0.0\n * @docLink packages/types/protocol-v2#parse-version\n */\nexport function parseVersion(s: string): ProtocolVersion {\n const parts = s.split(\".\");\n if (parts.length !== 3) {\n throw new Error(`Invalid ProtocolVersion: \"${s}\" (expected \"major.minor.patch\")`);\n }\n const [maj, min, pat] = parts;\n const major = Number(maj);\n const minor = Number(min);\n const patch = Number(pat);\n if (\n !Number.isInteger(major) ||\n !Number.isInteger(minor) ||\n !Number.isInteger(patch) ||\n major < 0 ||\n minor < 0 ||\n patch < 0\n ) {\n throw new Error(`Invalid ProtocolVersion: \"${s}\" (each part must be a non-negative integer)`);\n }\n return { major, minor, patch };\n}\n\n/**\n * Format a {@link ProtocolVersion} record into its `\"major.minor.patch\"` string form.\n *\n * @param v - the protocol version to format\n * @returns the dot-joined string form\n *\n * @example\n * ```ts\n * formatVersion({ major: 2, minor: 0, patch: 0 }); // '2.0.0'\n * ```\n *\n * @category Protocol\n * @since 2.0.0\n * @docLink packages/types/protocol-v2#format-version\n */\nexport function formatVersion(v: ProtocolVersion): string {\n return `${v.major}.${v.minor}.${v.patch}`;\n}\n"]}
|
|
1
|
+
{"version":3,"sources":["../types/src/mentions.ts","../types/src/reactions.ts","../types/src/capabilities.ts","../types/src/version.ts"],"names":[],"mappings":";AAmBO,IAAM,iBAAiB,CAAC,OAAA,EAAS,QAAA,EAAU,aAAA,EAAe,QAAQ,KAAK;;;ACevE,IAAM,eAAA,GAAkB;AAAA,EAC7B,WAAA;AAAA,EACA,WAAA;AAAA,EACA,QAAA;AAAA,EACA,cAAA;AAAA,EACA,WAAA;AAAA,EACA,WAAA;AAAA,EACA,WAAA;AAAA,EACA;AACF;;;AC8LO,SAAS,mBAAmB,GAAA,EAA0C;AAC3E,EAAA,OAAO,IAAI,MAAA,KAAW,MAAA;AACxB;AAsCO,SAAS,gBAAgB,GAAA,EAA0B;AACxD,EAAA,IAAI,GAAA,CAAI,aAAa,MAAA,EAAW;AAC9B,IAAA,OAAO,GAAA,CAAI,QA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,CAAO,UAAU,KAAK,CAAA,IACvB,CAAC,MAAA,CAAO,SAAA,CAAU,KAAK,CAAA,IACvB,KAAA,GAAQ,KACR,KAAA,GAAQ,CAAA,IACR,QAAQ,CAAA,EACR;AACA,IAAA,MAAM,IAAI,KAAA,CAAM,CAAA,0BAAA,EAA6B,CAAC,CAAA,4CAAA,CAA8C,CAAA;AAAA,EAC9F;AACA,EAAA,OAAO,EAAE,KAAA,EAAO,KAAA,EAAO,KAAA,EAAM;AAC/B;AAiBO,SAAS,cAAc,CAAA,EAA4B;AACxD,EAAA,OAAO,CAAA,EAAG,EAAE,KAAK,CAAA,CAAA,EAAI,EAAE,KAAK,CAAA,CAAA,EAAI,EAAE,KAAK,CAAA,CAAA;AACzC","file":"chunk-XJOPAGZX.js","sourcesContent":["/**\n * Mentions — types for @-mention support in session messages.\n *\n * A Mention records who was addressed in a message, whether a specific user\n * or a well-known group. Group mentions carry a resolved array of user IDs\n * so consumers can perform membership checks without the resolver.\n */\n\n// ---------------------------------------------------------------------------\n// Groups\n// ---------------------------------------------------------------------------\n\n/**\n * Well-known group mention targets as a `const` array.\n *\n * Use this for validation or exhaustive checks against `MentionGroup`.\n *\n * @docLink packages/types/messages#mention\n */\nexport const MENTION_GROUPS = [\"agent\", \"humans\", \"humans_here\", \"here\", \"all\"] as const;\n\n/**\n * A well-known group that can be `@`-mentioned: `'agent' | 'humans' | 'humans_here' | 'here' | 'all'`.\n *\n * @docLink packages/types/messages#mention\n */\nexport type MentionGroup = (typeof MENTION_GROUPS)[number];\n\n// ---------------------------------------------------------------------------\n// Mention discriminated union\n// ---------------------------------------------------------------------------\n\n/**\n * A parsed `@`-mention in a session message. Records who was addressed — either a\n * specific user or a well-known group — along with the source text position.\n *\n * Group mentions carry a resolved array of user IDs so consumers can perform\n * membership checks without needing the resolver.\n *\n * @docLink packages/types/messages#mention\n */\nexport type Mention =\n | {\n type: \"user\";\n userId: string;\n name: string;\n /** Position of the `@` character in the source text. */\n offset: number;\n /** Length of the full `@token` string including the `@`. */\n length: number;\n }\n | {\n type: \"group\";\n group: MentionGroup;\n /** User IDs resolved at parse time (e.g. all online users for `@here`). */\n resolved: string[];\n /** Position of the `@` character in the source text. */\n offset: number;\n /** Length of the full `@token` string including the `@`. */\n length: number;\n }\n | {\n type: \"custom\";\n /** Consumer-defined mention kind, e.g. \"assistant\". */\n kind: string;\n /** User IDs this mention resolves to (so isMentioned works); may be empty. */\n resolved: string[];\n /** Optional consumer payload, e.g. { sessionId, ownerId }. */\n data?: Record<string, unknown>;\n /** Position of the `@` character in the source text. */\n offset: number;\n /** Length of the full `@token` string including the `@`. */\n length: number;\n };\n","/**\n * Reactions -- emoji reactions on session messages.\n *\n * Any session participant (user or agent) can react to any message.\n * Reactions are persisted in a dedicated DB model and broadcast as\n * transient events for real-time updates.\n */\n\n/**\n * A single emoji reaction on a message, set by any session participant (user or agent).\n *\n * Reactions are persisted in a dedicated DB model and broadcast as transient events\n * for real-time updates.\n *\n * @docLink packages/types/messages#reaction\n */\nexport type Reaction = {\n /** Unicode emoji character (e.g. \"thumbs up\", not \":thumbsup:\"). */\n emoji: string;\n /** ID of the user (or \"agent\" for agent reactions). */\n userId: string;\n /** Display name at reaction time (avoids extra lookups for tooltip rendering). */\n userName: string;\n /** Unix epoch milliseconds. */\n timestamp: number;\n};\n\n/**\n * Quick-access emojis shown in the reaction bar picker.\n *\n * An `as const` array of eight Unicode emoji characters in display order.\n *\n * @docLink packages/types/messages#reaction\n */\nexport const QUICK_REACTIONS = [\n \"\\u{1F44D}\",\n \"\\u{1F440}\",\n \"\\u2705\",\n \"\\u2764\\uFE0F\",\n \"\\u{1F914}\",\n \"\\u{1FAE1}\",\n \"\\u{1F44F}\",\n \"\\u{1F389}\",\n] as const;\n","/**\n * Capability layer — Protocol v2's unified registry of LLM-invokable entry points.\n *\n * A {@link Capability} is a named, schema-typed entry point that the LLM can call\n * during a session. Capabilities are registered into a per-session\n * registry by either side (host platform via `side: 'client'` or runtime via\n * `side: 'agent'`) and routed by the bridge at invocation time.\n *\n * This module defines the wire types only; the runtime registry, the\n * `defineCapability` helper, and the per-handler logger live in\n * `@skaile/workspaces/runner`.\n *\n * @see {@link MessageV2} envelope that carries capability commands and events\n * @see {@link ProtocolVersion} for the version contract\n *\n * @category Capabilities\n * @since 2.0.0\n */\n\n// ---------------------------------------------------------------------------\n// Capability shape\n// ---------------------------------------------------------------------------\n\n/**\n * Visibility scope for a capability. Determines which surfaces the capability\n * appears on and which callers can invoke it.\n *\n * - `'llm'`: registered as an LLM tool, surfaced in the `<CAPABILITIES>` system\n * prompt section. The agent driver can invoke it.\n * - `'user'`: appears in user-facing surfaces — the command palette (cmdK),\n * debug menus, capability lists.\n * - `'runtime'`: invocable only by trusted runner / platform code paths. Never\n * reaches the LLM tool list. Never reaches the command palette. Used for\n * host RPCs (`host.refresh_credential`, `host.audit`, `host.notify_user`,\n * `host.persist_compaction_attempt`) and runner RPCs (`runner.add_mount`,\n * `runner.set_log_level`, `runner.lifecycle`, ...).\n *\n * Multiple audiences are allowed (e.g. `['llm', 'user']`). The default when\n * {@link Capability.audience} is omitted is `['llm', 'user']`, preserving the\n * v2.x default visibility for capabilities that haven't migrated yet.\n *\n * @category Capabilities\n * @since 3.0.0\n * @docLink packages/types/capabilities#capability-audience\n */\nexport type CapabilityAudience = \"llm\" | \"user\" | \"runtime\";\n\n/**\n * Source of truth for who registered a capability. Used for trust enforcement\n * (the bridge rejects mismatches between registering side and origin kind)\n * and for the `capability:<origin>:<name>` log taxonomy.\n *\n * Variants:\n * - `framework`: built-in (e.g. `__capabilities.list`)\n * - `client`: host platform (e.g. `platform.react`)\n * - `agent`: self-registered by the agent runtime\n * - `flow`: injected by an active flow execution\n * - `skill`: from a skill's MCP surface\n * - `mcp`: from a generic MCP server\n * - `connector`: from a connector (e.g. `postgres.query`)\n * - `mount`: surfaced by a filesystem mount\n * - `app`: from an embedded, agent-controllable app (carries the originating\n * `appId`). Handlers run in the app itself — see {@link Capability.side} `'app'`.\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability-origin\n */\nexport type CapabilityOrigin =\n | { kind: \"framework\" }\n | { kind: \"client\" }\n | { kind: \"agent\" }\n | { kind: \"flow\"; flowId: string }\n | { kind: \"skill\"; skillId: string }\n | { kind: \"mcp\"; serverId: string }\n | { kind: \"connector\"; connectorId: string }\n | { kind: \"mount\"; mountId: string }\n | { kind: \"app\"; appId: string };\n\n/**\n * Render contract for a capability that produces a UI surface when invoked.\n *\n * When the LLM invokes a capability whose `render` is set, the bridge emits\n * a {@link RenderInvokedEvent} carrying the capability name and props. The\n * client renders the configured `source` at the chosen `target`. Clients\n * without a render layer can fall back to the markdown `fallback` template.\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#render-spec\n */\nexport type RenderSpec = {\n /** Where the rendered component lives. */\n source: { kind: \"web-component\"; url: string; tagName: string } | { kind: \"iframe\"; url: string };\n /** Render placements supported by the component. */\n targets: (\"chat\" | \"preview\" | \"modal\" | \"input-extension\")[];\n /** Markdown template with `{{prop}}` placeholders for clients without a render layer. */\n fallback?: string;\n /** True when props may be partial during streaming. */\n streaming?: boolean;\n /** Interaction names the rendered component may fire back as state events. */\n interactions?: string[];\n};\n\n/**\n * A named, schema-typed entry point that the LLM can invoke during a session.\n *\n * Capabilities can be declared statically (via `ConfigureCommand.capabilities`)\n * or dynamically (via {@link CapabilityRegisterCommand} /\n * {@link CapabilityRegisterEvent}). They are cached for replay across\n * subscriber reconnects and session hibernation.\n *\n * @example Defining a client-side fire-and-forget tool (uses the runner's\n * `defineCapability` helper, which serializes a {@link Capability} to the wire):\n * ```ts\n * const reactTool = defineCapability({\n * name: 'platform.react',\n * description: 'Acknowledge a user message with a Unicode emoji.',\n * side: 'client',\n * origin: { kind: 'client' },\n * fireAndForget: true,\n * input: z.object({ emoji: z.string(), targetSeq: z.number().optional() }),\n * handler: async ({ emoji, targetSeq }, ctx) => { ... },\n * });\n * ```\n *\n * @see {@link RenderCapability} for capabilities that render UI components\n * @see {@link CapabilityOrigin} for who-registered-it metadata\n * @see {@link isRenderCapability} for the type-guard\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability\n */\nexport type Capability = {\n /** Unique within a session. Convention: namespaced as `<origin>.<name>` (e.g. `platform.react`, `ui.gif`). */\n name: string;\n /**\n * Human-readable label for user-facing surfaces (cmdK action palette,\n * capability menus, debug panels). Falls back to {@link Capability.name}\n * when omitted. Pure presentation — the LLM sees `name`, not `displayName`.\n */\n displayName?: string;\n /** Human/LLM-readable summary. Shown to the LLM as part of tool registration. */\n description: string;\n /** JSON Schema validating the invocation arguments. Authored as Zod, converted at register time. */\n inputSchema: Record<string, unknown>;\n /** Optional return shape. Omit for fire-and-forget effects. */\n outputSchema?: Record<string, unknown>;\n /** Where the handler runs. `client` = host platform, `agent` = runtime/skill/connector, `app` = embedded app. */\n side: \"client\" | \"agent\" | \"app\";\n /** Discriminated tag identifying who registered the capability. Used for trust enforcement and audit. */\n origin: CapabilityOrigin;\n /** Lifetime: `session` survives the whole session, `turn` is dropped at end-of-turn. */\n scope?: \"session\" | \"turn\";\n /** When true, the bridge auto-resolves with `{}` immediately and runs the handler in the background. */\n fireAndForget?: boolean;\n /** When true, the platform shows a confirm UI before dispatch and waits for {@link CapabilityApproveCommand}. */\n requiresApproval?: boolean;\n /** Documentation hint (not enforced) describing whether this is a side-effect, render, or pure query. */\n kind?: \"effect\" | \"render\" | \"query\";\n /**\n * Whether this capability should be exposed in user-facing surfaces (cmdK\n * action palette, capability menus). When omitted, the consumer applies a\n * default per-origin via {@link isUserInvokable}.\n *\n * - `true`: surface in cmdK and capability menus.\n * - `false`: hide from user surfaces (LLM-only or low-level).\n * - `undefined`: defer to {@link isUserInvokable}'s inference rules.\n *\n * @deprecated Set {@link Capability.audience} instead. `userInvokable` is\n * kept as a read-only shim for v2.x consumers and is honoured by\n * {@link isUserInvokable} when {@link Capability.audience} is absent.\n */\n userInvokable?: boolean;\n /**\n * Audience scoping for this capability. See {@link CapabilityAudience} for\n * the meaning of each value and combinations.\n *\n * When omitted, consumers treat the capability as `['llm', 'user']` (the\n * v2.x default). Host RPCs and runner RPCs MUST set this to `['runtime']`\n * so they never leak to the LLM tool list or the user-facing surfaces.\n *\n * @category Capabilities\n * @since 3.0.0\n */\n audience?: CapabilityAudience[];\n /** Appended to the system prompt's `<CAPABILITIES>` section. Use for usage hints the LLM should always see. */\n promptFragment?: string;\n /**\n * Per-capability override for how long the runner waits on the\n * `capability_result` round-trip before timing out. When omitted the\n * runner applies its default (`DEFAULT_CAPABILITY_CALL_TIMEOUT_MS`, 60s).\n *\n * Set this for capabilities that legitimately block far longer than a\n * normal tool call — e.g. `platform.ask_session` suspends the caller's\n * turn until a peer session answers, which can take minutes.\n *\n * @category Capabilities\n * @since 3.3.0\n */\n callTimeoutMs?: number;\n /** Present iff this is a render capability — see {@link RenderCapability}. */\n render?: RenderSpec;\n};\n\n/**\n * A {@link Capability} that produces a UI surface when invoked. The narrowed\n * type guarantees `render` is set, which simplifies frontend lookup.\n *\n * @see {@link isRenderCapability}\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#render-capability\n */\nexport type RenderCapability = Capability & { render: NonNullable<Capability[\"render\"]> };\n\n/**\n * Type-guard for {@link RenderCapability}. Use after {@link Capability}\n * lookup to narrow the type before reading `render`.\n *\n * @example\n * ```ts\n * for (const cap of registry.list()) {\n * if (isRenderCapability(cap)) console.log(cap.render.targets);\n * }\n * ```\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#is-render-capability\n */\nexport function isRenderCapability(cap: Capability): cap is RenderCapability {\n return cap.render !== undefined;\n}\n\n/**\n * Decide whether a capability should be surfaced in user-facing actions\n * (cmdK action palette, capability menus).\n *\n * Resolution order (first match wins):\n *\n * 1. {@link Capability.audience} is set — return `audience.includes('user')`.\n * Capabilities scoped to `'runtime'` only never appear in user surfaces.\n * 2. {@link Capability.userInvokable} is set (v2.x shim) — return that value.\n * 3. Default per-origin inference table below.\n *\n * Default-inference rules (when both `audience` and `userInvokable` are\n * omitted):\n * | Origin | Default |\n * | ------------ | ---------------------------------------------------------------------- |\n * | `framework` | `false` (LLM discovery surfaces, e.g. `__capabilities.list`) |\n * | `client` | `false` (platform ack tools — `platform.react`, `platform.pass`) |\n * | `agent` | `false` (agent-defined; assume internal unless flagged) |\n * | `flow` | `false` (per-cap opt-in) |\n * | `connector` | `false` (low-level FS / data ops) |\n * | `mount` | `false` (low-level FS ops) |\n * | `app` | `false` (LLM-only; app authors opt in via `audience: ['llm','user']`) |\n * | `mcp` | `true` if `kind === 'effect'`, else `false` |\n * | `skill` | `true` if `kind` ∈ {`effect`, `render`}, else `false` |\n *\n * @example\n * ```ts\n * for (const cap of capabilities.values()) {\n * if (isUserInvokable(cap)) registerCommandPaletteAction(cap);\n * }\n * ```\n *\n * @category Capabilities\n * @since 2.1.0\n * @docLink packages/types/capabilities#is-user-invokable\n */\nexport function isUserInvokable(cap: Capability): boolean {\n if (cap.audience !== undefined) {\n return cap.audience.includes(\"user\");\n }\n if (cap.userInvokable !== undefined) {\n return cap.userInvokable;\n }\n switch (cap.origin.kind) {\n case \"framework\":\n case \"client\":\n case \"agent\":\n case \"flow\":\n case \"connector\":\n case \"mount\":\n case \"app\":\n return false;\n case \"mcp\":\n return cap.kind === \"effect\";\n case \"skill\":\n return cap.kind === \"effect\" || cap.kind === \"render\";\n default:\n return false;\n }\n}\n\n// ---------------------------------------------------------------------------\n// Capability commands (client → agent)\n// ---------------------------------------------------------------------------\n\n/**\n * Register one or more capabilities mid-session (client → agent).\n *\n * The platform sends this when a new client-side tool becomes available\n * after `configure` has already returned (e.g. a user installs a new\n * extension during the session).\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability-register-command\n */\nexport type CapabilityRegisterCommand = {\n type: \"capability_register\";\n capabilities: Capability[];\n};\n\n/**\n * Deregister capabilities by name (client → agent). Names that are not\n * currently registered are ignored silently.\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability-deregister-command\n */\nexport type CapabilityDeregisterCommand = {\n type: \"capability_deregister\";\n names: string[];\n};\n\n/**\n * Return the result of a previously {@link CapabilityInvokedEvent | invoked} client-side\n * capability (client → agent). Bridges that registered the capability with\n * `fireAndForget: true` MAY skip this command; the bridge auto-resolves with `{}`.\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability-result-command\n */\nexport type CapabilityResultCommand = {\n type: \"capability_result\";\n /** Correlation token matching the {@link CapabilityInvokedEvent.callId}. */\n callId: string;\n /** Successful result payload, or an error envelope. */\n result: unknown | { error: string };\n};\n\n/**\n * Approve or reject a capability call that was invoked with\n * `requiresApproval: true` (client → agent). The platform shows a confirm\n * UI and forwards the user's decision via this command.\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability-approve-command\n */\nexport type CapabilityApproveCommand = {\n type: \"capability_approve\";\n /** Correlation token matching the {@link CapabilityInvokedEvent.callId}. */\n callId: string;\n /** User's decision. */\n decision: \"approved\" | \"rejected\";\n /** Optional rationale stored alongside the decision for audit. */\n feedback?: string;\n /** User ID of the decider (informational — framework enforces no policy). */\n decidedBy: string;\n};\n\n// ---------------------------------------------------------------------------\n// Capability events (agent → client)\n// ---------------------------------------------------------------------------\n\n/**\n * Register one or more capabilities mid-session (agent → client). Mirrors\n * {@link CapabilityRegisterCommand} for the agent-initiated direction; used\n * when the runtime adds a capability after `configure` (e.g. when a flow\n * starts and injects flow-scoped tools).\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability-register-event\n */\nexport type CapabilityRegisterEvent = {\n type: \"capability_register\";\n capabilities: Capability[];\n};\n\n/**\n * Deregister capabilities by name (agent → client).\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability-deregister-event\n */\nexport type CapabilityDeregisterEvent = {\n type: \"capability_deregister\";\n names: string[];\n};\n\n/**\n * Notify the client that a capability has been invoked by the LLM (agent →\n * client). For client-side capabilities the platform's handler runs in\n * response to this event and replies with {@link CapabilityResultCommand}.\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#capability-invoked-event\n */\nexport type CapabilityInvokedEvent = {\n type: \"capability_invoked\";\n /** Correlation token for the eventual {@link CapabilityResultCommand}. */\n callId: string;\n /** Name of the invoked {@link Capability}. */\n name: string;\n /** Validated input payload (already conforms to the capability's `inputSchema`). */\n input: unknown;\n /** In v2.0.0 the LLM is the only invoker. */\n invokedBy: \"agent\";\n};\n\n/**\n * Notify the client that a render capability should be drawn (agent →\n * client). Emitted alongside {@link CapabilityInvokedEvent} when the\n * invoked capability's `render` block is populated.\n *\n * Clients without a render layer can fall back to the capability's\n * `render.fallback` markdown template.\n *\n * @category Capabilities\n * @since 2.0.0\n * @docLink packages/types/capabilities#render-invoked-event\n */\nexport type RenderInvokedEvent = {\n type: \"render_invoked\";\n /** Name of the invoked render capability. */\n capabilityName: string;\n /** Props passed to the rendered component (already conforms to `inputSchema`). */\n props: unknown;\n /** Correlation token shared with the matching {@link CapabilityInvokedEvent}. */\n callId: string;\n};\n","/**\n * Protocol versioning primitives for Skaile Agent Protocol v2.\n *\n * The protocol is versioned by a structured {@link ProtocolVersion} record\n * (`major.minor.patch`). The compatibility rule applied at handshake is\n * **major-equality**: a runner emits {@link IncompatibleProtocolEvent} and\n * shuts down when its declared major does not match the platform's announced\n * major. Minor and patch differences ride through transparently because\n * unknown fields are preserved on round-trip (see `MessageMeta` round-trip\n * contract in `messaging.ts`).\n *\n * @category Protocol\n * @since 2.0.0\n */\n\n/**\n * Structured semantic version triple for the agent protocol.\n *\n * @example\n * ```ts\n * const v: ProtocolVersion = { major: 2, minor: 0, patch: 0 };\n * ```\n *\n * @category Protocol\n * @since 2.0.0\n * @docLink packages/types/protocol-v2#protocol-version\n */\nexport type ProtocolVersion = {\n /** Incremented on breaking wire-format changes (field removed, semantics changed, required field added). */\n major: number;\n /** Incremented on additive wire-format changes (new optional fields, new event types). */\n minor: number;\n /** Incremented on bug-fix or doc-only changes that do not affect the wire. */\n patch: number;\n};\n\n/**\n * The protocol version the framework currently speaks. Runners and platforms\n * compare this against the peer's announced version at session boot via\n * `SessionInitCommand.protocolVersion`.\n *\n * @example\n * ```ts\n * import { PROTOCOL_VERSION } from '@skaile/workspaces/types';\n * if (cmd.protocolVersion.major !== PROTOCOL_VERSION.major) {\n * emit({ type: 'incompatible_protocol', agentVersion: PROTOCOL_VERSION, platformVersion: cmd.protocolVersion });\n * }\n * ```\n *\n * @category Protocol\n * @since 3.0.0\n *\n * Changed in 3.5.0:\n * Flow-connector host-contract fix (workspaces#379). Three coordinated changes,\n * all additive under the major-equality rule:\n * - `op:\"hydrate\"` on the bare `\"flow\"` connector now auto-creates the\n * `flow:<runId>` connector on a cold container from its `{ state, flow }`\n * payload, so a persisted run rehydrates in one op. A peer that still issues\n * `start` then `hydrate` keeps working unchanged.\n * - The dead `SessionInit.activeFlows` field (never read by the runner) and its\n * `ActiveFlowRehydration` type are removed — wire-compatible (nothing produced\n * or consumed them) but source-breaking for typed hosts, hence the bump.\n * - Malformed / conflicting flow `start` and `hydrate` payloads now fail loudly\n * (warn with a reason) instead of silently falling through.\n * Because the handshake compares only `major`, a 3.4 host and a 3.5 runner\n * interoperate: the auto-create path is opt-in on the payload the host sends, and\n * the removed field was already inert. Spec: `runner/MIGRATION-flow-connector.md`.\n *\n * Changed in 3.4.0:\n * Additive embedded-app capability source. `CapabilityOrigin` gains a\n * `{ kind: 'app'; appId: string }` variant and `Capability.side` gains `'app'`\n * (\"the handler runs in the embedded app\"). Both are additive: a peer that does\n * not understand `origin:'app'` / `side:'app'` never produces or routes them, so\n * they ride through transparently under the major-equality rule. No new message\n * types — `capability_register` / `capability_invoked` / `capability_result` /\n * `capability_approve` / `render_invoked` are reused verbatim. Spec:\n * `_devlog/specs/2026-07-07-app-capability-source.md`.\n *\n * Changed in 3.3.0:\n * Additive agent-to-agent (session-to-session) communication extension.\n * `AgentEvent` gains an `a2a_message` variant carrying cross-session messages\n * (`direction`, `peerSessionId`, `peerName`, `exchangeId`, `text`). `Capability`\n * gains an optional `callTimeoutMs?: number` so a long-running capability call\n * (e.g. a 5-minute `platform.ask_session`) can exceed the default capability-call\n * timeout. Both are additive: a peer that does not understand them ignores the\n * event / falls back to the default timeout, so they ride through transparently\n * under the major-equality rule.\n *\n * Changed in 3.2.0:\n * Additive wake-time resume cascade. `AgentReconfigureOptions` gains optional\n * `resumeSessionId` and `expectedCapabilitySignature` fields driving the tier-1\n * native SDK resume path; `AgentEvent` gains `ResumeAttemptedEvent` and\n * `ResumeFailedEvent`. `FinishedEvent` gains optional `customType` /\n * `customData` for capability-routed custom payloads. All additive — clients\n * that omit the resume hint or ignore the new events keep working unchanged.\n *\n * Changed in 3.1.0:\n * Additive cost / token usage extension. `FinishedEvent` gains an optional\n * `tokens?: TokenUsage` field carrying per-turn input / output / cache-read /\n * cache-creation / reasoning token counts. `AgentDriver.getTokenUsage()` is\n * widened to return the same `TokenUsage` shape (existing consumers reading\n * `inputTokens` / `outputTokens` keep working unchanged). Drivers that do not\n * surface token usage continue to return `null` / omit the field.\n *\n * Changed in 3.0.0:\n * Major bump for the deterministic session bootstrap rewrite. `ConfigureCommandV2`,\n * `provision_secrets`, `request_access_token`, `add_resource`, `remove_resource`,\n * `set_log_level`, `state_action`, `lifecycle`, `remount_mount`, `compact`, and\n * `reconfigure_agent` are removed from the `AgentCommand` union. Their semantics\n * are reachable through:\n * - `session_init` (one deterministic envelope at session start that delivers\n * identity, resolved config, pre-minted credentials, secrets, capabilities,\n * shared state, active flows, resume hints, and logging config),\n * - `host.refresh_credential` (capability invocation that replaces the\n * refresh-on-401 path of `request_access_token`), and\n * - `runner.*` capabilities (`runner.add_mount`, `runner.add_connector`,\n * `runner.remove_resource`, `runner.update_credential`, `runner.set_log_level`,\n * `runner.set_state`, `runner.lifecycle`) invoked by the platform via the\n * bidirectional capability registry.\n *\n * Capabilities gain an `audience: ('llm' | 'user' | 'runtime')[]` field that\n * scopes visibility: host RPCs (`host.*`) and runner RPCs (`runner.*`) are\n * `['runtime']` and never reach the LLM tool list or the user-facing command\n * palette. v2.x capabilities without an explicit `audience` default to\n * `['llm', 'user']`, preserving prior behaviour.\n *\n * Spec: `_devlog/specs/2026-05-10-deterministic-session-bootstrap.md`.\n *\n * @docLink packages/types/protocol-v3#protocol-version\n */\nexport const PROTOCOL_VERSION: ProtocolVersion = { major: 3, minor: 5, patch: 0 };\n\n/**\n * String form of {@link PROTOCOL_VERSION}, kept in lock-step. Useful for\n * `package.json` version fields and HTTP `User-Agent` strings.\n *\n * @category Protocol\n * @since 3.0.0\n * @docLink packages/types/protocol-v3#protocol-version\n */\nexport const PROTOCOL_VERSION_STRING = \"3.5.0\";\n\n/**\n * Parse a `\"major.minor.patch\"` string into a {@link ProtocolVersion}.\n *\n * @param s - the version string to parse, exactly three dot-separated non-negative integers\n * @returns the parsed protocol version\n * @throws {Error} if the string is not exactly three dot-separated non-negative integers\n *\n * @example\n * ```ts\n * parseVersion('2.0.0'); // { major: 2, minor: 0, patch: 0 }\n * parseVersion('2.1'); // throws\n * ```\n *\n * @category Protocol\n * @since 2.0.0\n * @docLink packages/types/protocol-v2#parse-version\n */\nexport function parseVersion(s: string): ProtocolVersion {\n const parts = s.split(\".\");\n if (parts.length !== 3) {\n throw new Error(`Invalid ProtocolVersion: \"${s}\" (expected \"major.minor.patch\")`);\n }\n const [maj, min, pat] = parts;\n const major = Number(maj);\n const minor = Number(min);\n const patch = Number(pat);\n if (\n !Number.isInteger(major) ||\n !Number.isInteger(minor) ||\n !Number.isInteger(patch) ||\n major < 0 ||\n minor < 0 ||\n patch < 0\n ) {\n throw new Error(`Invalid ProtocolVersion: \"${s}\" (each part must be a non-negative integer)`);\n }\n return { major, minor, patch };\n}\n\n/**\n * Format a {@link ProtocolVersion} record into its `\"major.minor.patch\"` string form.\n *\n * @param v - the protocol version to format\n * @returns the dot-joined string form\n *\n * @example\n * ```ts\n * formatVersion({ major: 2, minor: 0, patch: 0 }); // '2.0.0'\n * ```\n *\n * @category Protocol\n * @since 2.0.0\n * @docLink packages/types/protocol-v2#format-version\n */\nexport function formatVersion(v: ProtocolVersion): string {\n return `${v.major}.${v.minor}.${v.patch}`;\n}\n"]}
|
package/dist/cli/index.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { AI_RESOURCES, aiResourceRoots } from '../chunk-VK24PIAB.js';
|
|
3
|
-
import { makeInstallCommand, makeCheckCommand, makeCleanCommand, reportInstalledSoftDeps } from '../chunk-
|
|
4
|
-
import { makeSourceCommand, syncProjectSources } from '../chunk-
|
|
3
|
+
import { makeInstallCommand, makeCheckCommand, makeCleanCommand, reportInstalledSoftDeps } from '../chunk-SBU73P7R.js';
|
|
4
|
+
import { makeSourceCommand, syncProjectSources } from '../chunk-MBGSJM7H.js';
|
|
5
5
|
import { getStoreConfig, storeFetch, deviceLogin, loadStoreAuthConfig, logout, hasStoredAuth, isStoreAuthenticated, getStoreToken, getStoreIdentity } from '../chunk-MB6563TL.js';
|
|
6
|
-
import { openCatalogSource, openLibraryManager, createFullRegistry, openLibrary } from '../chunk-
|
|
7
|
-
import { logErr, S, logOk, logInfo, kindColorPad, kindColor, colorRef, formatSoftDepSection, bareSoftDepName, logWarn, formatSoftDepHint, formatRelativeTime, formatSoftDepRemovePreview, formatSoftDepAddPreview, fitWidth } from '../chunk-
|
|
6
|
+
import { openCatalogSource, openLibraryManager, createFullRegistry, openLibrary } from '../chunk-6Q7CNVU3.js';
|
|
7
|
+
import { logErr, S, logOk, logInfo, kindColorPad, kindColor, colorRef, formatSoftDepSection, bareSoftDepName, logWarn, formatSoftDepHint, formatRelativeTime, formatSoftDepRemovePreview, formatSoftDepAddPreview, fitWidth } from '../chunk-JPKWPX5Q.js';
|
|
8
8
|
import { LocalSecretsProvider } from '../chunk-6BEGKO2Q.js';
|
|
9
|
-
import { runFlow, resumeFlow } from '../chunk-
|
|
9
|
+
import { runFlow, resumeFlow } from '../chunk-5F3GULZT.js';
|
|
10
10
|
import '../chunk-4R6DROGN.js';
|
|
11
11
|
import { validateFlowVersions, parseSkillFrontmatter } from '../chunk-GXC3TYMQ.js';
|
|
12
|
-
import { runAgentChat, loadSessionById, loadSession, listSessions, setCurrentSession, deleteSession, clearSession, loadAgentManifest, compileComposition, MarkdownStreamer, resolveMixin } from '../chunk-
|
|
13
|
-
import { buildClaudePluginFiles } from '../chunk-
|
|
12
|
+
import { runAgentChat, loadSessionById, loadSession, listSessions, setCurrentSession, deleteSession, clearSession, loadAgentManifest, compileComposition, MarkdownStreamer, resolveMixin } from '../chunk-HGLQYLZB.js';
|
|
13
|
+
import { buildClaudePluginFiles } from '../chunk-VWSR6K7C.js';
|
|
14
14
|
import '../chunk-X5YPJV4N.js';
|
|
15
15
|
import '../chunk-O7SG5PC2.js';
|
|
16
16
|
import '../chunk-7QBNJTTQ.js';
|
|
@@ -25,14 +25,14 @@ import '../chunk-BMQKMOQY.js';
|
|
|
25
25
|
import '../chunk-GAH4YRCI.js';
|
|
26
26
|
import '../chunk-TNSCHS4I.js';
|
|
27
27
|
import '../chunk-LV2HPH3C.js';
|
|
28
|
-
import '../chunk-
|
|
28
|
+
import '../chunk-JCKGYBWY.js';
|
|
29
29
|
import '../chunk-Y6FV73IH.js';
|
|
30
30
|
import '../chunk-6E6PKKAD.js';
|
|
31
31
|
import { loadFlow, loadAllFlows } from '../chunk-4N5XR5DQ.js';
|
|
32
32
|
import '../chunk-DEYYRFQU.js';
|
|
33
33
|
import '../chunk-IFGTRL2I.js';
|
|
34
|
-
import '../chunk-
|
|
35
|
-
import { AssetManager, NON_DEPLOYABLE_KINDS, MissingManifestError, normalizeRepoUrl, FACTORY_SOURCE_URL } from '../chunk-
|
|
34
|
+
import '../chunk-XJOPAGZX.js';
|
|
35
|
+
import { AssetManager, NON_DEPLOYABLE_KINDS, MissingManifestError, normalizeRepoUrl, FACTORY_SOURCE_URL } from '../chunk-5LPARFB5.js';
|
|
36
36
|
import { resolveLibraryDir, getStoreManifestsDir, getDefaultValue, isSecretPlaceholder } from '../chunk-MWE7DEGC.js';
|
|
37
37
|
import '../chunk-MZV6WCF3.js';
|
|
38
38
|
import '../chunk-JXT46QFC.js';
|
|
@@ -106,7 +106,7 @@ async function runSearch(kind, query, opts) {
|
|
|
106
106
|
}
|
|
107
107
|
}
|
|
108
108
|
async function searchIndex(query, kind) {
|
|
109
|
-
const { openLibrary: openLibrary2 } = await import('../open-library-
|
|
109
|
+
const { openLibrary: openLibrary2 } = await import('../open-library-VFS6WIO7.js');
|
|
110
110
|
const library = await openLibrary2();
|
|
111
111
|
try {
|
|
112
112
|
const defs = await library.listAssetDefs(kind ? { kind } : {});
|
|
@@ -158,7 +158,7 @@ async function searchLocal(query, kind, opts, showStore, airGapped) {
|
|
|
158
158
|
const factory = searchFactory(projectDir, query, kind);
|
|
159
159
|
let entries = unionEntries(await searchIndex(query, kind), factory);
|
|
160
160
|
if (entries.length === 0 && !query && !kind && !airGapped) {
|
|
161
|
-
const { autoSyncForSearch } = await import('../source-
|
|
161
|
+
const { autoSyncForSearch } = await import('../source-Z5HNLF6J.js');
|
|
162
162
|
if (await autoSyncForSearch(projectDir)) {
|
|
163
163
|
entries = unionEntries(await searchIndex(query, kind), factory);
|
|
164
164
|
}
|
|
@@ -212,7 +212,7 @@ async function searchStore(query, kind, opts, airGapped) {
|
|
|
212
212
|
logInfo("air-gapped (cache_ttl: 0) \u2014 local sources only");
|
|
213
213
|
return;
|
|
214
214
|
}
|
|
215
|
-
const { openCatalogSource: openCatalogSource2, LocalCatalogDisabledError } = await import('../open-library-
|
|
215
|
+
const { openCatalogSource: openCatalogSource2, LocalCatalogDisabledError } = await import('../open-library-VFS6WIO7.js');
|
|
216
216
|
try {
|
|
217
217
|
const remote = await openCatalogSource2({ projectDir: path14__default.resolve(opts.projectDir) });
|
|
218
218
|
const assets = await remote.listAssets(kind ? { kind } : {});
|
|
@@ -1101,7 +1101,7 @@ function makeCatalogCommand() {
|
|
|
1101
1101
|
return catalog;
|
|
1102
1102
|
}
|
|
1103
1103
|
async function runLocalCatalogTest(projectDir) {
|
|
1104
|
-
const { resolveCatalogSource } = await import('../open-library-
|
|
1104
|
+
const { resolveCatalogSource } = await import('../open-library-VFS6WIO7.js');
|
|
1105
1105
|
let resolved;
|
|
1106
1106
|
try {
|
|
1107
1107
|
resolved = await resolveCatalogSource({ projectDir });
|
|
@@ -3340,16 +3340,16 @@ function makeLibraryCommand() {
|
|
|
3340
3340
|
});
|
|
3341
3341
|
cmd.command("publish <lib>").description("Push + register the library's manifest atomically (needs git backend)").option("--asset <ref>", "Publish only the single asset matching this ref/name").option("--create-repo", "Provision + link a public github repo if the library has no remote").option("--ref <gitref>", "Git ref to ingest (default: the library branch or main)").option("--dry-run", "Print the plan; push nothing and call no store endpoint").action(
|
|
3342
3342
|
async (lib, opts) => {
|
|
3343
|
-
const { runLibraryPublish } = await import('../library-publish-
|
|
3343
|
+
const { runLibraryPublish } = await import('../library-publish-NCMIFF3V.js');
|
|
3344
3344
|
await withStoreErrorHandling(() => runLibraryPublish(lib, opts));
|
|
3345
3345
|
}
|
|
3346
3346
|
);
|
|
3347
3347
|
cmd.command("register <lib>").description("Register the library's manifest without pushing (bytes already on github)").option("--asset <ref>", "Publish only the single asset matching this ref/name").option("--ref <gitref>", "Git ref to ingest (default: the library branch or main)").option("--dry-run", "Print the plan; call no store endpoint").action(async (lib, opts) => {
|
|
3348
|
-
const { runLibraryRegister } = await import('../library-publish-
|
|
3348
|
+
const { runLibraryRegister } = await import('../library-publish-NCMIFF3V.js');
|
|
3349
3349
|
await withStoreErrorHandling(() => runLibraryRegister(lib, opts));
|
|
3350
3350
|
});
|
|
3351
3351
|
cmd.command("yank <lib>").description("Retract the library's published assets from the store").option("--asset <ref>", "Yank only the single asset matching this ref/name").action(async (lib, opts) => {
|
|
3352
|
-
const { runLibraryYank } = await import('../library-publish-
|
|
3352
|
+
const { runLibraryYank } = await import('../library-publish-NCMIFF3V.js');
|
|
3353
3353
|
await withStoreErrorHandling(() => runLibraryYank(lib, opts));
|
|
3354
3354
|
});
|
|
3355
3355
|
return cmd;
|
|
@@ -3990,7 +3990,7 @@ async function previewSoftDepsUnderCursor() {
|
|
|
3990
3990
|
}
|
|
3991
3991
|
async function loadAssets() {
|
|
3992
3992
|
softDepPreviewCache.clear();
|
|
3993
|
-
const { gatherAssetFeeds } = await import('../asset-feeds-
|
|
3993
|
+
const { gatherAssetFeeds } = await import('../asset-feeds-LD6QKJ2R.js');
|
|
3994
3994
|
const { entries, domains, notes } = await gatherAssetFeeds(am, am.projectDir);
|
|
3995
3995
|
if (notes.length > 0) {
|
|
3996
3996
|
state.message = notes.map((n) => `[${n.feed}] ${n.message}`).join(" \u2022 ");
|
|
@@ -4196,7 +4196,7 @@ function reconcileCollapsedSets(rows) {
|
|
|
4196
4196
|
async function loadSourcesAndLibraries() {
|
|
4197
4197
|
try {
|
|
4198
4198
|
const [{ openLibraryManager: openLibraryManager2 }, { skaileHomeDir }, { getGlobalCacheDir: getGlobalCacheDir2 }] = await Promise.all([
|
|
4199
|
-
import('../open-library-
|
|
4199
|
+
import('../open-library-VFS6WIO7.js'),
|
|
4200
4200
|
import('../library/index.js'),
|
|
4201
4201
|
import('../core/index.js')
|
|
4202
4202
|
]);
|
|
@@ -6567,7 +6567,7 @@ function makeServeCommand() {
|
|
|
6567
6567
|
);
|
|
6568
6568
|
}
|
|
6569
6569
|
async function ensurePluginsLoadedForServe(projectDir) {
|
|
6570
|
-
const { logInfo: logInfo2, logWarn: logWarn2 } = await import('../helpers-
|
|
6570
|
+
const { logInfo: logInfo2, logWarn: logWarn2 } = await import('../helpers-ZZZY7HUJ.js');
|
|
6571
6571
|
try {
|
|
6572
6572
|
const { resolveSkWorkspaceConfig: resolveSkWorkspaceConfig2 } = await import('../core/index.js');
|
|
6573
6573
|
const config = resolveSkWorkspaceConfig2(projectDir);
|
|
@@ -6586,7 +6586,7 @@ async function ensurePluginsLoadedForServe(projectDir) {
|
|
|
6586
6586
|
}
|
|
6587
6587
|
}
|
|
6588
6588
|
async function runCompileTest(opts) {
|
|
6589
|
-
const { logOk: logOk2, logErr: logErr2, logInfo: logInfo2, S: S2 } = await import('../helpers-
|
|
6589
|
+
const { logOk: logOk2, logErr: logErr2, logInfo: logInfo2, S: S2 } = await import('../helpers-ZZZY7HUJ.js');
|
|
6590
6590
|
const { tmpdir } = await import('os');
|
|
6591
6591
|
const { dirname: dirname4, join: join7, resolve: resolve5 } = await import('path');
|
|
6592
6592
|
const { fileURLToPath: fileURLToPath2 } = await import('url');
|
|
@@ -7466,7 +7466,7 @@ function makeStoreCommand() {
|
|
|
7466
7466
|
process.exit(2);
|
|
7467
7467
|
});
|
|
7468
7468
|
store.command("search <query>").description("Search the AI Asset Store catalog by name, description, or publisher").option("--kind <kind>", "Filter by asset kind (skill, agent, prompt, flow, \u2026)").option("-C, --project-dir <dir>", "Project directory (catalog config overlay)", process.cwd()).action(async (query, opts) => {
|
|
7469
|
-
const { openCatalogSource: openCatalogSource2, LocalCatalogDisabledError } = await import('../open-library-
|
|
7469
|
+
const { openCatalogSource: openCatalogSource2, LocalCatalogDisabledError } = await import('../open-library-VFS6WIO7.js');
|
|
7470
7470
|
try {
|
|
7471
7471
|
const remote = await openCatalogSource2({ projectDir: path14__default.resolve(opts.projectDir) });
|
|
7472
7472
|
const assets = await remote.listAssets(opts.kind ? { kind: opts.kind } : {});
|
|
@@ -7499,8 +7499,8 @@ function makeStoreCommand() {
|
|
|
7499
7499
|
}
|
|
7500
7500
|
});
|
|
7501
7501
|
store.command("show <ref>").description("Show a store asset's details + provenance (source, files, integrity)").option("-C, --project-dir <dir>", "Project directory (catalog config overlay)", process.cwd()).action(async (ref, opts) => {
|
|
7502
|
-
const { openCatalogSource: openCatalogSource2, LocalCatalogDisabledError } = await import('../open-library-
|
|
7503
|
-
const { supportsInstallManifest } = await import('../project-
|
|
7502
|
+
const { openCatalogSource: openCatalogSource2, LocalCatalogDisabledError } = await import('../open-library-VFS6WIO7.js');
|
|
7503
|
+
const { supportsInstallManifest } = await import('../project-SC7TVEQ6.js');
|
|
7504
7504
|
try {
|
|
7505
7505
|
const remote = await openCatalogSource2({ projectDir: path14__default.resolve(opts.projectDir) });
|
|
7506
7506
|
const asset = await remote.resolve(ref);
|
|
@@ -8580,7 +8580,7 @@ async function bootstrapUserConfig() {
|
|
|
8580
8580
|
}
|
|
8581
8581
|
async function hydrateInitSources(resolved, created) {
|
|
8582
8582
|
try {
|
|
8583
|
-
const { ensureSourcesCloned } = await import('../ensure-sources-
|
|
8583
|
+
const { ensureSourcesCloned } = await import('../ensure-sources-S6QBARWF.js');
|
|
8584
8584
|
const hydrate = ensureSourcesCloned(resolved, { quiet: true });
|
|
8585
8585
|
for (const n of hydrate.cloned) created.push(`~/.skaile/cache/sources/${n}/`);
|
|
8586
8586
|
if (hydrate.failed.length > 0) {
|
package/dist/connectors/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { AbstractConnector, BUILTIN_CONNECTOR_CATALOG, ConnectorFieldMissingError, ConnectorManager, ConnectorStartupError, FlowAdapter, LogBuffer, ManagedGitconfigCollisionError, PortPool, atomicReplaceCredential, buildConnectorPromptSection, buildSdkConnectorTools, createFsWatcher, createWorktree, defaultSpawn, ensureDirMode, ensureFleetMounted, findGitRoot, findMissingPackages, getConnector, installNpmPackages, isFleetManaged, isPackageResolvable, listConnectors, listWorktrees, registerBuiltinConnectors, removeMountBlock, renderCredentialHelperScript, tryGetConnector, worktreeRegistry, writeHelperScript, writeMountBlock } from '../chunk-
|
|
1
|
+
export { AbstractConnector, BUILTIN_CONNECTOR_CATALOG, ConnectorFieldMissingError, ConnectorManager, ConnectorStartupError, FlowAdapter, LogBuffer, ManagedGitconfigCollisionError, PortPool, atomicReplaceCredential, buildConnectorPromptSection, buildSdkConnectorTools, createFsWatcher, createWorktree, defaultSpawn, ensureDirMode, ensureFleetMounted, findGitRoot, findMissingPackages, getConnector, installNpmPackages, isFleetManaged, isPackageResolvable, listConnectors, listWorktrees, registerBuiltinConnectors, removeMountBlock, renderCredentialHelperScript, tryGetConnector, worktreeRegistry, writeHelperScript, writeMountBlock } from '../chunk-JCKGYBWY.js';
|
|
2
2
|
export { EnvSecretProvider, ForgeSecretProvider, InMemorySecretProvider, LegacyAuthGrammarError, LockedSecretProvider, OAuthRequiredError, PreMintedSecretProvider, SecretProviderChain, createCliSecretProviderChain, createForgeSecretProviderChain, deriveSingleMaterializedConnectorDeclaration, fromMaterializedConnectorMd, loadConnectorDeclarations, loadMaterializedConnectorDeclarations, resolveAuthRef, resolveBackendAuthFor, resolvedConfigToDeclarations } from '../chunk-Y6FV73IH.js';
|
|
3
3
|
import '../chunk-6E6PKKAD.js';
|
|
4
4
|
import '../chunk-4N5XR5DQ.js';
|
|
@@ -7,11 +7,14 @@
|
|
|
7
7
|
* `_devlog/specs/2026-05-07-unified-credential-mediation.md` § Step 9a:
|
|
8
8
|
*
|
|
9
9
|
* 1. On `op = get`, stat the credentials file and compute its age (mtime).
|
|
10
|
-
* 2. If age > triggerAgeSec, touch the
|
|
11
|
-
* this path via `fs.watch` and mints
|
|
12
|
-
* credentials file when it sees the
|
|
13
|
-
*
|
|
14
|
-
*
|
|
10
|
+
* 2. If the file is empty/missing OR age > triggerAgeSec, touch the
|
|
11
|
+
* refresh-flag file. The runner watches this path via `fs.watch` and mints
|
|
12
|
+
* a fresh access token + rewrites the credentials file when it sees the
|
|
13
|
+
* change. Emptiness is its own trigger because a freshly truncated file
|
|
14
|
+
* has a *recent* mtime, so the age check alone can never heal it.
|
|
15
|
+
* 3. Poll the credentials file in 200ms increments until its mtime advances,
|
|
16
|
+
* or it becomes non-empty (when it started empty), or waitTimeoutMs
|
|
17
|
+
* elapses.
|
|
15
18
|
* 4. Translate the credentials file (`scheme://user:pass@host <tag>` lines —
|
|
16
19
|
* git's `store --file=` format) into the helper-output format git
|
|
17
20
|
* expects (`username=<value>\npassword=<value>\n`). Filters lines by the
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"credential-helper-script.d.ts","sourceRoot":"","sources":["../../../connectors/src/credential-helper-script.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"credential-helper-script.d.ts","sourceRoot":"","sources":["../../../connectors/src/credential-helper-script.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsCG;AAEH,mEAAmE;AACnE,MAAM,WAAW,gBAAgB;IAC/B,uDAAuD;IACvD,eAAe,EAAE,MAAM,CAAC;IACxB;;;;OAIG;IACH,eAAe,EAAE,MAAM,CAAC;IACxB;;;;OAIG;IACH,aAAa,EAAE,MAAM,CAAC;IACtB;;;;;OAKG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB;;;;;OAKG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAgB,4BAA4B,CAAC,IAAI,EAAE,gBAAgB,GAAG,MAAM,CAkH3E"}
|
|
@@ -115,8 +115,10 @@ export declare function writeHelperScript(scriptPath: string, body: string): voi
|
|
|
115
115
|
* The gitconfig block (which only points at the helper) does not need to
|
|
116
116
|
* change; the helper re-reads the credentials file on every git network op.
|
|
117
117
|
*
|
|
118
|
-
*
|
|
119
|
-
*
|
|
118
|
+
* Upserts: inserts the line when `mountId` has none yet. An emptied or missing
|
|
119
|
+
* credentials file must be able to self-heal from the refresh path — refusing
|
|
120
|
+
* to insert would strand interactive git until an external reconnect.
|
|
121
|
+
* Other mounts' lines are left untouched.
|
|
120
122
|
*/
|
|
121
123
|
export declare function atomicReplaceCredential(opts: AtomicReplaceCredentialOptions): void;
|
|
122
124
|
//# sourceMappingURL=managed-gitconfig.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"managed-gitconfig.d.ts","sourceRoot":"","sources":["../../../connectors/src/managed-gitcon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;;;;;;;GAQG;AACH,wBAAgB,iBAAiB,CAAC,UAAU,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,IAAI,CAKxE;AAED
|
|
1
|
+
{"version":3,"file":"managed-gitconfig.d.ts","sourceRoot":"","sources":["../../../connectors/src/managed-gitconfig.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AAgBH;;;;GAIG;AACH,qBAAa,8BAA+B,SAAQ,KAAK;IACvD,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,eAAe,EAAE,MAAM,CAAC;IACjC,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;gBAEhB,SAAS,EAAE,MAAM,EAAE,eAAe,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM;CAW3E;AAED,sDAAsD;AACtD,MAAM,WAAW,sBAAsB;IACrC,mDAAmD;IACnD,OAAO,EAAE,MAAM,CAAC;IAChB;;;;OAIG;IACH,SAAS,EAAE,MAAM,CAAC;IAClB;;;OAGG;IACH,KAAK,EAAE,MAAM,CAAC;IACd,mDAAmD;IACnD,aAAa,EAAE,MAAM,CAAC;IACtB,kDAAkD;IAClD,eAAe,EAAE,MAAM,CAAC;IACxB;;;;;;;;;OASG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B;AAED,uDAAuD;AACvD,MAAM,WAAW,uBAAuB;IACtC,0DAA0D;IAC1D,OAAO,EAAE,MAAM,CAAC;IAChB,mDAAmD;IACnD,aAAa,EAAE,MAAM,CAAC;IACtB,kDAAkD;IAClD,eAAe,EAAE,MAAM,CAAC;CACzB;AAED,8DAA8D;AAC9D,MAAM,WAAW,8BAA8B;IAC7C,4DAA4D;IAC5D,OAAO,EAAE,MAAM,CAAC;IAChB,mFAAmF;IACnF,SAAS,EAAE,MAAM,CAAC;IAClB,4BAA4B;IAC5B,KAAK,EAAE,MAAM,CAAC;IACd,kDAAkD;IAClD,eAAe,EAAE,MAAM,CAAC;CACzB;AAoLD;;;;;;;;;;;GAWG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAAE,sBAAsB,GAAG,IAAI,CAkClE;AAED;;;;GAIG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,uBAAuB,GAAG,IAAI,CAiBpE;AAED;;;;;;;;GAQG;AACH,wBAAgB,iBAAiB,CAAC,UAAU,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,IAAI,CAKxE;AAED;;;;;;;;;GASG;AACH,wBAAgB,uBAAuB,CAAC,IAAI,EAAE,8BAA8B,GAAG,IAAI,CAOlF"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { logErr, logOk, logInfo } from './chunk-
|
|
2
|
-
import './chunk-
|
|
1
|
+
import { logErr, logOk, logInfo } from './chunk-JPKWPX5Q.js';
|
|
2
|
+
import './chunk-5LPARFB5.js';
|
|
3
3
|
import './chunk-MWE7DEGC.js';
|
|
4
4
|
import './chunk-MZV6WCF3.js';
|
|
5
5
|
import './chunk-JXT46QFC.js';
|
|
@@ -85,5 +85,5 @@ function ensureSourcesCloned(projectDir, opts = {}) {
|
|
|
85
85
|
}
|
|
86
86
|
|
|
87
87
|
export { ensureSourcesCloned };
|
|
88
|
-
//# sourceMappingURL=ensure-sources-
|
|
89
|
-
//# sourceMappingURL=ensure-sources-
|
|
88
|
+
//# sourceMappingURL=ensure-sources-S6QBARWF.js.map
|
|
89
|
+
//# sourceMappingURL=ensure-sources-S6QBARWF.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../cli/src/ensure-sources.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAqBA,SAAS,gBAAgB,GAAA,EAAqB;AAC5C,EAAA,OAAY,IAAA,CAAA,IAAA,CAAK,iBAAA,EAAkB,EAAG,GAAG,CAAA;AAC3C;AASA,SAAS,kBAAA,CAAmB,UAAkB,KAAA,EAAsC;AAClF,EAAA,IAAI;AACF,IAAA,O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A;AAC5B,EAAA,MAAM,OAAA,GAAU,kBAAA,CAAmB,QAAA,EAAU,KAAK,CAAA;AAClD,EAAA,IAAI,OAAA,KAAY,MAAM,OAAO,MAAA;AAC7B,EAAA,IAAI,OAAA,CAAQ,MAAA,KAAW,CAAA,EAAG,OAAO,MAAA;AAEjC,EAAA,KAAA,MAAW,SAAS,OAAA,EAAS;AAC3B,IAAA,kBAAA,CAAmB,KAAA,EAAO,OAAO,MAAM,CAAA;AAAA,EACzC;AAEA,EAAA,IAAI,CAAC,KAAA,EAAO;AACV,IAAA,iBAAA,CAAkB,MAAM,CAAA;AAAA,EAC1B;AAEA,EAAA,OAAO,MAAA;AACT","file":"ensure-sources-S6QBARWF.js","sourcesContent":["/**\n * ensure-sources.ts — hydrate the `~/.skaile/cache/sources/` clone cache from a\n * project's `skaile.yaml` `sources:` entries.\n *\n * Called by `skaile init` (idempotent: no-op when no sources declared) and\n * `skaile install` so checking out a project pulls its source clones onto\n * the local machine.\n */\n\nimport { spawnSync } from \"node:child_process\";\nimport { existsSync, mkdirSync } from \"node:fs\";\nimport * as path from \"node:path\";\nimport {\n getGlobalCacheDir,\n type SourceEntry,\n sourceCacheKey,\n sourceShortName,\n WorkspaceYamlEditor,\n} from \"@skaile/workspaces/core\";\nimport { logErr, logInfo, logOk } from \"./helpers.ts\";\n\nfunction sourceClonePath(key: string): string {\n return path.join(getGlobalCacheDir(), key);\n}\n\nexport interface EnsureResult {\n cloned: string[];\n cached: string[];\n failed: string[];\n}\n\n/** Load `sources:` from a project's `skaile.yaml`, or `null` when unavailable. */\nfunction loadProjectSources(yamlPath: string, quiet: boolean): SourceEntry[] | null {\n try {\n return WorkspaceYamlEditor.load(yamlPath).getSources();\n } catch (err) {\n if (!quiet) {\n logErr(`Could not read ${yamlPath}: ${err instanceof Error ? err.message : String(err)}`);\n }\n return null;\n }\n}\n\n/**\n * Hydrate a single source entry into `result`: skip when already cached,\n * otherwise clone and record success/failure. Mutates `result` in place.\n */\nfunction hydrateSourceEntry(entry: SourceEntry, quiet: boolean, result: EnsureResult): void {\n const key = sourceCacheKey(entry.url);\n const slug = sourceShortName(entry.url);\n const dest = sourceClonePath(key);\n if (existsSync(dest)) {\n result.cached.push(slug);\n return;\n }\n mkdirSync(path.dirname(dest), { recursive: true });\n const args = [\"clone\", entry.url, dest];\n if (entry.pin) args.splice(1, 0, \"--branch\", entry.pin);\n const clone = spawnSync(\"git\", args, { stdio: quiet ? \"pipe\" : \"inherit\" });\n if (clone.status !== 0) {\n result.failed.push(slug);\n if (quiet) {\n logErr(`git clone failed for ${entry.url}`);\n }\n return;\n }\n result.cloned.push(slug);\n}\n\n/** Log a full-hydrate summary of cloned + reused-cached entries. */\nfunction logHydrateSummary(result: EnsureResult): void {\n for (const n of result.cloned) logOk(`Cloned source \"${n}\".`);\n if (result.cached.length > 0) {\n logInfo(`Reused cached clones: ${result.cached.join(\", \")}`);\n }\n}\n\n/**\n * Walk `projectDir/skaile.yaml` `sources:` and clone any entries whose\n * clone directory does not yet exist under `~/.skaile/cache/sources/`. Existing\n * clones are left untouched — this is hydration, not sync.\n *\n * Quiet by default: when `quiet: true` the helper only prints failures.\n * On full hydrate (`quiet: false`) it logs each cloned/cached entry.\n */\nexport function ensureSourcesCloned(\n projectDir: string,\n opts: { quiet?: boolean } = {},\n): EnsureResult {\n const result: EnsureResult = { cloned: [], cached: [], failed: [] };\n const yamlPath = path.join(projectDir, \"skaile.yaml\");\n if (!existsSync(yamlPath)) return result;\n\n const quiet = opts.quiet ?? false;\n const sources = loadProjectSources(yamlPath, quiet);\n if (sources === null) return result;\n if (sources.length === 0) return result;\n\n for (const entry of sources) {\n hydrateSourceEntry(entry, quiet, result);\n }\n\n if (!quiet) {\n logHydrateSummary(result);\n }\n\n return result;\n}\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { BoxConnector, createConnector4 as createConnector } from '../../chunk-
|
|
1
|
+
export { BoxConnector, createConnector4 as createConnector } from '../../chunk-JCKGYBWY.js';
|
|
2
2
|
import '../../chunk-Y6FV73IH.js';
|
|
3
3
|
import '../../chunk-6E6PKKAD.js';
|
|
4
4
|
import '../../chunk-4N5XR5DQ.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { DeployConnector, createConnector2 as createConnector } from '../../chunk-
|
|
1
|
+
export { DeployConnector, createConnector2 as createConnector } from '../../chunk-JCKGYBWY.js';
|
|
2
2
|
import '../../chunk-Y6FV73IH.js';
|
|
3
3
|
import '../../chunk-6E6PKKAD.js';
|
|
4
4
|
import '../../chunk-4N5XR5DQ.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { DevServerConnector, createConnector3 as createConnector } from '../../chunk-
|
|
1
|
+
export { DevServerConnector, createConnector3 as createConnector } from '../../chunk-JCKGYBWY.js';
|
|
2
2
|
import '../../chunk-Y6FV73IH.js';
|
|
3
3
|
import '../../chunk-6E6PKKAD.js';
|
|
4
4
|
import '../../chunk-4N5XR5DQ.js';
|
|
@@ -83,8 +83,9 @@ export interface FlowAdapterConnectOptions {
|
|
|
83
83
|
/**
|
|
84
84
|
* Either a fresh start seed (runId + startedBy) or a full rehydration
|
|
85
85
|
* state. If `execution` is provided, it replaces the default empty
|
|
86
|
-
* state — used on
|
|
87
|
-
*
|
|
86
|
+
* state — used on cold-container rehydration when the runner bootstraps
|
|
87
|
+
* the flow connector from a host `connector_mutate { id: "flow",
|
|
88
|
+
* op: "hydrate", payload: { state, flow } }` (Protocol >= 3.5).
|
|
88
89
|
*/
|
|
89
90
|
execution?: FlowExecution;
|
|
90
91
|
seed?: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"adapter.d.ts","sourceRoot":"","sources":["../../../../factory-assets/connectors/flow/adapter.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,OAAO,EACL,iBAAiB,EACjB,KAAK,cAAc,EAEnB,KAAK,oBAAoB,EAEzB,KAAK,eAAe,EAKpB,KAAK,QAAQ,EACd,MAAM,+BAA+B,CAAC;AACvC,OAAO,KAAK,EAGV,aAAa,EASd,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAEL,KAAK,cAAc,EAEnB,UAAU,EACX,MAAM,mBAAmB,CAAC;AAM3B;;;;;;;;;GASG;AACH,MAAM,WAAW,sBAAsB;IACrC,MAAM,CACJ,WAAW,EAAE,MAAM,EACnB,GAAG,EAAE;QAAE,cAAc,EAAE,MAAM,CAAC;QAAC,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;KAAE,GAC9D,OAAO,CAAC,IAAI,CAAC,CAAC;CAClB;AAID;;;GAGG;AACH,MAAM,WAAW,gBAAgB;IAC/B,2DAA2D;IAC3D,OAAO,EAAE,cAAc,CAAC;IACxB,kFAAkF;IAClF,SAAS,EAAE,aAAa,CAAC;IACzB,kGAAkG;IAClG,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,aAAa,KAAK,IAAI,CAAC;IAC1C;;;;;;OAMG;IACH,WAAW,CAAC,EAAE,sBAAsB,CAAC;IACrC;;;;OAIG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,sFAAsF;IACtF,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B;;;;OAIG;IACH,qBAAqB,CAAC,EAAE,aAAa,CAAC;CACvC;AAED;;;GAGG;AACH,MAAM,WAAW,yBAAyB;IACxC,IAAI,EAAE,cAAc,CAAC;IACrB
|
|
1
|
+
{"version":3,"file":"adapter.d.ts","sourceRoot":"","sources":["../../../../factory-assets/connectors/flow/adapter.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,OAAO,EACL,iBAAiB,EACjB,KAAK,cAAc,EAEnB,KAAK,oBAAoB,EAEzB,KAAK,eAAe,EAKpB,KAAK,QAAQ,EACd,MAAM,+BAA+B,CAAC;AACvC,OAAO,KAAK,EAGV,aAAa,EASd,MAAM,0BAA0B,CAAC;AAClC,OAA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,EAAE,MAAM,GAAG,SAAS,EAC5B,SAAS,EAAE,MAAM,GAChB,IAAI;IAoCP;;;OAGG;IACH,UAAU,CAAC,MAAM,EAAE,eAAe,EAAE,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,GAAG,IAAI;IAoChG;;;;OAIG;IACH,SAAS,CAAC,MAAM,EAAE,eAAe,EAAE,MAAM,EAAE,MAAM,GAAG,IAAI;IAiBxD,0DAA0D;IAC1D,iBAAiB,CAAC,MAAM,EAAE,eAAe,EAAE,OAAO,EAAE,OAAO,GAAG,IAAI;IAOlE,mFAAmF;IACnF,MAAM,CAAC,MAAM,EAAE,eAAe,GAAG,IAAI;IAOrC,8DAA8D;IAC9D,YAAY,CAAC,MAAM,EAAE,eAAe,GAAG,aAAa;IAMpD,OAAO,CAAC,CAAC;IAIT;;;;;;;;;;;OAWG;IACH,OAAO,CAAC,MAAM;IAgCd;;;;OAIG;IACH,OAAO,CAAC,SAAS;IAuCjB;;;OAGG;IACH,OAAO,CAAC,YAAY;CAuBrB;AA4DD,OAAO,EAAE,UAAU,EAAE,CAAC;AAEtB;;;;GAIG;AACH,wBAAgB,eAAe,IAAI,WAAW,CAE7C"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { FlowAdapter, createConnector } from '../../../chunk-
|
|
1
|
+
export { FlowAdapter, createConnector } from '../../../chunk-JCKGYBWY.js';
|
|
2
2
|
import '../../../chunk-Y6FV73IH.js';
|
|
3
3
|
import '../../../chunk-6E6PKKAD.js';
|
|
4
4
|
export { isBlocking } from '../../../chunk-4N5XR5DQ.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { resumeFlow, runFlow } from '../../../chunk-
|
|
1
|
+
export { resumeFlow, runFlow } from '../../../chunk-5F3GULZT.js';
|
|
2
2
|
import '../../../chunk-4R6DROGN.js';
|
|
3
3
|
import '../../../chunk-GXC3TYMQ.js';
|
|
4
|
-
import '../../../chunk-
|
|
4
|
+
import '../../../chunk-JCKGYBWY.js';
|
|
5
5
|
import '../../../chunk-Y6FV73IH.js';
|
|
6
6
|
import '../../../chunk-6E6PKKAD.js';
|
|
7
7
|
import '../../../chunk-4N5XR5DQ.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"driver.d.ts","sourceRoot":"","sources":["../../../../factory-assets/connectors/git/driver.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAYH,OAAO,KAAK,EACV,cAAc,EACd,oBAAoB,EACpB,oBAAoB,EACpB,eAAe,EACf,cAAc,EAMd,QAAQ,EAER,WAAW,EACX,YAAY,EACb,MAAM,+BAA+B,CAAC;AAEvC,OAAO,EACL,iBAAiB,EAUlB,MAAM,+BAA+B,CAAC;AAOvC,UAAU,gBAAgB;IACxB,OAAO,EAAE,OAAO,CAAC;IACjB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,OAAO,CAAC;IAChB,YAAY,EAAE,MAAM,CAAC;IACrB;;;;;;;;;;;;OAYG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,UAAU,aAAa;IACrB,gBAAgB,EAAE,MAAM,CAAC;IACzB,UAAU,EAAE,OAAO,CAAC;IACpB,QAAQ,EAAE,OAAO,CAAC;CACnB;AAED,UAAU,kBAAkB;IAC1B,iBAAiB,EAAE,OAAO,CAAC;IAC3B,eAAe,EAAE,OAAO,CAAC;IACzB,YAAY,EAAE,OAAO,CAAC;IACtB,WAAW,EAAE,OAAO,CAAC;IACrB,qFAAqF;IACrF,gBAAgB,EAAE,MAAM,CAAC;IACzB,6CAA6C;IAC7C,eAAe,EAAE,OAAO,CAAC;IACzB;4EACwE;IACxE,eAAe,EAAE,OAAO,CAAC;CAC1B;AAuJD;;;;;GAKG;AACH,iBAAS,gBAAgB,CAAC,IAAI,EAAE;IAAE,IAAI,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;IAAC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,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AW,EAAE,MAAM,EAAE,MAAM,EAAE,eAAe,GAAG,OAAO,CAAC,IAAI,CAAC;
|
|
1
|
+
{"version":3,"file":"driver.d.ts","sourceRoot":"","sources":["../../../../factory-assets/connectors/git/driver.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAYH,OAAO,KAAK,EACV,cAAc,EACd,oBAAoB,EACpB,oBAAoB,EACpB,eAAe,EACf,cAAc,EAMd,QAAQ,EAER,WAAW,EACX,YAAY,EACb,MAAM,+BAA+B,CAAC;AAEvC,OAAO,EACL,iBAAiB,EAUlB,MAAM,+BAA+B,CAAC;AAOvC,UAAU,gBAAgB;IACxB,OAAO,EAAE,OAAO,CAAC;IACjB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,OAAO,CAAC;IAChB,YAAY,EAAE,MAAM,CAAC;IACrB;;;;;;;;;;;;OAYG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,UAAU,aAAa;IACrB,gBAAgB,EAAE,MAAM,CAAC;IACzB,UAAU,EAAE,OAAO,CAAC;IACpB,QAAQ,EAAE,OAAO,CAAC;CACnB;AAED,UAAU,kBAAkB;IAC1B,iBAAiB,EAAE,OAAO,CAAC;IAC3B,eAAe,EAAE,OAAO,CAAC;IACzB,YAAY,EAAE,OAAO,CAAC;IACtB,WAAW,EAAE,OAAO,CAAC;IACrB,qFAAqF;IACrF,gBAAgB,EAAE,MAAM,CAAC;IACzB,6CAA6C;IAC7C,eAAe,EAAE,OAAO,CAAC;IACzB;4EACwE;IACxE,eAAe,EAAE,OAAO,CAAC;CAC1B;AAuJD;;;;;GAKG;AACH,iBAAS,gBAAgB,CAAC,IAAI,EAAE;IAAE,IAAI,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;IAAC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;CAAE,GAAG;IAC/F,OAAO,EAAE,gBAAgB,CAAC;IAC1B,IAAI,EAAE,aAAa,CA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AAuB,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { GitConnector, __test, createConnector5 as createConnector, readGitSyncStatus } from '../../chunk-
|
|
1
|
+
export { GitConnector, __test, createConnector5 as createConnector, readGitSyncStatus } from '../../chunk-JCKGYBWY.js';
|
|
2
2
|
import '../../chunk-Y6FV73IH.js';
|
|
3
3
|
import '../../chunk-6E6PKKAD.js';
|
|
4
4
|
import '../../chunk-4N5XR5DQ.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { GmailConnector, createConnector6 as createConnector } from '../../chunk-
|
|
1
|
+
export { GmailConnector, createConnector6 as createConnector } from '../../chunk-JCKGYBWY.js';
|
|
2
2
|
import '../../chunk-Y6FV73IH.js';
|
|
3
3
|
import '../../chunk-6E6PKKAD.js';
|
|
4
4
|
import '../../chunk-4N5XR5DQ.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { GoogleDriveConnector, createConnector7 as createConnector } from '../../chunk-
|
|
1
|
+
export { GoogleDriveConnector, createConnector7 as createConnector } from '../../chunk-JCKGYBWY.js';
|
|
2
2
|
import '../../chunk-Y6FV73IH.js';
|
|
3
3
|
import '../../chunk-6E6PKKAD.js';
|
|
4
4
|
import '../../chunk-4N5XR5DQ.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { LocalConnector, createConnector8 as createConnector } from '../../chunk-
|
|
1
|
+
export { LocalConnector, createConnector8 as createConnector } from '../../chunk-JCKGYBWY.js';
|
|
2
2
|
import '../../chunk-Y6FV73IH.js';
|
|
3
3
|
import '../../chunk-6E6PKKAD.js';
|
|
4
4
|
import '../../chunk-4N5XR5DQ.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { MattermostConnector, createConnector9 as createConnector } from '../../chunk-
|
|
1
|
+
export { MattermostConnector, createConnector9 as createConnector } from '../../chunk-JCKGYBWY.js';
|
|
2
2
|
import '../../chunk-Y6FV73IH.js';
|
|
3
3
|
import '../../chunk-6E6PKKAD.js';
|
|
4
4
|
import '../../chunk-4N5XR5DQ.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { MemoryConnector, createConnector10 as createConnector } from '../../chunk-
|
|
1
|
+
export { MemoryConnector, createConnector10 as createConnector } from '../../chunk-JCKGYBWY.js';
|
|
2
2
|
import '../../chunk-Y6FV73IH.js';
|
|
3
3
|
import '../../chunk-6E6PKKAD.js';
|
|
4
4
|
import '../../chunk-4N5XR5DQ.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { MinIOConnector, createConnector11 as createConnector } from '../../chunk-
|
|
1
|
+
export { MinIOConnector, createConnector11 as createConnector } from '../../chunk-JCKGYBWY.js';
|
|
2
2
|
import '../../chunk-Y6FV73IH.js';
|
|
3
3
|
import '../../chunk-6E6PKKAD.js';
|
|
4
4
|
import '../../chunk-4N5XR5DQ.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { PostgresConnector, createConnector12 as createConnector } from '../../chunk-
|
|
1
|
+
export { PostgresConnector, createConnector12 as createConnector } from '../../chunk-JCKGYBWY.js';
|
|
2
2
|
import '../../chunk-Y6FV73IH.js';
|
|
3
3
|
import '../../chunk-6E6PKKAD.js';
|
|
4
4
|
import '../../chunk-4N5XR5DQ.js';
|