@alisio/sdk 0.1.0-alpha.16 → 0.1.0-alpha.17
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/index.d.ts +135 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1063,7 +1063,7 @@ export interface CommandDescriptor {
|
|
|
1063
1063
|
description: string;
|
|
1064
1064
|
aliases?: string[];
|
|
1065
1065
|
argumentHint?: string;
|
|
1066
|
-
source: "builtin" | "plugin" | "prompt" | "skill";
|
|
1066
|
+
source: "builtin" | "plugin" | "prompt" | "skill" | "agent";
|
|
1067
1067
|
/** Plugin id or resource owner, when not built in. */
|
|
1068
1068
|
owner?: string;
|
|
1069
1069
|
surfaces: Array<"tui" | "web" | "api">;
|
|
@@ -1489,6 +1489,140 @@ export interface ProviderModelsInfo {
|
|
|
1489
1489
|
models: ModelInfo[];
|
|
1490
1490
|
unavailable: boolean;
|
|
1491
1491
|
}
|
|
1492
|
+
/** Output format of an agent's answers (`text.format.type`). */
|
|
1493
|
+
export type AgentTextFormatType = "text" | "json_object" | "json_schema";
|
|
1494
|
+
/** Reasoning summary preference of an agent (`reasoning.summary`). */
|
|
1495
|
+
export type AgentReasoningSummary = "auto" | "none" | "concise" | "detailed";
|
|
1496
|
+
/** Answer verbosity preference of an agent (`text.verbosity`). */
|
|
1497
|
+
export type AgentVerbosity = "low" | "medium" | "high";
|
|
1498
|
+
/**
|
|
1499
|
+
* Where a user agent file lives: `project` is `<workspace>/.agents/agents/<id>.md`, `global` is
|
|
1500
|
+
* `~/.agents/agents/<id>.md`. A project agent overrides a global one with the same id.
|
|
1501
|
+
*/
|
|
1502
|
+
export type AgentScope = "project" | "global";
|
|
1503
|
+
/** Body of `POST /api/agents` and `PUT /api/agents/:id`: a user agent definition. */
|
|
1504
|
+
export interface AgentDefinitionInput {
|
|
1505
|
+
/** Display name; the stable id is derived from it once, on creation. */
|
|
1506
|
+
name: string;
|
|
1507
|
+
description?: string;
|
|
1508
|
+
/** System prompt appended to the session instructions when the agent is active. */
|
|
1509
|
+
instructions?: string;
|
|
1510
|
+
/** Model selector (`provider/model` or an unambiguous model id). */
|
|
1511
|
+
model: string;
|
|
1512
|
+
reasoning?: {
|
|
1513
|
+
effort?: string;
|
|
1514
|
+
summary?: AgentReasoningSummary;
|
|
1515
|
+
};
|
|
1516
|
+
text?: {
|
|
1517
|
+
format?: {
|
|
1518
|
+
type: AgentTextFormatType;
|
|
1519
|
+
};
|
|
1520
|
+
verbosity?: AgentVerbosity;
|
|
1521
|
+
};
|
|
1522
|
+
}
|
|
1523
|
+
/** A stored user agent definition (`GET /api/agents/definitions`). Times are epoch ms. */
|
|
1524
|
+
export interface AgentDefinitionInfo extends AgentDefinitionInput {
|
|
1525
|
+
/** File slug: the frontmatter `name` other harnesses use as the agent identifier. */
|
|
1526
|
+
id: string;
|
|
1527
|
+
scope: AgentScope;
|
|
1528
|
+
description: string;
|
|
1529
|
+
instructions: string;
|
|
1530
|
+
/** Absolute path of the Markdown file. */
|
|
1531
|
+
path: string;
|
|
1532
|
+
createdAt: number;
|
|
1533
|
+
updatedAt: number;
|
|
1534
|
+
/** A project agent that takes precedence over the global agent with the same id. */
|
|
1535
|
+
overridesGlobal?: boolean;
|
|
1536
|
+
/** A global agent hidden by the project agent with the same id. */
|
|
1537
|
+
overriddenByProject?: boolean;
|
|
1538
|
+
}
|
|
1539
|
+
/**
|
|
1540
|
+
* Answer of agent writes. `live`: the running Alisio already uses the change (its agent registry
|
|
1541
|
+
* reloaded and loaded the file); false means it is saved but needs a restart (or a trusted
|
|
1542
|
+
* workspace / the subagents plugin) before sessions can use it.
|
|
1543
|
+
*/
|
|
1544
|
+
export interface AgentSaveResult {
|
|
1545
|
+
agent: AgentDefinitionInfo;
|
|
1546
|
+
live: boolean;
|
|
1547
|
+
}
|
|
1548
|
+
/** `GET /api/agents/definitions`: both scopes merged, plus where new agents go by default. */
|
|
1549
|
+
export interface AgentDefinitionsOverview {
|
|
1550
|
+
agents: AgentDefinitionInfo[];
|
|
1551
|
+
scopes: AgentScope[];
|
|
1552
|
+
defaultScope: AgentScope;
|
|
1553
|
+
/** Directory of each available scope. */
|
|
1554
|
+
dirs: Partial<Record<AgentScope, string>>;
|
|
1555
|
+
/** Project agents load only in trusted workspaces. */
|
|
1556
|
+
trusted: boolean;
|
|
1557
|
+
}
|
|
1558
|
+
/** A predefined starting point for a new agent (`GET /api/agents/templates`). */
|
|
1559
|
+
export interface AgentTemplateInfo {
|
|
1560
|
+
id: string;
|
|
1561
|
+
name: string;
|
|
1562
|
+
description: string;
|
|
1563
|
+
instructions: string;
|
|
1564
|
+
reasoning?: {
|
|
1565
|
+
effort?: string;
|
|
1566
|
+
summary?: AgentReasoningSummary;
|
|
1567
|
+
};
|
|
1568
|
+
text?: {
|
|
1569
|
+
format?: {
|
|
1570
|
+
type: AgentTextFormatType;
|
|
1571
|
+
};
|
|
1572
|
+
verbosity?: AgentVerbosity;
|
|
1573
|
+
};
|
|
1574
|
+
}
|
|
1575
|
+
/** What a model supports for the agent editor, derived from its catalog metadata. */
|
|
1576
|
+
export interface AgentModelCapabilities {
|
|
1577
|
+
/** The catalog declared any capability metadata; otherwise every option is offered. */
|
|
1578
|
+
known: boolean;
|
|
1579
|
+
reasoning: boolean;
|
|
1580
|
+
/** Reasoning effort levels to offer (empty when reasoning is unsupported). */
|
|
1581
|
+
effortLevels: string[];
|
|
1582
|
+
defaultEffort?: string;
|
|
1583
|
+
summary: boolean;
|
|
1584
|
+
verbosity: boolean;
|
|
1585
|
+
textFormats: AgentTextFormatType[];
|
|
1586
|
+
/** Declared tool calling support; absent when unknown. */
|
|
1587
|
+
tools?: boolean;
|
|
1588
|
+
/** Declared image input support; absent when unknown. */
|
|
1589
|
+
vision?: boolean;
|
|
1590
|
+
}
|
|
1591
|
+
/** A configured model the agent editor can select (`GET /api/agents/models`). */
|
|
1592
|
+
export interface AgentModelOption {
|
|
1593
|
+
/** Canonical selector `<provider>/<model>`. */
|
|
1594
|
+
reference: string;
|
|
1595
|
+
provider: string;
|
|
1596
|
+
profile: string;
|
|
1597
|
+
providerName: string;
|
|
1598
|
+
id: string;
|
|
1599
|
+
name?: string;
|
|
1600
|
+
/** The workspace application runs this model right now. */
|
|
1601
|
+
active: boolean;
|
|
1602
|
+
capabilities: AgentModelCapabilities;
|
|
1603
|
+
/** Short capability labels such as "Reasoning", "Tools", "Vision". */
|
|
1604
|
+
labels: string[];
|
|
1605
|
+
}
|
|
1606
|
+
/** Answer of `POST /api/agents/draft`: a definition drafted by the active model. */
|
|
1607
|
+
export interface AgentDraft {
|
|
1608
|
+
name: string;
|
|
1609
|
+
description: string;
|
|
1610
|
+
instructions: string;
|
|
1611
|
+
reasoning?: {
|
|
1612
|
+
effort?: string;
|
|
1613
|
+
summary?: AgentReasoningSummary;
|
|
1614
|
+
};
|
|
1615
|
+
text?: {
|
|
1616
|
+
format?: {
|
|
1617
|
+
type: AgentTextFormatType;
|
|
1618
|
+
};
|
|
1619
|
+
verbosity?: AgentVerbosity;
|
|
1620
|
+
};
|
|
1621
|
+
/** The model that wrote the draft. */
|
|
1622
|
+
generatedBy: string;
|
|
1623
|
+
/** Authoring guidance used: `skill:<name>` (a discovered skill) or `bundled:create-agent`. */
|
|
1624
|
+
guidance: string;
|
|
1625
|
+
}
|
|
1492
1626
|
/** Body of every non-2xx web API response. */
|
|
1493
1627
|
export interface ApiError {
|
|
1494
1628
|
error: {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alisio/sdk",
|
|
3
|
-
"version": "0.1.0-alpha.
|
|
3
|
+
"version": "0.1.0-alpha.17",
|
|
4
4
|
"description": "Typed plugin SDK for Alisio: the stable contract for tools, commands, context, compaction and session hooks, model completions and storage. Types only plus tiny helpers; zero runtime dependencies.",
|
|
5
5
|
"author": "Gustavo Gutiérrez",
|
|
6
6
|
"license": "MIT",
|