@makinbakin/sdk 0.0.1-rc.1 → 0.0.1-rc.11
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 +1 -0
- package/_internal/app/components/agent-select.d.ts +7 -2
- package/_internal/app/components/ui/button.d.ts +1 -1
- package/_internal/app/hooks/use-content-store.d.ts +2 -0
- package/_internal/app/hooks/use-nav-badge.d.ts +13 -0
- package/_internal/app/types/index.d.ts +2 -42
- package/_internal/core/adapters/runtime/concepts.d.ts +102 -1
- package/_internal/core/adapters/runtime/index.d.ts +1 -1
- package/_internal/core/plugin-types.d.ts +102 -32
- package/_internal/plugins/team/types.d.ts +12 -2
- package/components/index.d.ts +37 -2
- package/components/index.js +15532 -1478
- package/hooks/index.d.ts +57 -8
- package/hooks/index.js +14423 -422
- package/index.d.ts +35 -2
- package/index.js +73 -1
- package/metadata/index.d.ts +14 -1
- package/package.json +1 -1
- package/register.d.ts +20 -9
- package/routing/index.d.ts +6 -1
- package/slots/index.js +20 -1
- package/types/index.d.ts +353 -46
- package/ui/index.js +2 -1
- package/utils/index.d.ts +20 -3
- package/_internal/app/hooks/use-assets.d.ts +0 -25
package/README.md
CHANGED
|
@@ -86,6 +86,7 @@ component for a slot via `registerPlugin({ slots: { 'slot-name': Component } })`
|
|
|
86
86
|
| `task-assets` | Task drawer, asset attachments section |
|
|
87
87
|
| `task-sidebar` | Task drawer sidebar (custom panels for a plugin's tasks) |
|
|
88
88
|
| `home-widget` | Dashboard home widget grid |
|
|
89
|
+
| `nav-badge-providers` | Background hook runners (render `null`) that drive `setNavBadge` |
|
|
89
90
|
| `page:/<route>` | Full-page mount at `<route>` |
|
|
90
91
|
|
|
91
92
|
## Sub-path imports
|
|
@@ -1,6 +1,11 @@
|
|
|
1
|
-
|
|
1
|
+
import type { AriaAttributes } from 'react';
|
|
2
|
+
interface AgentSelectProps extends Pick<AriaAttributes, 'aria-describedby' | 'aria-invalid'> {
|
|
3
|
+
id?: string;
|
|
2
4
|
value: string;
|
|
3
5
|
onValueChange: (value: string) => void;
|
|
6
|
+
/** Include the workflow/task runtime assignee token (`$assigned`) */
|
|
7
|
+
includeAssigned?: boolean;
|
|
8
|
+
assignedLabel?: string;
|
|
4
9
|
/** Show a "None" / "Unassigned" option at the top (default: false) */
|
|
5
10
|
allowNone?: boolean;
|
|
6
11
|
/** Label for the none option (default: "Unassigned") */
|
|
@@ -11,5 +16,5 @@ interface AgentSelectProps {
|
|
|
11
16
|
agentIds?: string[];
|
|
12
17
|
className?: string;
|
|
13
18
|
}
|
|
14
|
-
export declare function AgentSelect({ value, onValueChange, allowNone, noneLabel, placeholder, agentIds, className, }: AgentSelectProps): import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
export declare function AgentSelect({ value, onValueChange, includeAssigned, assignedLabel, allowNone, noneLabel, placeholder, agentIds, className, id, 'aria-describedby': ariaDescribedBy, 'aria-invalid': ariaInvalid, }: AgentSelectProps): import("react/jsx-runtime").JSX.Element;
|
|
15
20
|
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Button as ButtonPrimitive } from "@base-ui/react/button";
|
|
2
2
|
import { type VariantProps } from "class-variance-authority";
|
|
3
3
|
declare const buttonVariants: (props?: ({
|
|
4
|
-
variant?: "destructive" | "link" | "default" | "outline" | "secondary" | "ghost" | "warning" | "accent" | null | undefined;
|
|
4
|
+
variant?: "info" | "destructive" | "link" | "default" | "outline" | "secondary" | "ghost" | "warning" | "accent" | null | undefined;
|
|
5
5
|
size?: "default" | "sm" | "lg" | "icon" | "xs" | "icon-xs" | "icon-sm" | "icon-lg" | null | undefined;
|
|
6
6
|
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
7
7
|
declare function Button({ className, variant, size, ...props }: ButtonPrimitive.Props & VariantProps<typeof buttonVariants>): import("react/jsx-runtime").JSX.Element;
|
|
@@ -15,6 +15,7 @@ interface ContentStore extends ContentState {
|
|
|
15
15
|
activityEvents: ActivityEvent[];
|
|
16
16
|
sseConnected: boolean;
|
|
17
17
|
taskboardVersion: number;
|
|
18
|
+
doctorVersion: number;
|
|
18
19
|
debug: boolean;
|
|
19
20
|
reindexProgress: Record<string, ReindexProgressEntry>;
|
|
20
21
|
setFiles: (files: Record<string, string>) => void;
|
|
@@ -26,6 +27,7 @@ interface ContentStore extends ContentState {
|
|
|
26
27
|
setActivityEvents: (events: ActivityEvent[]) => void;
|
|
27
28
|
setSseConnected: (connected: boolean) => void;
|
|
28
29
|
bumpTaskboard: () => void;
|
|
30
|
+
bumpDoctor: () => void;
|
|
29
31
|
setDebug: (debug: boolean) => void;
|
|
30
32
|
toggleDebug: () => void;
|
|
31
33
|
setReindexProgress: (table: string, indexed: number, done: boolean) => void;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { type NavBadge } from '@makinbakin/sdk';
|
|
2
|
+
/**
|
|
3
|
+
* Sync a nav item's badge to the value passed each render. Calls
|
|
4
|
+
* `setNavBadge(pluginId, navItemId, badge)` only when the badge's value
|
|
5
|
+
* actually changes — the effect is keyed on a serialization of `count` +
|
|
6
|
+
* `tone`, not the object identity (which a parent recreates every render).
|
|
7
|
+
*
|
|
8
|
+
* This is the recommended glue for a badge provider: keep your own summary
|
|
9
|
+
* hook (fetch + refresh) per plugin, derive a `NavBadge | null`, and pass it
|
|
10
|
+
* here. Teardown is handled by `unregisterPlugin`, so this does not clear on
|
|
11
|
+
* unmount (which would flicker on dev hot-reload).
|
|
12
|
+
*/
|
|
13
|
+
export declare function useNavBadge(pluginId: string, navItemId: string, badge: NavBadge | null): void;
|
|
@@ -2,6 +2,7 @@ export interface TaskLogEntry {
|
|
|
2
2
|
timestamp: string;
|
|
3
3
|
author: string;
|
|
4
4
|
message: string;
|
|
5
|
+
data?: Record<string, unknown>;
|
|
5
6
|
}
|
|
6
7
|
export interface Task {
|
|
7
8
|
id: string;
|
|
@@ -56,48 +57,6 @@ export interface ProjectMeta {
|
|
|
56
57
|
status?: string;
|
|
57
58
|
content: string;
|
|
58
59
|
}
|
|
59
|
-
export interface AssetVariantMeta {
|
|
60
|
-
role: 'thumbnail' | 'optimized' | 'webp';
|
|
61
|
-
path: string;
|
|
62
|
-
filename: string;
|
|
63
|
-
size: number;
|
|
64
|
-
mimeType: string;
|
|
65
|
-
}
|
|
66
|
-
export interface AssetMeta {
|
|
67
|
-
path: string;
|
|
68
|
-
filename: string;
|
|
69
|
-
type: 'text' | 'images' | 'video' | 'audio' | 'plans' | 'research' | 'pdf' | 'data' | 'other';
|
|
70
|
-
mimeType: string;
|
|
71
|
-
size: number;
|
|
72
|
-
mtimeMs?: number;
|
|
73
|
-
metadata: {
|
|
74
|
-
agent: string;
|
|
75
|
-
taskId: string | null;
|
|
76
|
-
created: string;
|
|
77
|
-
tool?: string;
|
|
78
|
-
description?: string;
|
|
79
|
-
tags?: string[];
|
|
80
|
-
originalFilename?: string;
|
|
81
|
-
};
|
|
82
|
-
variants?: AssetVariantMeta[];
|
|
83
|
-
}
|
|
84
|
-
export interface TrashedAssetMeta {
|
|
85
|
-
filename: string;
|
|
86
|
-
originalFilename: string;
|
|
87
|
-
type: string;
|
|
88
|
-
mimeType: string;
|
|
89
|
-
size: number;
|
|
90
|
-
deletedAt: string;
|
|
91
|
-
expiresAt: string;
|
|
92
|
-
metadata: {
|
|
93
|
-
agent: string;
|
|
94
|
-
taskId: string | null;
|
|
95
|
-
created: string;
|
|
96
|
-
tool?: string;
|
|
97
|
-
description?: string;
|
|
98
|
-
tags?: string[];
|
|
99
|
-
} | null;
|
|
100
|
-
}
|
|
101
60
|
export interface OfficeData {
|
|
102
61
|
asciiMap: string;
|
|
103
62
|
statusTable: {
|
|
@@ -118,6 +77,7 @@ export interface ActivityEvent {
|
|
|
118
77
|
taskTitle?: string;
|
|
119
78
|
eventName?: string;
|
|
120
79
|
duplicate?: boolean;
|
|
80
|
+
data?: Record<string, unknown>;
|
|
121
81
|
}
|
|
122
82
|
export interface ContentState {
|
|
123
83
|
files: Record<string, string>;
|
|
@@ -38,7 +38,19 @@ export interface WorkspaceFile {
|
|
|
38
38
|
updatedAt?: string;
|
|
39
39
|
metadata?: RuntimeMetadata;
|
|
40
40
|
}
|
|
41
|
-
export
|
|
41
|
+
export type RuntimeMessageToolsMode = 'auto' | 'none';
|
|
42
|
+
export interface RuntimeMessageToolPolicy {
|
|
43
|
+
/**
|
|
44
|
+
* Controls whether runtime-native tools are available for this agent turn.
|
|
45
|
+
* `none` disables tools. Omit or use `auto` for runtime/provider defaults.
|
|
46
|
+
*/
|
|
47
|
+
toolsMode?: RuntimeMessageToolsMode;
|
|
48
|
+
/** Optional runtime-native tool allowlist for this turn. */
|
|
49
|
+
toolsAllow?: string[];
|
|
50
|
+
/** Optional runtime-native tool denylist for this turn. */
|
|
51
|
+
toolsDeny?: string[];
|
|
52
|
+
}
|
|
53
|
+
export interface MessageArgs extends RuntimeMessageToolPolicy {
|
|
42
54
|
agentId: string;
|
|
43
55
|
content: string;
|
|
44
56
|
/**
|
|
@@ -296,6 +308,94 @@ export interface RuntimeAvailableModel {
|
|
|
296
308
|
tags?: string[];
|
|
297
309
|
metadata?: RuntimeMetadata;
|
|
298
310
|
}
|
|
311
|
+
export type RuntimeImageOutputFormat = 'png' | 'jpeg' | 'jpg' | 'webp';
|
|
312
|
+
export type RuntimeImageBackground = 'transparent' | 'opaque' | 'auto';
|
|
313
|
+
/**
|
|
314
|
+
* Image capability is intentionally all-optional. A thin runtime that exposes a
|
|
315
|
+
* single image tool maps on by filling minimal fields (e.g. one synthesized
|
|
316
|
+
* provider with a defaultModel); a rich runtime fills more. Consumers MUST
|
|
317
|
+
* treat a sparse capability as normal and never require a field a thin runtime
|
|
318
|
+
* cannot provide — gaps are filled below, in the adapter/shim, not pushed up
|
|
319
|
+
* into plugins. See .claude/specs/media-generation-adapter-architecture.md.
|
|
320
|
+
*/
|
|
321
|
+
export interface RuntimeImageProviderCapabilities {
|
|
322
|
+
generate?: {
|
|
323
|
+
maxCount?: number;
|
|
324
|
+
supportsSize?: boolean;
|
|
325
|
+
supportsAspectRatio?: boolean;
|
|
326
|
+
supportsResolution?: boolean;
|
|
327
|
+
};
|
|
328
|
+
edit?: {
|
|
329
|
+
enabled?: boolean;
|
|
330
|
+
maxCount?: number;
|
|
331
|
+
maxInputImages?: number;
|
|
332
|
+
supportsSize?: boolean;
|
|
333
|
+
supportsAspectRatio?: boolean;
|
|
334
|
+
supportsResolution?: boolean;
|
|
335
|
+
};
|
|
336
|
+
geometry?: {
|
|
337
|
+
sizes?: string[];
|
|
338
|
+
aspectRatios?: string[];
|
|
339
|
+
resolutions?: string[];
|
|
340
|
+
};
|
|
341
|
+
output?: {
|
|
342
|
+
formats?: string[];
|
|
343
|
+
qualities?: string[];
|
|
344
|
+
backgrounds?: string[];
|
|
345
|
+
};
|
|
346
|
+
metadata?: RuntimeMetadata;
|
|
347
|
+
}
|
|
348
|
+
export interface RuntimeImageProvider {
|
|
349
|
+
id: string;
|
|
350
|
+
label?: string;
|
|
351
|
+
defaultModel?: string;
|
|
352
|
+
models?: string[];
|
|
353
|
+
available?: boolean;
|
|
354
|
+
configured?: boolean;
|
|
355
|
+
selected?: boolean;
|
|
356
|
+
capabilities?: RuntimeImageProviderCapabilities;
|
|
357
|
+
metadata?: RuntimeMetadata;
|
|
358
|
+
}
|
|
359
|
+
export interface RuntimeImageGenerateInput {
|
|
360
|
+
prompt: string;
|
|
361
|
+
provider?: string;
|
|
362
|
+
model?: string;
|
|
363
|
+
count?: number;
|
|
364
|
+
width?: number;
|
|
365
|
+
height?: number;
|
|
366
|
+
size?: string;
|
|
367
|
+
aspectRatio?: string;
|
|
368
|
+
resolution?: string;
|
|
369
|
+
outputFormat?: RuntimeImageOutputFormat;
|
|
370
|
+
background?: RuntimeImageBackground;
|
|
371
|
+
timeoutMs?: number;
|
|
372
|
+
metadata?: RuntimeMetadata;
|
|
373
|
+
}
|
|
374
|
+
export interface RuntimeImageEditInput extends RuntimeImageGenerateInput {
|
|
375
|
+
files: string[];
|
|
376
|
+
}
|
|
377
|
+
export interface RuntimeImageFile {
|
|
378
|
+
filePath: string;
|
|
379
|
+
mimeType?: string;
|
|
380
|
+
width?: number;
|
|
381
|
+
height?: number;
|
|
382
|
+
provider?: string;
|
|
383
|
+
model?: string;
|
|
384
|
+
url?: string;
|
|
385
|
+
metadata?: RuntimeMetadata;
|
|
386
|
+
}
|
|
387
|
+
export interface RuntimeImageGenerationResult {
|
|
388
|
+
images: RuntimeImageFile[];
|
|
389
|
+
provider?: string;
|
|
390
|
+
model?: string;
|
|
391
|
+
providerText?: string;
|
|
392
|
+
metadata?: RuntimeMetadata;
|
|
393
|
+
}
|
|
394
|
+
export interface RuntimeImagesAccess {
|
|
395
|
+
providers(): Promise<RuntimeImageProvider[]>;
|
|
396
|
+
generate(input: RuntimeImageGenerateInput): Promise<RuntimeImageGenerationResult>;
|
|
397
|
+
edit(input: RuntimeImageEditInput): Promise<RuntimeImageGenerationResult>;
|
|
398
|
+
}
|
|
299
399
|
export interface TaskDispatchArgs {
|
|
300
400
|
bakinTaskId: string;
|
|
301
401
|
agentId?: string;
|
|
@@ -452,6 +552,7 @@ export interface AgentRuntimeAdapter {
|
|
|
452
552
|
includeUnavailable?: boolean;
|
|
453
553
|
}): Promise<RuntimeAvailableModel[]>;
|
|
454
554
|
};
|
|
555
|
+
images?: RuntimeImagesAccess;
|
|
455
556
|
tasks: {
|
|
456
557
|
dispatch(args: TaskDispatchArgs): Promise<TaskDispatchResult>;
|
|
457
558
|
getExecutionStatus(flowId: string): Promise<TaskExecutionStatus>;
|
|
@@ -2,4 +2,4 @@ export type { AdapterAuditEvent, AdapterHealthCheckDefinition, AdapterHealthChec
|
|
|
2
2
|
export type { ChannelCapability } from './capabilities';
|
|
3
3
|
export { hasChannelCapability } from './capabilities';
|
|
4
4
|
export { getRuntimeMainAgent, getRuntimeMainAgentId, getRuntimeMainAgentName, selectRuntimeMainAgent, } from './helpers';
|
|
5
|
-
export type { AgentRuntimeAdapter, ApprovalDelivery, ApprovalOption, ApprovalPatch, ApprovalRenderRef, ApprovalRenderResult, ApprovalResolveEvent, ApprovalResponse, CancelApprovalArgs, ChannelInfo, ChannelInteractionEvent, ChannelMessageArgs, ChannelMessageEvent, ChatChunk, ContentDeliveryArgs, CreateApprovalArgs, CreateCronJobInput, CreateRuntimeAgentInput, CronJob, CronRun, DeliveryResult, DurableApprovalRecord, EditApprovalArgs, ListExecutionsOpts, MessageArgs, MessageResult, NotificationArgs, ResolveApprovalArgs, RuntimeAgent, RuntimeAllowlistPatch, RuntimeToolActivity, RuntimeAvailableModel, RuntimeConfigAccess, RuntimeMemoryEntry, RuntimeMemoryEntryStat, RuntimeMemoryPathMatch, RuntimeMemoryReadRange, RuntimeMemorySearchResult, RuntimeMemoryTier, RuntimeMetadata, RuntimePermissionPatch, RawCronSnapshot, RuntimeSession, RuntimeSkill, TaskDispatchArgs, TaskDispatchResult, TaskExecutionEvent, TaskExecutionStatus, ToolDefinition, ToolResult, UpdateCronJobInput, UpdateRuntimeAgentInput, WorkspaceFile, } from './concepts';
|
|
5
|
+
export type { AgentRuntimeAdapter, ApprovalDelivery, ApprovalOption, ApprovalPatch, ApprovalRenderRef, ApprovalRenderResult, ApprovalResolveEvent, ApprovalResponse, CancelApprovalArgs, ChannelInfo, ChannelInteractionEvent, ChannelMessageArgs, ChannelMessageEvent, ChatChunk, ContentDeliveryArgs, CreateApprovalArgs, CreateCronJobInput, CreateRuntimeAgentInput, CronJob, CronRun, DeliveryResult, DurableApprovalRecord, EditApprovalArgs, ListExecutionsOpts, MessageArgs, MessageResult, NotificationArgs, ResolveApprovalArgs, RuntimeAgent, RuntimeAllowlistPatch, RuntimeToolActivity, RuntimeAvailableModel, RuntimeConfigAccess, RuntimeImageBackground, RuntimeImageEditInput, RuntimeImageFile, RuntimeImageGenerateInput, RuntimeImageGenerationResult, RuntimeImageOutputFormat, RuntimeImageProvider, RuntimeImageProviderCapabilities, RuntimeImagesAccess, RuntimeMemoryEntry, RuntimeMemoryEntryStat, RuntimeMemoryPathMatch, RuntimeMemoryReadRange, RuntimeMemorySearchResult, RuntimeMemoryTier, RuntimeMessageToolPolicy, RuntimeMessageToolsMode, RuntimeMetadata, RuntimePermissionPatch, RawCronSnapshot, RuntimeSession, RuntimeSkill, TaskDispatchArgs, TaskDispatchResult, TaskExecutionEvent, TaskExecutionStatus, ToolDefinition, ToolResult, UpdateCronJobInput, UpdateRuntimeAgentInput, WorkspaceFile, } from './concepts';
|
|
@@ -109,6 +109,16 @@ export interface SkillDefinition {
|
|
|
109
109
|
instructions: string;
|
|
110
110
|
output_schema?: Record<string, unknown>;
|
|
111
111
|
source?: string;
|
|
112
|
+
/** Absolute source markdown file path when the skill was loaded from a managed package/plugin file. */
|
|
113
|
+
sourcePath?: string;
|
|
114
|
+
}
|
|
115
|
+
export interface WorkflowLayoutInput {
|
|
116
|
+
positions?: Record<string, {
|
|
117
|
+
x: number;
|
|
118
|
+
y: number;
|
|
119
|
+
[key: string]: unknown;
|
|
120
|
+
}>;
|
|
121
|
+
[key: string]: unknown;
|
|
112
122
|
}
|
|
113
123
|
export interface WorkflowDefinitionInput {
|
|
114
124
|
/** Stable workflow id. Falls back to slug(name) when omitted. */
|
|
@@ -117,7 +127,9 @@ export interface WorkflowDefinitionInput {
|
|
|
117
127
|
description: string;
|
|
118
128
|
version: number;
|
|
119
129
|
inputs?: Record<string, unknown>;
|
|
130
|
+
layout?: WorkflowLayoutInput;
|
|
120
131
|
steps: unknown[];
|
|
132
|
+
[key: string]: unknown;
|
|
121
133
|
}
|
|
122
134
|
export interface ActivityAPI {
|
|
123
135
|
/** Log a human-readable message to the live activity feed */
|
|
@@ -431,44 +443,93 @@ export interface PluginTaskService {
|
|
|
431
443
|
}): Promise<PluginTask[]>;
|
|
432
444
|
appendLog(id: string, entry: TaskLogEntry): Promise<void>;
|
|
433
445
|
}
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
446
|
+
/** The asset type taxonomy (mirrors ASSET_TYPES in the assets plugin). */
|
|
447
|
+
export type AssetTypeName = 'text' | 'images' | 'video' | 'audio' | 'plans' | 'research' | 'pdf' | 'data' | 'other';
|
|
448
|
+
/** Per-version generation provenance (matches the manifest's `generation` block). */
|
|
449
|
+
export interface AssetGenerationInfo {
|
|
450
|
+
provider: string;
|
|
451
|
+
model: string;
|
|
452
|
+
surface: string;
|
|
453
|
+
quality: string;
|
|
454
|
+
routeSource: string;
|
|
455
|
+
routeReason?: string;
|
|
456
|
+
}
|
|
457
|
+
/** Create a new versioned asset (v1) from a source file. */
|
|
458
|
+
export interface AssetCreateInput {
|
|
459
|
+
sourceFilePath: string;
|
|
460
|
+
type: AssetTypeName;
|
|
461
|
+
agent: string;
|
|
462
|
+
taskId: string | null;
|
|
463
|
+
slug?: string;
|
|
464
|
+
op?: 'generate' | 'upload' | 'import';
|
|
465
|
+
tool?: string | null;
|
|
466
|
+
prompt?: string | null;
|
|
467
|
+
promptHash?: string | null;
|
|
468
|
+
description?: string;
|
|
469
|
+
tags?: string[];
|
|
470
|
+
source?: {
|
|
471
|
+
kind: 'generated' | 'upload' | 'import' | 'clipboard' | 'workspace-file';
|
|
472
|
+
path: string | null;
|
|
473
|
+
};
|
|
474
|
+
generation?: AssetGenerationInfo | null;
|
|
475
|
+
}
|
|
476
|
+
/** Append a new version to an existing asset. */
|
|
477
|
+
export interface AssetVersionCreateInput {
|
|
478
|
+
sourceFilePath: string;
|
|
479
|
+
op?: 'edit' | 'generate' | 'upload' | 'import';
|
|
480
|
+
tool?: string | null;
|
|
481
|
+
prompt?: string | null;
|
|
482
|
+
promptHash?: string | null;
|
|
483
|
+
description?: string;
|
|
484
|
+
tags?: string[];
|
|
485
|
+
generation?: AssetGenerationInfo | null;
|
|
486
|
+
}
|
|
487
|
+
/** Render a derived export of a version (keyed/idempotent by surface). */
|
|
488
|
+
export interface AssetExportRequest {
|
|
489
|
+
fromVersion?: number;
|
|
490
|
+
surface: string;
|
|
491
|
+
format: 'jpg' | 'png' | 'webp';
|
|
492
|
+
width: number;
|
|
493
|
+
height: number;
|
|
494
|
+
quality?: number;
|
|
495
|
+
}
|
|
496
|
+
export interface VersionedAssetRef {
|
|
497
|
+
assetId: string;
|
|
498
|
+
version: number;
|
|
499
|
+
}
|
|
500
|
+
export interface AssetVersionFileRef {
|
|
501
|
+
absPath: string;
|
|
439
502
|
mimeType: string;
|
|
503
|
+
version: number;
|
|
440
504
|
}
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
type:
|
|
505
|
+
/** Current-version summary of an asset, addressed by id. */
|
|
506
|
+
export interface AssetSummary {
|
|
507
|
+
assetId: string;
|
|
508
|
+
type: AssetTypeName;
|
|
509
|
+
agent: string;
|
|
510
|
+
taskId: string | null;
|
|
511
|
+
created: string;
|
|
512
|
+
updated: string;
|
|
513
|
+
currentVersion: number;
|
|
514
|
+
versionCount: number;
|
|
515
|
+
description: string;
|
|
516
|
+
tags: string[];
|
|
445
517
|
mimeType: string;
|
|
518
|
+
width: number | null;
|
|
519
|
+
height: number | null;
|
|
446
520
|
size: number;
|
|
447
|
-
|
|
448
|
-
metadata: {
|
|
449
|
-
agent: string;
|
|
450
|
-
taskId: string | null;
|
|
451
|
-
created: string;
|
|
452
|
-
tool?: string;
|
|
453
|
-
description?: string;
|
|
454
|
-
tags?: string[];
|
|
455
|
-
originalFilename?: string;
|
|
456
|
-
};
|
|
457
|
-
variants?: AssetVariantMeta[];
|
|
458
|
-
}
|
|
459
|
-
export interface AssetFileRef {
|
|
460
|
-
kind: 'asset';
|
|
461
|
-
filename: string;
|
|
462
|
-
mimeType?: string;
|
|
521
|
+
hasThumb: boolean;
|
|
463
522
|
}
|
|
464
523
|
export interface AssetsAPI {
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
524
|
+
createAsset(input: AssetCreateInput): Promise<VersionedAssetRef>;
|
|
525
|
+
/** Read an asset's current-version summary by id (metadata: type/description/tags/etc.), or null. */
|
|
526
|
+
getAsset(assetId: string): Promise<AssetSummary | null>;
|
|
527
|
+
addVersion(assetId: string, input: AssetVersionCreateInput): Promise<VersionedAssetRef>;
|
|
528
|
+
addExport(assetId: string, input: AssetExportRequest): Promise<{
|
|
529
|
+
name: string;
|
|
530
|
+
file: string;
|
|
531
|
+
}>;
|
|
532
|
+
resolveVersionFile(assetId: string, version?: number): Promise<AssetVersionFileRef | null>;
|
|
472
533
|
}
|
|
473
534
|
/** Field type for search content type schemas */
|
|
474
535
|
export interface SearchSchemaField {
|
|
@@ -597,6 +658,8 @@ export interface SearchResult {
|
|
|
597
658
|
fields: Record<string, unknown>;
|
|
598
659
|
/** Cross-encoder reranker score (present when a reranker was used). */
|
|
599
660
|
rerankScore?: number;
|
|
661
|
+
/** Per-index score breakdown (e.g. { full_text_index_v0, assets_text, assets_visual }). */
|
|
662
|
+
indexScores?: Record<string, number>;
|
|
600
663
|
}
|
|
601
664
|
/** Search response from a query */
|
|
602
665
|
export interface SearchResponse {
|
|
@@ -720,6 +783,13 @@ export interface FileBackedContentTypeDefinition extends SearchContentTypeDefini
|
|
|
720
783
|
* own initial population (rare).
|
|
721
784
|
*/
|
|
722
785
|
buildOnStartup?: boolean;
|
|
786
|
+
/**
|
|
787
|
+
* Keep indexed documents that are not represented by a matched file when
|
|
788
|
+
* verifyExists(key) still returns true. Use this only for hybrid content
|
|
789
|
+
* types that combine file-backed rows with registry/runtime rows in the
|
|
790
|
+
* same table.
|
|
791
|
+
*/
|
|
792
|
+
preserveVirtualDocuments?: boolean;
|
|
723
793
|
}
|
|
724
794
|
/** Search API provided to plugins via ctx.search */
|
|
725
795
|
export interface SearchAPI {
|
|
@@ -67,12 +67,13 @@ export interface SkillSummary {
|
|
|
67
67
|
* client doesn't reach across the package boundary for types.
|
|
68
68
|
*
|
|
69
69
|
* The server today returns 4 states (`absent | unmanaged | adopted | managed`).
|
|
70
|
-
* `drifted` and `update-available` are
|
|
71
|
-
*
|
|
70
|
+
* `drifted` and `update-available` are display states layered on top of the
|
|
71
|
+
* server row when diagnostics or update checks report additional status.
|
|
72
72
|
*/
|
|
73
73
|
export interface PackageStateRow {
|
|
74
74
|
agentId: string;
|
|
75
75
|
state: 'absent' | 'unmanaged' | 'adopted' | 'managed' | 'drifted' | 'update-available';
|
|
76
|
+
version?: string;
|
|
76
77
|
packageId?: string;
|
|
77
78
|
entry?: {
|
|
78
79
|
source: string;
|
|
@@ -82,6 +83,15 @@ export interface PackageStateRow {
|
|
|
82
83
|
version?: string;
|
|
83
84
|
dependencies?: string[];
|
|
84
85
|
};
|
|
86
|
+
updateStatus?: {
|
|
87
|
+
currentVersion: string;
|
|
88
|
+
latestVersion: string | null;
|
|
89
|
+
currentCommitSha: string;
|
|
90
|
+
latestCommitSha: string | null;
|
|
91
|
+
upgradeAvailable: boolean;
|
|
92
|
+
checkedAt: string;
|
|
93
|
+
error?: string;
|
|
94
|
+
};
|
|
85
95
|
}
|
|
86
96
|
/**
|
|
87
97
|
* Single message from a runtime session JSONL. Used by the Active Context
|
package/components/index.d.ts
CHANGED
|
@@ -6,29 +6,64 @@
|
|
|
6
6
|
* not include layout chrome (sidebar, header, toaster) — those are Bakin's
|
|
7
7
|
* shell, not plugin-author territory.
|
|
8
8
|
*/
|
|
9
|
+
/** Round avatar image for an agent, falls back to initials. */
|
|
9
10
|
export { AgentAvatar } from '../_internal/app/components/agent-avatar';
|
|
11
|
+
/** Multi-select facet filter scoped to agents. */
|
|
10
12
|
export { AgentFilter } from '../_internal/app/components/agent-filter';
|
|
13
|
+
/** Single-agent picker dropdown for form fields. */
|
|
11
14
|
export { AgentSelect } from '../_internal/app/components/agent-select';
|
|
12
|
-
|
|
15
|
+
/** Small status dot showing an agent's online/offline state. */
|
|
16
|
+
export { AgentDot } from '../_internal/app/components/agent-status';
|
|
17
|
+
/** Compound agent status (dot + label + last-seen timestamp). */
|
|
18
|
+
export { AgentStatus } from '../_internal/app/components/agent-status';
|
|
19
|
+
/** Right-side slide-out drawer with backdrop and focus trap. */
|
|
13
20
|
export { BakinDrawer } from '../_internal/app/components/bakin-drawer';
|
|
21
|
+
/** Color picker swatch grid for tag/agent color assignment. */
|
|
14
22
|
export { ColorPicker } from '../_internal/app/components/color-picker';
|
|
23
|
+
/** Centered empty-state component with icon, title, and CTA. */
|
|
15
24
|
export { EmptyState } from '../_internal/app/components/empty-state';
|
|
25
|
+
/** Inline error banner with dismiss + retry actions. */
|
|
16
26
|
export { ErrorBanner } from '../_internal/app/components/error-banner';
|
|
27
|
+
/** Full-page error state with title, description, and retry button. */
|
|
17
28
|
export { ErrorState } from '../_internal/app/components/error-state';
|
|
29
|
+
/** Popover multi-select facet filter (column, owner, tag, etc.). */
|
|
18
30
|
export { FacetFilter } from '../_internal/app/components/facet-filter';
|
|
19
31
|
export type { FacetOption } from '../_internal/app/components/facet-filter';
|
|
32
|
+
/** Chat + plan-proposal review panel for brainstorm sessions. */
|
|
20
33
|
export { IntegratedBrainstorm } from '../_internal/app/components/integrated-brainstorm';
|
|
21
34
|
export type { BrainstormMessage, IntegratedBrainstormProps, BrainstormOnSend, SendContext, AssistantTransformed, BrainstormActivityInput, BrainstormActivityStorageInput, BrainstormActivityStorageRecord, BrainstormTimelineActivityInput, BrainstormTimelineMessageInput, } from '../_internal/app/components/integrated-brainstorm';
|
|
22
|
-
|
|
35
|
+
/** Convert a custom activity message back into a brainstorm activity. */
|
|
36
|
+
export { brainstormActivityMessageFromCustom } from '../_internal/app/components/integrated-brainstorm';
|
|
37
|
+
/** Compute the canonical thread ID for a brainstorm session. */
|
|
38
|
+
export { brainstormThreadId } from '../_internal/app/components/integrated-brainstorm';
|
|
39
|
+
/** Normalize a brainstorm activity payload for persistence. */
|
|
40
|
+
export { normalizeBrainstormActivityForStorage } from '../_internal/app/components/integrated-brainstorm';
|
|
41
|
+
/** Normalize a single brainstorm message for persistence. */
|
|
42
|
+
export { normalizeBrainstormActivityMessageForStorage } from '../_internal/app/components/integrated-brainstorm';
|
|
43
|
+
/** Read an SSE response stream into brainstorm activity events. */
|
|
44
|
+
export { readBrainstormSseResponse } from '../_internal/app/components/integrated-brainstorm';
|
|
45
|
+
/** Convert a runtime chat chunk to a brainstorm activity event. */
|
|
46
|
+
export { runtimeChunkToBrainstormActivity } from '../_internal/app/components/integrated-brainstorm';
|
|
47
|
+
/** Fold a brainstorm session's events into a renderable timeline. */
|
|
48
|
+
export { toBrainstormTimeline } from '../_internal/app/components/integrated-brainstorm';
|
|
49
|
+
/** Render markdown content with syntax highlighting and link handling. */
|
|
23
50
|
export { MarkdownContent } from '../_internal/app/components/markdown-content';
|
|
51
|
+
/** Editable markdown text area with preview toggle. */
|
|
24
52
|
export { MarkdownEditor } from '../_internal/app/components/markdown-editor';
|
|
53
|
+
/** Model picker dropdown listing available models from the catalog. */
|
|
25
54
|
export { ModelSelect } from '../_internal/app/components/model-select';
|
|
55
|
+
/** Standard plugin page wrapper with header, content area, and toaster. */
|
|
26
56
|
export { PageLayout } from '../_internal/app/components/page-layout';
|
|
57
|
+
/** Plugin page header with title, count badge, search, and action buttons. */
|
|
27
58
|
export { PluginHeader } from '../_internal/app/components/plugin-header';
|
|
59
|
+
/** Render a settings form from a PluginSettingsSchema definition. */
|
|
28
60
|
export { PluginSettingsRenderer } from '../_internal/app/components/plugin-settings-renderer';
|
|
29
61
|
export type { PluginSettingsSchema } from '../_internal/app/components/plugin-settings-renderer';
|
|
62
|
+
/** Sortable table column header with ascending/descending indicator. */
|
|
30
63
|
export { SortableHead } from '../_internal/app/components/sortable-head';
|
|
31
64
|
export type { SortDir } from '../_internal/app/components/sortable-head';
|
|
65
|
+
/** Tab list with animated underline indicator. */
|
|
32
66
|
export { UnderlineTabs } from '../_internal/app/components/underline-tabs';
|
|
33
67
|
export type { UnderlineTab } from '../_internal/app/components/underline-tabs';
|
|
68
|
+
/** Icon component for a notification channel (Discord, Slack, email, etc.). */
|
|
34
69
|
export { ChannelIcon } from '../_internal/plugins/workflows/hooks/channel-icon';
|