@agentshouse/mdruntime-families 0.1.0-caf5d4c2d5044 → 0.1.0-cb289cd6dabcf

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.
@@ -50,7 +50,7 @@ export type ListedConversation = {
50
50
  outcome: string | null;
51
51
  waiting: boolean;
52
52
  };
53
- export type ConversationAction = 'conversation.create' | 'conversation.send' | 'conversation.answer' | 'conversation.interrupt' | 'conversation.kill' | 'conversation.cancel' | 'conversation.delete' | 'conversation.history';
53
+ export type ConversationAction = 'conversation.create' | 'conversation.send' | 'conversation.attach' | 'conversation.answer' | 'conversation.interrupt' | 'conversation.kill' | 'conversation.cancel' | 'conversation.delete' | 'conversation.history';
54
54
  export type ConversationMessage = {
55
55
  identity: string;
56
56
  turn: string;
@@ -408,11 +408,8 @@ export type BinaryRequest = {
408
408
  referrer: unknown;
409
409
  };
410
410
  export type ReferrerScope = {
411
- kind: 'room';
412
411
  locator: string;
413
412
  path?: string;
414
- } | {
415
- kind: 'conversations';
416
413
  };
417
414
  export type BinaryResult = {
418
415
  kind: 'binary';
@@ -3,6 +3,7 @@ import type { Member, ServiceMode } from './adapter.js';
3
3
  import type { ChatDraft, ConversationAgent, ConversationEntry, ConversationOptions, ConversationView } from './conversation.js';
4
4
  import { type Observation } from './observation.js';
5
5
  import type { BinaryReference } from './binary.js';
6
+ import type { ChosenFile } from './file.js';
6
7
  import type { BinaryAnswer, BinaryLinkAnswer, CallResult, HistoryAnswer, Offline, QueueEntry, Resolution } from './outcome.js';
7
8
  import type { DocumentQuery, DocumentResult, GroupQuery, GroupResult, PendingResult } from './query.js';
8
9
  import type { RoomDraft, RoomDraftParts, RoomDraftWrite } from './room-draft.js';
@@ -36,6 +37,7 @@ export type MdRuntimeClient = {
36
37
  read(conversation: string, options?: ConversationOptions): Promise<ConversationView>;
37
38
  create(input: unknown): Promise<CallResult>;
38
39
  send(conversation: string, operation?: string, draft?: ChatDraft): Promise<CallResult | Offline>;
40
+ attach(room: string, file: ChosenFile): Promise<CallResult | Offline>;
39
41
  answer(conversation: string, answer: unknown): Promise<CallResult>;
40
42
  interrupt(conversation: string): Promise<CallResult>;
41
43
  kill(conversation: string): Promise<CallResult>;
@@ -1,6 +1,6 @@
1
1
  import type { ConversationAction, ConversationAgents, ConversationEvent, ConversationMessage, ConversationStream, ProcessCommand, SessionOption, TurnContext } from './adapter.js';
2
2
  import { type ChangeSet } from './change-set.js';
3
- import { type ChatDraftFile } from './file.js';
3
+ import { type ChosenFile } from './file.js';
4
4
  import type { Open } from './open.js';
5
5
  import { type CallResult, type Offline } from './outcome.js';
6
6
  import type { DocumentResult, PendingResult } from './query.js';
@@ -33,7 +33,6 @@ export type RunningTurn = {
33
33
  };
34
34
  export type ChatDraft = {
35
35
  text: string;
36
- files: readonly ChatDraftFile[];
37
36
  };
38
37
  export type ConversationOptions = {
39
38
  limit?: number;
@@ -66,6 +65,7 @@ export type ConversationSurface = {
66
65
  read(conversation: string, options?: ConversationOptions): Promise<ConversationView>;
67
66
  create(input: unknown): Promise<CallResult>;
68
67
  send(conversation: string, operation?: string, draft?: ChatDraft): Promise<CallResult | Offline>;
68
+ attach(room: string, file: ChosenFile): Promise<CallResult | Offline>;
69
69
  answer(conversation: string, answer: unknown): Promise<CallResult>;
70
70
  interrupt(conversation: string): Promise<CallResult>;
71
71
  kill(conversation: string): Promise<CallResult>;
@@ -1,4 +1,4 @@
1
- export type ChatDraftFile = {
1
+ export type ChosenFile = {
2
2
  name: string;
3
3
  blob: Blob;
4
4
  };
@@ -7,13 +7,6 @@ export type FileDeclaration = {
7
7
  mediaType: string;
8
8
  byteLength: number;
9
9
  contentHash: string;
10
- width?: number;
11
- height?: number;
12
10
  };
13
- export type Extent = {
14
- width: number;
15
- height: number;
16
- };
17
- export declare function extentOf(bytes: Uint8Array): Extent | null;
18
11
  export declare function hexDigest(digest: ArrayBuffer): string;
19
- export declare function declaredFile(file: ChatDraftFile): Promise<FileDeclaration>;
12
+ export declare function declaredFile(file: ChosenFile): Promise<FileDeclaration>;
@@ -4,7 +4,6 @@ import type { AcceptedMessage, KeptReceipt } from './adapter.js';
4
4
  import type { ChangeBatch } from './change.js';
5
5
  import { type HeldBinary } from './overlay.js';
6
6
  import { type Later } from './turn.js';
7
- import type { ChatDraftFile } from './file.js';
8
7
  import type { Submission } from './outcome.js';
9
8
  import type { RoomDraftRecord, SavedDraft } from './room-draft.js';
10
9
  export declare const STORE_SCHEMA = 25;
@@ -82,13 +81,11 @@ export type ConversationWrite = {
82
81
  export type ChatSubmission = {
83
82
  readonly operation: string;
84
83
  readonly text: string;
85
- readonly files: readonly ChatDraftFile[];
86
84
  readonly turn: string | null;
87
85
  };
88
86
  export type ChatDraftRecord = {
89
87
  conversation: string;
90
88
  text: string;
91
- files: readonly ChatDraftFile[];
92
89
  revision: string;
93
90
  submitted?: readonly ChatSubmission[];
94
91
  moves?: readonly string[];
@@ -126,6 +126,10 @@ declare const MEMBERS: {
126
126
  readonly reach: 'within';
127
127
  readonly effect: 'action';
128
128
  };
129
+ readonly 'conversation.attach': {
130
+ readonly reach: 'within';
131
+ readonly effect: 'action';
132
+ };
129
133
  readonly 'conversation.answer': {
130
134
  readonly reach: 'within';
131
135
  readonly effect: 'action';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agentshouse/mdruntime-families",
3
- "version": "0.1.0-caf5d4c2d5044",
3
+ "version": "0.1.0-cb289cd6dabcf",
4
4
  "description": "react-admin and Refine data providers over the MD Runtime client",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -28,7 +28,7 @@
28
28
  "LICENSE"
29
29
  ],
30
30
  "dependencies": {
31
- "@agentshouse/mdmodel": "0.1.0-c20d81032ac78"
31
+ "@agentshouse/mdmodel": "0.1.0-c04c0d681d2d4"
32
32
  },
33
33
  "peerDependencies": {
34
34
  "@refinedev/core": ">=5",