@yadsh/dsh-qa-surface 0.15.7 → 0.17.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +27 -2
- package/lib/access/capability-catalog.js +11 -4
- package/lib/access/capability-catalog.js.map +1 -1
- package/lib/access/service.js +46 -5
- package/lib/access/service.js.map +1 -1
- package/lib/account-remotes.js +9 -0
- package/lib/account-remotes.js.map +1 -1
- package/lib/accounts/database.js +34 -3
- package/lib/accounts/database.js.map +1 -1
- package/lib/accounts/store.js +22 -2
- package/lib/accounts/store.js.map +1 -1
- package/lib/admin/service.js +4 -2
- package/lib/admin/service.js.map +1 -1
- package/lib/admin/session-log.js +3 -0
- package/lib/admin/session-log.js.map +1 -1
- package/lib/agent-scope.js +9 -0
- package/lib/agent-scope.js.map +1 -0
- package/lib/chat-sharing/native-fence.js +120 -0
- package/lib/chat-sharing/native-fence.js.map +1 -0
- package/lib/chat-sharing/resources.js +57 -0
- package/lib/chat-sharing/resources.js.map +1 -0
- package/lib/chat-sharing/store.js +199 -0
- package/lib/chat-sharing/store.js.map +1 -0
- package/lib/chat-sharing/transport.js +329 -0
- package/lib/chat-sharing/transport.js.map +1 -0
- package/lib/chat-sharing/turn-guard.js +154 -0
- package/lib/chat-sharing/turn-guard.js.map +1 -0
- package/lib/chat-sharing/types.js +2 -0
- package/lib/chat-sharing/types.js.map +1 -0
- package/lib/chat-sharing/uploads.js +55 -0
- package/lib/chat-sharing/uploads.js.map +1 -0
- package/lib/client/QaAccountsController.js +47 -2
- package/lib/client/QaAccountsController.js.map +1 -1
- package/lib/client/QaConfigController.js +7 -12
- package/lib/client/QaConfigController.js.map +1 -1
- package/lib/client/QaSessionController.js +195 -19
- package/lib/client/QaSessionController.js.map +1 -1
- package/lib/client/QaSurface.js +156 -14
- package/lib/client/QaSurface.js.map +1 -1
- package/lib/client/QaSurfaceGuard.js +6 -1
- package/lib/client/QaSurfaceGuard.js.map +1 -1
- package/lib/client/QaTranscriptAdapter.js +28 -5
- package/lib/client/QaTranscriptAdapter.js.map +1 -1
- package/lib/client/account-conversation.js +33 -0
- package/lib/client/account-conversation.js.map +1 -0
- package/lib/client/account-sessions.js +106 -0
- package/lib/client/account-sessions.js.map +1 -0
- package/lib/client/account-upload.js +30 -0
- package/lib/client/account-upload.js.map +1 -0
- package/lib/client/answer-review.js +89 -0
- package/lib/client/answer-review.js.map +1 -0
- package/lib/client/chat-artifacts.js +18 -3
- package/lib/client/chat-artifacts.js.map +1 -1
- package/lib/client/chat-sharing-api.js +2 -0
- package/lib/client/chat-sharing-api.js.map +1 -0
- package/lib/client/components/QaAnswerReviewStatus.js +45 -0
- package/lib/client/components/QaAnswerReviewStatus.js.map +1 -0
- package/lib/client/components/QaChangelog.js +92 -3
- package/lib/client/components/QaChangelog.js.map +1 -1
- package/lib/client/components/QaChatActions.js +52 -0
- package/lib/client/components/QaChatActions.js.map +1 -0
- package/lib/client/components/QaChatSharing.js +95 -0
- package/lib/client/components/QaChatSharing.js.map +1 -0
- package/lib/client/components/QaComposer.js +8 -4
- package/lib/client/components/QaComposer.js.map +1 -1
- package/lib/client/components/QaFileAttachment.js +12 -3
- package/lib/client/components/QaFileAttachment.js.map +1 -1
- package/lib/client/components/QaFilesPanel.js +11 -4
- package/lib/client/components/QaFilesPanel.js.map +1 -1
- package/lib/client/components/QaHeader.js +3 -3
- package/lib/client/components/QaHeader.js.map +1 -1
- package/lib/client/components/QaMarkdownPreview.js +86 -0
- package/lib/client/components/QaMarkdownPreview.js.map +1 -0
- package/lib/client/components/QaMessage.js +41 -10
- package/lib/client/components/QaMessage.js.map +1 -1
- package/lib/client/components/QaModal.js +17 -0
- package/lib/client/components/QaModal.js.map +1 -1
- package/lib/client/components/QaRightRail.js +6 -4
- package/lib/client/components/QaRightRail.js.map +1 -1
- package/lib/client/components/QaRightRailResize.js +129 -0
- package/lib/client/components/QaRightRailResize.js.map +1 -0
- package/lib/client/components/QaSidebar.js +11 -2
- package/lib/client/components/QaSidebar.js.map +1 -1
- package/lib/client/components/QaSourceFilters.js +22 -0
- package/lib/client/components/QaSourceFilters.js.map +1 -0
- package/lib/client/components/QaSourcesPanel.js +66 -14
- package/lib/client/components/QaSourcesPanel.js.map +1 -1
- package/lib/client/components/QaSpreadsheetPreview.js +56 -0
- package/lib/client/components/QaSpreadsheetPreview.js.map +1 -0
- package/lib/client/components/QaWelcomeNotice.js +2 -2
- package/lib/client/components/QaWelcomeNotice.js.map +1 -1
- package/lib/client/components/QaWorkspaceBrowser.js +46 -12
- package/lib/client/components/QaWorkspaceBrowser.js.map +1 -1
- package/lib/client/components/QaZoomImage.js +56 -0
- package/lib/client/components/QaZoomImage.js.map +1 -0
- package/lib/client/components/source-refs.js +57 -24
- package/lib/client/components/source-refs.js.map +1 -1
- package/lib/client/index.js +76 -8
- package/lib/client/index.js.map +1 -1
- package/lib/client/lineage.js +4 -3
- package/lib/client/lineage.js.map +1 -1
- package/lib/client/markdown/SourceImage.js +52 -0
- package/lib/client/markdown/SourceImage.js.map +1 -0
- package/lib/client/markdown/blocks.js +150 -115
- package/lib/client/markdown/blocks.js.map +1 -1
- package/lib/client/markdown/katex-css.js +1 -1
- package/lib/client/markdown/render.js +26 -9
- package/lib/client/markdown/render.js.map +1 -1
- package/lib/client/markdown/source-chip.js +6 -2
- package/lib/client/markdown/source-chip.js.map +1 -1
- package/lib/client/notifications/notification-dispatcher.js +50 -11
- package/lib/client/notifications/notification-dispatcher.js.map +1 -1
- package/lib/client/notifications/use-turn-notifications.js +107 -18
- package/lib/client/notifications/use-turn-notifications.js.map +1 -1
- package/lib/client/project-session-state.js +28 -13
- package/lib/client/project-session-state.js.map +1 -1
- package/lib/client/session-admission.js +9 -1
- package/lib/client/session-admission.js.map +1 -1
- package/lib/client/session-sources.js +44 -3
- package/lib/client/session-sources.js.map +1 -1
- package/lib/client/settings/sections/sources.js +1 -1
- package/lib/client/settings/sections/sources.js.map +1 -1
- package/lib/client/settings/styles.js +18 -28
- package/lib/client/settings/styles.js.map +1 -1
- package/lib/client/slash/useSlashNavigation.js +8 -5
- package/lib/client/slash/useSlashNavigation.js.map +1 -1
- package/lib/client/source-filters-styles.js +11 -0
- package/lib/client/source-filters-styles.js.map +1 -0
- package/lib/client/source-preview.js +1 -1
- package/lib/client/source-preview.js.map +1 -1
- package/lib/client/styles.js +62 -4
- package/lib/client/styles.js.map +1 -1
- package/lib/client/turn-sources.js +2 -1
- package/lib/client/turn-sources.js.map +1 -1
- package/lib/client/types.js.map +1 -1
- package/lib/client/use-right-rail.js +1 -1
- package/lib/client/use-right-rail.js.map +1 -1
- package/lib/client/user-settings/IntegrationTokensPage.js +30 -6
- package/lib/client/user-settings/IntegrationTokensPage.js.map +1 -1
- package/lib/client/workspace-download.js +42 -2
- package/lib/client/workspace-download.js.map +1 -1
- package/lib/client.js +6481 -2234
- package/lib/client.js.map +1 -1
- package/lib/config-resolvers/defaults.js +4 -3
- package/lib/config-resolvers/defaults.js.map +1 -1
- package/lib/config-resolvers/sources.js +2 -0
- package/lib/config-resolvers/sources.js.map +1 -1
- package/lib/config.js +3 -0
- package/lib/config.js.map +1 -1
- package/lib/enforcement/skill-policy.js +29 -4
- package/lib/enforcement/skill-policy.js.map +1 -1
- package/lib/enforcement/skill-resource-paths.js +32 -0
- package/lib/enforcement/skill-resource-paths.js.map +1 -0
- package/lib/enforcement/structured-result.js +38 -0
- package/lib/enforcement/structured-result.js.map +1 -0
- package/lib/enforcement/tool-grants.js +3 -1
- package/lib/enforcement/tool-grants.js.map +1 -1
- package/lib/index.js +447 -17
- package/lib/index.js.map +1 -1
- package/lib/integration/host-runner.js +1 -0
- package/lib/integration/host-runner.js.map +1 -1
- package/lib/integration/question-policy.js +126 -0
- package/lib/integration/question-policy.js.map +1 -0
- package/lib/integration/service.js +2 -0
- package/lib/integration/service.js.map +1 -1
- package/lib/llm-identity.js +27 -0
- package/lib/llm-identity.js.map +1 -0
- package/lib/markdown-frontmatter.js +47 -0
- package/lib/markdown-frontmatter.js.map +1 -0
- package/lib/markdown-images.js +33 -0
- package/lib/markdown-images.js.map +1 -0
- package/lib/prompt-notes.js +19 -2
- package/lib/prompt-notes.js.map +1 -1
- package/lib/provenance/collector.js +15 -1
- package/lib/provenance/collector.js.map +1 -1
- package/lib/provenance/connectors.js +57 -27
- package/lib/provenance/connectors.js.map +1 -1
- package/lib/provenance/dedupe.js +25 -1
- package/lib/provenance/dedupe.js.map +1 -1
- package/lib/provenance/document-preview.js +31 -3
- package/lib/provenance/document-preview.js.map +1 -1
- package/lib/provenance/extractors.js +88 -4
- package/lib/provenance/extractors.js.map +1 -1
- package/lib/provenance/file-download.js +56 -0
- package/lib/provenance/file-download.js.map +1 -0
- package/lib/provenance/file-preview.js +20 -2
- package/lib/provenance/file-preview.js.map +1 -1
- package/lib/provenance/host-store.js +59 -10
- package/lib/provenance/host-store.js.map +1 -1
- package/lib/provenance/integration-extractor.js +62 -0
- package/lib/provenance/integration-extractor.js.map +1 -0
- package/lib/provenance/snapshot-store.js +2 -0
- package/lib/provenance/snapshot-store.js.map +1 -1
- package/lib/provenance/source-content.js +103 -0
- package/lib/provenance/source-content.js.map +1 -0
- package/lib/provenance/source-image.js +57 -0
- package/lib/provenance/source-image.js.map +1 -0
- package/lib/provenance/spreadsheet-preview.js +52 -0
- package/lib/provenance/spreadsheet-preview.js.map +1 -0
- package/lib/qa-tools/docs-tools.js +14 -0
- package/lib/qa-tools/docs-tools.js.map +1 -1
- package/lib/questions.js +6 -1
- package/lib/questions.js.map +1 -1
- package/lib/secure-session.js +9 -3
- package/lib/secure-session.js.map +1 -1
- package/lib/session-fork-host.js +157 -0
- package/lib/session-fork-host.js.map +1 -0
- package/lib/session-fork.js +34 -0
- package/lib/session-fork.js.map +1 -0
- package/lib/session-ownership.js +5 -1
- package/lib/session-ownership.js.map +1 -1
- package/lib/shared/documents.js +12 -0
- package/lib/shared/documents.js.map +1 -1
- package/lib/shared/session-lineage.js +6 -0
- package/lib/shared/session-lineage.js.map +1 -0
- package/lib/slash/draft-target.js +21 -0
- package/lib/slash/draft-target.js.map +1 -0
- package/lib/slash/remotes.js +39 -4
- package/lib/slash/remotes.js.map +1 -1
- package/lib/typert.host.js +1869 -163
- package/lib/typert.remote-client.d.ts +56 -5
- package/lib/typert.remote-client.js +1678 -154
- package/lib/types/access/capability-catalog.d.ts +1 -1
- package/lib/types/access/service.d.ts +7 -0
- package/lib/types/access.js +2 -0
- package/lib/types/access.js.map +1 -0
- package/lib/types/account-remotes.d.ts +3 -0
- package/lib/types/accounts/database.d.ts +5 -0
- package/lib/types/accounts/store.d.ts +7 -2
- package/lib/types/accounts.js +2 -0
- package/lib/types/accounts.js.map +1 -0
- package/lib/types/admin/session-log.d.ts +2 -0
- package/lib/types/admin.js +2 -0
- package/lib/types/admin.js.map +1 -0
- package/lib/types/agent-scope.d.ts +4 -0
- package/lib/types/answer-review.js +2 -0
- package/lib/types/answer-review.js.map +1 -0
- package/lib/types/capability.js +2 -0
- package/lib/types/capability.js.map +1 -0
- package/lib/types/chat-sharing/native-fence.d.ts +11 -0
- package/lib/types/chat-sharing/resources.d.ts +5 -0
- package/lib/types/chat-sharing/store.d.ts +29 -0
- package/lib/types/chat-sharing/transport.d.ts +32 -0
- package/lib/types/chat-sharing/turn-guard.d.ts +21 -0
- package/lib/types/chat-sharing/types.d.ts +25 -0
- package/lib/types/chat-sharing/uploads.d.ts +5 -0
- package/lib/types/client/QaAccountsController.d.ts +4 -0
- package/lib/types/client/QaConfigController.d.ts +3 -2
- package/lib/types/client/QaSessionController.d.ts +17 -3
- package/lib/types/client/QaSurface.d.ts +6 -1
- package/lib/types/client/account-conversation.d.ts +6 -0
- package/lib/types/client/account-sessions.d.ts +7 -0
- package/lib/types/client/account-upload.d.ts +15 -0
- package/lib/types/client/answer-review.d.ts +16 -0
- package/lib/types/client/chat-sharing-api.d.ts +35 -0
- package/lib/types/client/components/QaAnswerReviewStatus.d.ts +8 -0
- package/lib/types/client/components/QaChatActions.d.ts +7 -0
- package/lib/types/client/components/QaChatSharing.d.ts +12 -0
- package/lib/types/client/components/QaComposer.d.ts +2 -0
- package/lib/types/client/components/QaFileAttachment.d.ts +3 -2
- package/lib/types/client/components/QaFilesPanel.d.ts +4 -1
- package/lib/types/client/components/QaMarkdownPreview.d.ts +13 -0
- package/lib/types/client/components/QaMessage.d.ts +5 -2
- package/lib/types/client/components/QaModal.d.ts +9 -0
- package/lib/types/client/components/QaRightRail.d.ts +3 -2
- package/lib/types/client/components/QaRightRailResize.d.ts +9 -0
- package/lib/types/client/components/QaSidebar.d.ts +2 -0
- package/lib/types/client/components/QaSourceFilters.d.ts +12 -0
- package/lib/types/client/components/QaSpreadsheetPreview.d.ts +8 -0
- package/lib/types/client/components/QaWelcomeNotice.d.ts +1 -1
- package/lib/types/client/components/QaWorkspaceBrowser.d.ts +8 -1
- package/lib/types/client/components/QaZoomImage.d.ts +38 -0
- package/lib/types/client/components/source-refs.d.ts +1 -0
- package/lib/types/client/lineage.d.ts +2 -2
- package/lib/types/client/markdown/SourceImage.d.ts +7 -0
- package/lib/types/client/markdown/blocks.d.ts +8 -1
- package/lib/types/client/markdown/render.d.ts +5 -1
- package/lib/types/client/markdown/source-chip.d.ts +1 -0
- package/lib/types/client/notifications/notification-dispatcher.d.ts +10 -6
- package/lib/types/client/notifications/use-turn-notifications.d.ts +4 -0
- package/lib/types/client/project-session-state.d.ts +1 -0
- package/lib/types/client/session-admission.d.ts +2 -0
- package/lib/types/client/session-sources.d.ts +1 -0
- package/lib/types/client/settings/styles.d.ts +2 -5
- package/lib/types/client/source-filters-styles.d.ts +2 -0
- package/lib/types/client/turn-sources.d.ts +1 -1
- package/lib/types/client/types.d.ts +18 -5
- package/lib/types/client/workspace-download.d.ts +9 -1
- package/lib/types/config.js +2 -0
- package/lib/types/config.js.map +1 -0
- package/lib/types/documents.js +2 -0
- package/lib/types/documents.js.map +1 -0
- package/lib/types/enforcement/skill-resource-paths.d.ts +5 -0
- package/lib/types/enforcement/structured-result.d.ts +11 -0
- package/lib/types/expert-memory.js +2 -0
- package/lib/types/expert-memory.js.map +1 -0
- package/lib/types/index.d.ts +42 -3
- package/lib/types/integration/contract.d.ts +1 -0
- package/lib/types/integration/question-policy.d.ts +20 -0
- package/lib/types/integration/service.d.ts +1 -0
- package/lib/types/llm-identity.d.ts +20 -0
- package/lib/types/markdown-frontmatter.d.ts +10 -0
- package/lib/types/markdown-images.d.ts +3 -0
- package/lib/types/policy.js +2 -0
- package/lib/types/policy.js.map +1 -0
- package/lib/types/prompt-notes.d.ts +3 -1
- package/lib/types/provenance/connectors.d.ts +4 -1
- package/lib/types/provenance/document-preview.d.ts +5 -2
- package/lib/types/provenance/extractors.d.ts +2 -0
- package/lib/types/provenance/file-download.d.ts +10 -0
- package/lib/types/provenance/file-preview.d.ts +2 -1
- package/lib/types/provenance/host-store.d.ts +2 -0
- package/lib/types/provenance/integration-extractor.d.ts +5 -0
- package/lib/types/provenance/source-content.d.ts +19 -0
- package/lib/types/provenance/source-image.d.ts +4 -0
- package/lib/types/provenance/spreadsheet-preview.d.ts +5 -0
- package/lib/types/provenance/types.d.ts +5 -0
- package/lib/types/qa-tools/docs-tools.d.ts +2 -0
- package/lib/types/quality.js +7 -0
- package/lib/types/quality.js.map +1 -0
- package/lib/types/questions.d.ts +2 -1
- package/lib/types/session-fork-host.d.ts +27 -0
- package/lib/types/session-fork.d.ts +7 -0
- package/lib/types/session.js +2 -0
- package/lib/types/session.js.map +1 -0
- package/lib/types/shared/documents.d.ts +2 -0
- package/lib/types/shared/session-lineage.d.ts +7 -0
- package/lib/types/skills.js +2 -0
- package/lib/types/skills.js.map +1 -0
- package/lib/types/slash/draft-target.d.ts +7 -0
- package/lib/types/slash/remotes.d.ts +7 -0
- package/lib/types/slash.js +2 -0
- package/lib/types/slash.js.map +1 -0
- package/lib/types/types/access.d.ts +43 -0
- package/lib/types/types/accounts.d.ts +177 -0
- package/lib/types/types/admin.d.ts +286 -0
- package/lib/types/types/answer-review.d.ts +11 -0
- package/lib/types/types/capability.d.ts +230 -0
- package/lib/types/types/config.d.ts +597 -0
- package/lib/types/types/documents.d.ts +34 -0
- package/lib/types/types/expert-memory.d.ts +35 -0
- package/lib/types/types/policy.d.ts +54 -0
- package/lib/types/types/quality.d.ts +100 -0
- package/lib/types/types/session.d.ts +397 -0
- package/lib/types/types/skills.d.ts +143 -0
- package/lib/types/types/slash.d.ts +159 -0
- package/lib/types/types.d.ts +14 -2180
- package/package.json +8 -7
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Why one skill draft cannot be saved, or why it saves with a caveat. Codes
|
|
3
|
+
* stay stable on the wire; the browser owns the Russian copy.
|
|
4
|
+
*/
|
|
5
|
+
export type QaSkillDiagnosticCode = "name-required" | "name-invalid" | "name-mismatch" | "description-required" | "description-too-long" | "when-to-use-too-long" | "field-type-invalid" | "invocation-never" | "invocation-invalid" | "invocation-legacy-key" | "allowed-tools-invalid" | "tool-name-invalid" | "tool-unavailable" | "tools-too-many" | "file-too-large" | "frontmatter-missing" | "skill-file-missing" | "skill-file-truncated" | "frontmatter-invalid" | "unknown-field" | "resource-unsupported";
|
|
6
|
+
/** One finding about a skill file or an editor draft. */
|
|
7
|
+
export interface QaSkillDiagnostic {
|
|
8
|
+
readonly code: QaSkillDiagnosticCode;
|
|
9
|
+
readonly severity: "error" | "warning";
|
|
10
|
+
/** The editor field the message belongs to, or null for a file-wide one. */
|
|
11
|
+
readonly field: string | null;
|
|
12
|
+
/** The offending value: a tool name, a frontmatter key, a limit. */
|
|
13
|
+
readonly detail: string | null;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* A JSON-representable frontmatter value. The editor receives the preserved
|
|
17
|
+
* foreign fields verbatim over the Host bridge, which carries JSON only, so
|
|
18
|
+
* the parser drops anything a YAML document can hold but JSON cannot.
|
|
19
|
+
*/
|
|
20
|
+
export type QaSkillJsonValue = string | number | boolean | null | readonly QaSkillJsonValue[] | {
|
|
21
|
+
readonly [key: string]: QaSkillJsonValue;
|
|
22
|
+
};
|
|
23
|
+
/** One personal skill as the catalog list renders it. */
|
|
24
|
+
/**
|
|
25
|
+
* One administrator write to a skill somebody else owns.
|
|
26
|
+
*
|
|
27
|
+
* The record exists so a personal skill cannot be changed behind its owner's
|
|
28
|
+
* back: it is written beside the skill and reported on every read, and the
|
|
29
|
+
* owner sees the badge in their own catalog.
|
|
30
|
+
*/
|
|
31
|
+
export interface QaSkillAdminEdit {
|
|
32
|
+
/** Administrator account id; the owner is told a role, not a colleague. */
|
|
33
|
+
readonly actorId: string;
|
|
34
|
+
/** ISO timestamp of that write. */
|
|
35
|
+
readonly at: string;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Which skill store an administrator is editing: the deployment-wide shared
|
|
39
|
+
* root every account may read, or one account's own directory.
|
|
40
|
+
*/
|
|
41
|
+
export type QaAdminSkillScope = {
|
|
42
|
+
readonly kind: "shared";
|
|
43
|
+
} | {
|
|
44
|
+
readonly kind: "user";
|
|
45
|
+
readonly userId: string;
|
|
46
|
+
};
|
|
47
|
+
/** The account a personal skill scope belongs to, for the console's header. */
|
|
48
|
+
export interface QaAdminSkillOwner {
|
|
49
|
+
readonly userId: string;
|
|
50
|
+
readonly email: string;
|
|
51
|
+
readonly displayName: string;
|
|
52
|
+
}
|
|
53
|
+
/** One scope's catalog plus the facts the console names it by. */
|
|
54
|
+
export interface QaAdminSkillsView {
|
|
55
|
+
readonly scope: QaAdminSkillScope;
|
|
56
|
+
/** The account of a personal scope; null for the shared root. */
|
|
57
|
+
readonly owner: QaAdminSkillOwner | null;
|
|
58
|
+
readonly skills: readonly QaSkillSummary[];
|
|
59
|
+
/** Absolute directory this scope reads and writes, rendered read-only. */
|
|
60
|
+
readonly rootPath: string;
|
|
61
|
+
}
|
|
62
|
+
export interface QaSkillSummary {
|
|
63
|
+
readonly name: string;
|
|
64
|
+
readonly description: string;
|
|
65
|
+
readonly whenToUse: string | null;
|
|
66
|
+
readonly modelInvocable: boolean;
|
|
67
|
+
readonly userInvocable: boolean;
|
|
68
|
+
/** Declared tools, in canonical order; unknown ones included. */
|
|
69
|
+
readonly allowedTools: readonly string[];
|
|
70
|
+
/** Declared tools the current QA scope cannot use; still stored as declared. */
|
|
71
|
+
readonly unavailableTools: readonly string[];
|
|
72
|
+
/** Entries in the skill directory besides SKILL.md (references, assets, …). */
|
|
73
|
+
readonly resourceCount: number;
|
|
74
|
+
readonly valid: boolean;
|
|
75
|
+
readonly diagnostics: readonly QaSkillDiagnostic[];
|
|
76
|
+
readonly updatedAt: string | null;
|
|
77
|
+
/** sha256 of the stored bytes; an update must echo the revision it read. */
|
|
78
|
+
readonly revision: string;
|
|
79
|
+
/**
|
|
80
|
+
* The administrator write that produced the stored revision, or null. A
|
|
81
|
+
* record whose revision no longer matches is stale and reports as null: the
|
|
82
|
+
* badge answers "did an administrator write what I am looking at", not
|
|
83
|
+
* "was this skill ever touched by an administrator".
|
|
84
|
+
*/
|
|
85
|
+
readonly adminEdit: QaSkillAdminEdit | null;
|
|
86
|
+
}
|
|
87
|
+
/** One personal skill with everything the editor needs. */
|
|
88
|
+
export interface QaSkillDocument extends QaSkillSummary {
|
|
89
|
+
readonly body: string;
|
|
90
|
+
/** Frontmatter the editor preserves but does not own. */
|
|
91
|
+
readonly extraFrontmatter: Readonly<Record<string, QaSkillJsonValue>>;
|
|
92
|
+
/** Absolute SKILL.md path; rendered read-only for advanced users. */
|
|
93
|
+
readonly sourcePath: string;
|
|
94
|
+
/** The canonical file the serializer writes, built from the parsed content. */
|
|
95
|
+
readonly preview: string;
|
|
96
|
+
/**
|
|
97
|
+
* True when the stored file is larger than the Host's read ceiling, so `body`
|
|
98
|
+
* and `preview` describe its head only. A save over such a document erases
|
|
99
|
+
* the unread tail, and the Host refuses it until the client confirms.
|
|
100
|
+
*/
|
|
101
|
+
readonly truncated: boolean;
|
|
102
|
+
}
|
|
103
|
+
/** One tool the picker can offer, with this deployment's availability. */
|
|
104
|
+
export interface QaSkillToolDescriptor {
|
|
105
|
+
readonly name: string;
|
|
106
|
+
readonly description: string;
|
|
107
|
+
/** False when the QA session's own scope cannot use the tool. */
|
|
108
|
+
readonly available: boolean;
|
|
109
|
+
}
|
|
110
|
+
/** The editor's save payload. */
|
|
111
|
+
export interface QaSkillDraftInput {
|
|
112
|
+
readonly name: string;
|
|
113
|
+
readonly description: string;
|
|
114
|
+
readonly whenToUse: string | null;
|
|
115
|
+
readonly modelInvocable: boolean;
|
|
116
|
+
readonly userInvocable: boolean;
|
|
117
|
+
readonly allowedTools: readonly string[];
|
|
118
|
+
readonly body: string;
|
|
119
|
+
/** Echo of the revision the editor read; a stale one is refused. */
|
|
120
|
+
readonly expectedRevision: string | null;
|
|
121
|
+
/**
|
|
122
|
+
* The client's acknowledgement that it is saving from an incomplete copy: the
|
|
123
|
+
* stored `SKILL.md` is over the read ceiling, so the draft carries the head
|
|
124
|
+
* of the file and a save would drop everything the read never loaded. A write
|
|
125
|
+
* without it is refused.
|
|
126
|
+
*/
|
|
127
|
+
readonly confirmPartialOverwrite?: boolean;
|
|
128
|
+
}
|
|
129
|
+
/**
|
|
130
|
+
* The Host's answer about one unsaved draft: the file a save would write and
|
|
131
|
+
* the diagnostics it found. The editor shows its own subset immediately and
|
|
132
|
+
* this authoritative set as soon as it arrives.
|
|
133
|
+
*/
|
|
134
|
+
export interface QaSkillValidation {
|
|
135
|
+
readonly preview: string;
|
|
136
|
+
readonly diagnostics: readonly QaSkillDiagnostic[];
|
|
137
|
+
}
|
|
138
|
+
/** What one delete did: v1 keeps the directory recoverable. */
|
|
139
|
+
export interface QaSkillRemoval {
|
|
140
|
+
readonly name: string;
|
|
141
|
+
readonly trashed: boolean;
|
|
142
|
+
}
|
|
143
|
+
//# sourceMappingURL=skills.d.ts.map
|
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
import type { QaImageMediaType } from "./session.js";
|
|
2
|
+
/** Which native registry one unified entry came from. */
|
|
3
|
+
export type QaSlashEntryKind = "skill" | "command";
|
|
4
|
+
/** How one half of the catalog admits native entries. */
|
|
5
|
+
export type QaSlashPolicyMode = "deny-all" | "allow-list" | "all";
|
|
6
|
+
export interface QaSlashPolicyConfig {
|
|
7
|
+
readonly mode?: QaSlashPolicyMode;
|
|
8
|
+
readonly allow?: readonly string[];
|
|
9
|
+
}
|
|
10
|
+
export interface QaSlashPaletteConfig {
|
|
11
|
+
readonly enabled?: boolean;
|
|
12
|
+
/** Run the two weakest matcher rungs (substring, subsequence). */
|
|
13
|
+
readonly fuzzySearch?: boolean;
|
|
14
|
+
readonly maxVisible?: number;
|
|
15
|
+
readonly showDescriptions?: boolean;
|
|
16
|
+
readonly showKindBadge?: boolean;
|
|
17
|
+
}
|
|
18
|
+
export interface QaSlashCommandsConfig {
|
|
19
|
+
readonly skills?: QaSlashPolicyConfig;
|
|
20
|
+
readonly commands?: QaSlashPolicyConfig;
|
|
21
|
+
readonly palette?: QaSlashPaletteConfig;
|
|
22
|
+
}
|
|
23
|
+
export interface ResolvedQaSlashCommands {
|
|
24
|
+
/** Mirror of `lockdown.allowSlashCommands`; the one master switch. */
|
|
25
|
+
readonly enabled: boolean;
|
|
26
|
+
readonly skills: {
|
|
27
|
+
readonly mode: QaSlashPolicyMode;
|
|
28
|
+
readonly allow: readonly string[];
|
|
29
|
+
};
|
|
30
|
+
readonly commands: {
|
|
31
|
+
readonly mode: QaSlashPolicyMode;
|
|
32
|
+
readonly allow: readonly string[];
|
|
33
|
+
};
|
|
34
|
+
readonly palette: {
|
|
35
|
+
readonly enabled: boolean;
|
|
36
|
+
readonly fuzzySearch: boolean;
|
|
37
|
+
readonly maxVisible: number;
|
|
38
|
+
readonly showDescriptions: boolean;
|
|
39
|
+
readonly showKindBadge: boolean;
|
|
40
|
+
};
|
|
41
|
+
/**
|
|
42
|
+
* True when the deployment turned the master switch on without declaring a
|
|
43
|
+
* `slashCommands` section: skills then admit every user-invocable skill the
|
|
44
|
+
* session already exposes, commands stay denied. The Host logs it once, so
|
|
45
|
+
* an upgrade cannot silently widen anything.
|
|
46
|
+
*/
|
|
47
|
+
readonly legacyDefaults: boolean;
|
|
48
|
+
}
|
|
49
|
+
/**
|
|
50
|
+
* One palette row. `id` is the routing identity: skill and command may share a
|
|
51
|
+
* name, so identity is `skill:<name>` or `command:<name>` and never the bare
|
|
52
|
+
* name the two halves would collide on.
|
|
53
|
+
*/
|
|
54
|
+
export interface QaSlashCatalogEntry {
|
|
55
|
+
readonly id: string;
|
|
56
|
+
readonly kind: QaSlashEntryKind;
|
|
57
|
+
readonly name: string;
|
|
58
|
+
readonly description: string;
|
|
59
|
+
/** Skill-only: the native `whenToUse`, rendered as secondary copy. */
|
|
60
|
+
readonly whenToUse?: string;
|
|
61
|
+
/** Skill-only: whether the model is also offered this skill. */
|
|
62
|
+
readonly modelInvocable?: boolean;
|
|
63
|
+
/** Command-only: the advertised argument shape. */
|
|
64
|
+
readonly inputHint?: string;
|
|
65
|
+
/** Command-only: whether the executor admits composer attachments. */
|
|
66
|
+
readonly acceptsAttachments?: boolean;
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* Whether the command half of the catalog could be read. `inactive` is the
|
|
70
|
+
* ordinary state of a cold chat: the native command registry resolves through
|
|
71
|
+
* a live Agent, and a chat with none answers with no commands rather than an
|
|
72
|
+
* error — the palette then offers skills alone.
|
|
73
|
+
*/
|
|
74
|
+
export type QaSlashCommandSurface = "ready" | "unavailable" | "inactive";
|
|
75
|
+
export interface QaSlashCatalog {
|
|
76
|
+
/** False while `lockdown.allowSlashCommands` is off. */
|
|
77
|
+
readonly enabled: boolean;
|
|
78
|
+
readonly entries: readonly QaSlashCatalogEntry[];
|
|
79
|
+
readonly commandSurface: QaSlashCommandSurface;
|
|
80
|
+
/**
|
|
81
|
+
* User-invocable skills of this chat that the deployment or the chat's role
|
|
82
|
+
* withheld from the palette. Naming them is what lets the browser warn about
|
|
83
|
+
* a `/name` typed inside an ordinary prompt — the native gesture path never
|
|
84
|
+
* consults this list, so it is a courtesy, not an authorization.
|
|
85
|
+
*/
|
|
86
|
+
readonly deniedSkills: readonly string[];
|
|
87
|
+
}
|
|
88
|
+
/**
|
|
89
|
+
* One composer attachment offered to a human command. The same two shapes the
|
|
90
|
+
* prompt path uses — an image rides inline, a file rides its staged receipt —
|
|
91
|
+
* because the native executor admits both through one attachment store.
|
|
92
|
+
*/
|
|
93
|
+
export type QaSlashSubmitAttachment = {
|
|
94
|
+
readonly type: "image";
|
|
95
|
+
readonly mediaType: QaImageMediaType;
|
|
96
|
+
readonly data: string;
|
|
97
|
+
readonly name?: string;
|
|
98
|
+
} | {
|
|
99
|
+
readonly type: "file";
|
|
100
|
+
readonly receiptId: string;
|
|
101
|
+
};
|
|
102
|
+
/** Why a command line was refused before, or instead of, running. */
|
|
103
|
+
export type QaSlashRefusal = "slash-disabled" | "unknown-command" | "not-allowed" | "attachments-unsupported" | "inactive-session";
|
|
104
|
+
export type QaSlashCommandOutcome = {
|
|
105
|
+
readonly kind: "success";
|
|
106
|
+
readonly text?: string;
|
|
107
|
+
/** Earlier authoritative event this result is presented from. */
|
|
108
|
+
readonly sourceEventSeq?: number;
|
|
109
|
+
} | {
|
|
110
|
+
readonly kind: "error";
|
|
111
|
+
readonly text: string;
|
|
112
|
+
};
|
|
113
|
+
/**
|
|
114
|
+
* The result of one admitted command. `refused` is an admission decision and
|
|
115
|
+
* costs nothing; `executed` means the native runtime ran the handler and the
|
|
116
|
+
* lifecycle is already in the session log, which is what the transcript row
|
|
117
|
+
* projects.
|
|
118
|
+
*/
|
|
119
|
+
export type QaSlashExecution = {
|
|
120
|
+
readonly kind: "executed";
|
|
121
|
+
readonly commandId: string;
|
|
122
|
+
readonly outcome: QaSlashCommandOutcome;
|
|
123
|
+
} | {
|
|
124
|
+
readonly kind: "refused";
|
|
125
|
+
readonly reason: QaSlashRefusal;
|
|
126
|
+
/** Host-authored detail; the browser renders its own copy for `reason`. */
|
|
127
|
+
readonly message: string;
|
|
128
|
+
};
|
|
129
|
+
/** One entry of the palette the browser is filtering. */
|
|
130
|
+
export interface QaSlashView {
|
|
131
|
+
readonly enabled: boolean;
|
|
132
|
+
readonly state: "idle" | "loading" | "ready" | "error";
|
|
133
|
+
readonly entries: readonly QaSlashCatalogEntry[];
|
|
134
|
+
readonly commandSurface: QaSlashCommandSurface;
|
|
135
|
+
readonly deniedSkills: readonly string[];
|
|
136
|
+
/** Set when the catalog could not be read; ordinary prompts keep working. */
|
|
137
|
+
readonly error: string | null;
|
|
138
|
+
/**
|
|
139
|
+
* Bumped when the surface must re-open a palette the user had dismissed —
|
|
140
|
+
* an ambiguous `/name` is the case that needs it. The composer watches the
|
|
141
|
+
* counter rather than the message, so a refusal can be re-stated.
|
|
142
|
+
*/
|
|
143
|
+
readonly reopen: number;
|
|
144
|
+
}
|
|
145
|
+
/**
|
|
146
|
+
* One human command line projected into the transcript. Commands never enter
|
|
147
|
+
* the model conversation, so this row is their only visible trace; it is a
|
|
148
|
+
* control row, not an assistant bubble.
|
|
149
|
+
*/
|
|
150
|
+
export interface QaCommandActivity {
|
|
151
|
+
readonly commandId: string;
|
|
152
|
+
readonly name: string;
|
|
153
|
+
/** Verbatim text after the name, with its separator whitespace removed. */
|
|
154
|
+
readonly args?: string;
|
|
155
|
+
readonly state: "running" | "success" | "error";
|
|
156
|
+
readonly resultText?: string;
|
|
157
|
+
readonly sourceEventSeq?: number;
|
|
158
|
+
}
|
|
159
|
+
//# sourceMappingURL=slash.d.ts.map
|