@inferencesh/sdk 0.5.13 → 0.5.15
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/http/client.js +3 -1
- package/dist/types.d.ts +14 -0
- package/dist/types.js +3 -0
- package/package.json +1 -1
package/dist/http/client.js
CHANGED
|
@@ -16,7 +16,9 @@ export class HttpClient {
|
|
|
16
16
|
this.baseUrl = config.baseUrl || 'https://api.inference.sh';
|
|
17
17
|
this.proxyUrl = config.proxyUrl;
|
|
18
18
|
this.getToken = config.getToken;
|
|
19
|
-
|
|
19
|
+
const isBrowser = typeof window !== 'undefined';
|
|
20
|
+
const sourceKey = isBrowser ? 'X-Client-Source' : 'User-Agent';
|
|
21
|
+
this.customHeaders = { [sourceKey]: 'inference-sdk-js/0.5.13', ...config.headers };
|
|
20
22
|
this.credentials = config.credentials || 'include';
|
|
21
23
|
this.onError = config.onError;
|
|
22
24
|
this.streamDefault = config.stream ?? true;
|
package/dist/types.d.ts
CHANGED
|
@@ -227,6 +227,8 @@ export interface AgentDTO extends BaseModel, PermissionModelDTO, ProjectModelDTO
|
|
|
227
227
|
export interface SkillConfig {
|
|
228
228
|
name: string;
|
|
229
229
|
description: string;
|
|
230
|
+
skill_id?: string;
|
|
231
|
+
version_id?: string;
|
|
230
232
|
url?: string;
|
|
231
233
|
content?: string;
|
|
232
234
|
}
|
|
@@ -321,6 +323,7 @@ export interface APIResponse<T extends any> {
|
|
|
321
323
|
export interface APIError {
|
|
322
324
|
code: string;
|
|
323
325
|
message: string;
|
|
326
|
+
suggestions?: string[];
|
|
324
327
|
}
|
|
325
328
|
/**
|
|
326
329
|
* ApiAppRunRequest is the request body for /apps/run endpoint.
|
|
@@ -562,6 +565,13 @@ export interface SkillPublishRequest {
|
|
|
562
565
|
metadata?: {
|
|
563
566
|
[key: string]: string;
|
|
564
567
|
};
|
|
568
|
+
/**
|
|
569
|
+
* Lineage — backend infers MutationType from context
|
|
570
|
+
*/
|
|
571
|
+
parent_skill_id?: string;
|
|
572
|
+
parent_version_id?: string;
|
|
573
|
+
source_url?: string;
|
|
574
|
+
version_notes?: string;
|
|
565
575
|
/**
|
|
566
576
|
* Spec fields for roundtrip fidelity
|
|
567
577
|
*/
|
|
@@ -1628,6 +1638,9 @@ export declare const GraphEdgeTypeDependency: GraphEdgeType;
|
|
|
1628
1638
|
export declare const GraphEdgeTypeFlow: GraphEdgeType;
|
|
1629
1639
|
export declare const GraphEdgeTypeConditional: GraphEdgeType;
|
|
1630
1640
|
export declare const GraphEdgeTypeExecution: GraphEdgeType;
|
|
1641
|
+
export declare const GraphEdgeTypeParent: GraphEdgeType;
|
|
1642
|
+
export declare const GraphEdgeTypeAncestor: GraphEdgeType;
|
|
1643
|
+
export declare const GraphEdgeTypeDuplicate: GraphEdgeType;
|
|
1631
1644
|
/**
|
|
1632
1645
|
* GraphNodeDTO is the API representation of a graph node
|
|
1633
1646
|
*/
|
|
@@ -2347,6 +2360,7 @@ export interface UserMetadata {
|
|
|
2347
2360
|
use_case: string;
|
|
2348
2361
|
use_case_reason: string;
|
|
2349
2362
|
use_case_privacy: string;
|
|
2363
|
+
signup_source: string;
|
|
2350
2364
|
}
|
|
2351
2365
|
/**
|
|
2352
2366
|
* WidgetAction represents an action triggered by a widget button
|
package/dist/types.js
CHANGED
|
@@ -124,6 +124,9 @@ export const GraphEdgeTypeDependency = "dependency"; // Blocking dependency
|
|
|
124
124
|
export const GraphEdgeTypeFlow = "flow"; // Non-blocking flow
|
|
125
125
|
export const GraphEdgeTypeConditional = "conditional"; // Conditional flow
|
|
126
126
|
export const GraphEdgeTypeExecution = "execution"; // Node → Resource execution link
|
|
127
|
+
export const GraphEdgeTypeParent = "parent"; // Parent resource → child resource (e.g. skill fork)
|
|
128
|
+
export const GraphEdgeTypeAncestor = "ancestor"; // Specific version → child resource (fork point)
|
|
129
|
+
export const GraphEdgeTypeDuplicate = "duplicate"; // Skill → skill with identical content hash
|
|
127
130
|
export const ProjectTypeAgent = "agent";
|
|
128
131
|
export const ProjectTypeApp = "app";
|
|
129
132
|
export const ProjectTypeFlow = "flow";
|