@saturn-universe/core 0.1.2-dev.5 → 0.1.2-dev.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/contracts.d.ts +30 -4
- package/dist/team.d.ts +4 -0
- package/package.json +1 -1
package/dist/contracts.d.ts
CHANGED
|
@@ -39,6 +39,7 @@ export interface Session {
|
|
|
39
39
|
readonly title: string;
|
|
40
40
|
readonly status: 'open' | 'archived';
|
|
41
41
|
readonly createdAt: ISODateTime;
|
|
42
|
+
readonly modeRef?: string;
|
|
42
43
|
}
|
|
43
44
|
export type AgentSessionScope = 'run' | 'session' | 'project';
|
|
44
45
|
export type AgentSessionOwner = {
|
|
@@ -427,13 +428,18 @@ export interface TeamMemberState {
|
|
|
427
428
|
readonly parent: string | null;
|
|
428
429
|
readonly agentSessionId: AgentSessionId;
|
|
429
430
|
readonly turnId?: TurnId;
|
|
430
|
-
readonly status:
|
|
431
|
+
readonly status: TeamMemberStatus;
|
|
432
|
+
readonly stopRequest?: {
|
|
433
|
+
readonly requestedBy: 'main';
|
|
434
|
+
readonly reason: string;
|
|
435
|
+
};
|
|
431
436
|
}
|
|
437
|
+
export type TeamMemberStatus = 'waiting' | 'stopped' | TurnStatus;
|
|
432
438
|
export interface TeamTaskState {
|
|
433
439
|
readonly memberId: string;
|
|
434
440
|
readonly task: string;
|
|
435
441
|
readonly turnId?: TurnId;
|
|
436
|
-
readonly status:
|
|
442
|
+
readonly status: TeamMemberStatus;
|
|
437
443
|
readonly resultMessageId?: MessageId;
|
|
438
444
|
}
|
|
439
445
|
export interface TeamInboxMessage {
|
|
@@ -636,12 +642,12 @@ export interface StreamRef {
|
|
|
636
642
|
readonly id: string;
|
|
637
643
|
}
|
|
638
644
|
export type WorkspaceEventType = 'workspace.created' | 'workspace.archived' | 'agent.created';
|
|
639
|
-
export type SessionEventType = 'session.created' | 'session.archived' | 'session.agent.bound';
|
|
645
|
+
export type SessionEventType = 'session.created' | 'session.archived' | 'session.agent.bound' | 'session.mode.selected';
|
|
640
646
|
export declare const terminalRunEventTypes: readonly ("run.completed" | "run.failed" | "run.cancelled")[];
|
|
641
647
|
export type TerminalRunEventType = (typeof terminalRunEventTypes)[number];
|
|
642
648
|
export declare function isTerminalRunEventType(value: unknown): value is TerminalRunEventType;
|
|
643
649
|
export type RunTransition = 'run.started' | 'run.paused' | 'run.resumed' | 'run.cancel_requested' | TerminalRunEventType;
|
|
644
|
-
export type RunEventType = 'run.created' | 'run.agent.attached' | 'run.team.planned' | 'run.team.message.sent' | 'run.team.message.read' | 'run.search.started' | 'run.search.branch.created' | 'run.search.branch.evaluated' | 'run.search.converged' | 'run.plugin.availability' | RunTransition;
|
|
650
|
+
export type RunEventType = 'run.created' | 'run.agent.attached' | 'run.team.planned' | 'run.team.member.stop_requested' | 'run.team.message.sent' | 'run.team.message.read' | 'run.search.started' | 'run.search.branch.created' | 'run.search.branch.evaluated' | 'run.search.converged' | 'run.plugin.availability' | RunTransition;
|
|
645
651
|
export type ScopeFor<K> = K extends WorkspaceEventType ? WorkspaceScope : K extends SessionEventType ? SessionScope : K extends RunEventType ? RunScope : K extends 'agent_session.created' | 'agent_session.archived' | 'surface.compacted' ? AgentSessionEventScope : AgentExecutionScope;
|
|
646
652
|
export interface EventMetadata {
|
|
647
653
|
readonly actor: {
|
|
@@ -694,6 +700,9 @@ export interface EventDataMap {
|
|
|
694
700
|
'session.archived': {
|
|
695
701
|
readonly reason: string;
|
|
696
702
|
};
|
|
703
|
+
'session.mode.selected': {
|
|
704
|
+
readonly modeRef: string;
|
|
705
|
+
};
|
|
697
706
|
'agent_session.created': {
|
|
698
707
|
readonly agentSession: AgentSession;
|
|
699
708
|
};
|
|
@@ -720,6 +729,13 @@ export interface EventDataMap {
|
|
|
720
729
|
readonly verificationCriteria?: readonly string[];
|
|
721
730
|
readonly team?: TeamConfig;
|
|
722
731
|
};
|
|
732
|
+
'run.team.member.stop_requested': {
|
|
733
|
+
readonly memberId: string;
|
|
734
|
+
readonly turnId: TurnId;
|
|
735
|
+
readonly requesterAgentSessionId: AgentSessionId;
|
|
736
|
+
readonly requestedBy: 'main';
|
|
737
|
+
readonly reason: string;
|
|
738
|
+
};
|
|
723
739
|
'run.team.message.sent': {
|
|
724
740
|
readonly messageId: string;
|
|
725
741
|
readonly from: string;
|
|
@@ -829,6 +845,7 @@ export interface EventDataMap {
|
|
|
829
845
|
};
|
|
830
846
|
'turn.interrupted': {
|
|
831
847
|
readonly turnId: TurnId;
|
|
848
|
+
readonly stoppedByMain?: true;
|
|
832
849
|
readonly reason: 'cancelled' | 'timeout' | 'limit';
|
|
833
850
|
readonly usage: Usage;
|
|
834
851
|
readonly unresolvedCallIds: readonly ToolCallId[];
|
|
@@ -851,6 +868,7 @@ export interface EventDataMap {
|
|
|
851
868
|
'message.user.added': {
|
|
852
869
|
readonly message: UserMessage;
|
|
853
870
|
readonly steering?: true;
|
|
871
|
+
readonly steeringSource?: 'main';
|
|
854
872
|
};
|
|
855
873
|
'message.assistant.added': {
|
|
856
874
|
readonly message: AssistantMessage;
|
|
@@ -1157,6 +1175,7 @@ export interface PersistedResponsesHistoryPlan {
|
|
|
1157
1175
|
readonly initialSystemPrompt?: string;
|
|
1158
1176
|
readonly initialBackground?: readonly BackgroundHistoryMessage[];
|
|
1159
1177
|
readonly prunedToolResults?: boolean;
|
|
1178
|
+
readonly projectedToolHistory?: true;
|
|
1160
1179
|
readonly fullInputDigest: string;
|
|
1161
1180
|
readonly configurationDigest: string;
|
|
1162
1181
|
readonly backgroundDigest?: string;
|
|
@@ -1199,6 +1218,8 @@ export interface HistorySelection {
|
|
|
1199
1218
|
}
|
|
1200
1219
|
export interface HistoryBuildInput {
|
|
1201
1220
|
readonly surface: SessionSurface;
|
|
1221
|
+
readonly modeRef?: string;
|
|
1222
|
+
readonly historicalRunModes?: Readonly<Record<string, string>>;
|
|
1202
1223
|
readonly model: ModelRef;
|
|
1203
1224
|
readonly binding: ProviderBinding;
|
|
1204
1225
|
readonly capabilities: ModelCapabilities;
|
|
@@ -1822,6 +1843,7 @@ export interface ContextStateSnapshot {
|
|
|
1822
1843
|
readonly surface: SessionSurface;
|
|
1823
1844
|
readonly runState: RunState;
|
|
1824
1845
|
readonly activeRequest?: PersistedModelRequest;
|
|
1846
|
+
readonly historicalRunModes?: Readonly<Record<string, string>>;
|
|
1825
1847
|
readonly teamReports?: readonly {
|
|
1826
1848
|
readonly from: string;
|
|
1827
1849
|
readonly text: string;
|
|
@@ -2109,6 +2131,10 @@ export type HostSubmitInput = Omit<SubmitTask, 'commandId' | 'config' | 'planner
|
|
|
2109
2131
|
export type HostCommand = Exclude<RuntimeCommand, {
|
|
2110
2132
|
readonly type: 'run.submit' | 'tool.approval.resolve';
|
|
2111
2133
|
}> | {
|
|
2134
|
+
readonly type: 'session.mode.select';
|
|
2135
|
+
readonly sessionId: SessionId;
|
|
2136
|
+
readonly modeRef: string;
|
|
2137
|
+
} | {
|
|
2112
2138
|
readonly type: 'run.steer';
|
|
2113
2139
|
readonly runId: RunId;
|
|
2114
2140
|
readonly content: string;
|
package/dist/team.d.ts
CHANGED
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
import type { PlannerConfig, RunConfig, TeamConfig, TeamHintConfig } from './contracts.js';
|
|
2
|
+
export interface TeamMemberActionResult {
|
|
3
|
+
readonly status: 'accepted' | 'ended' | 'inactive' | 'invalid_target' | 'forbidden';
|
|
4
|
+
readonly message: string;
|
|
5
|
+
}
|
|
2
6
|
export declare const teamRootId = "main";
|
|
3
7
|
export declare const plannerMemberId = "planner";
|
|
4
8
|
export declare const defaultTeamConcurrency = 4;
|