@d-id/client-sdk 1.0.1 → 1.0.2
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.
|
@@ -1,32 +1,20 @@
|
|
|
1
|
-
import { VideoType } from '../';
|
|
2
1
|
import { ExtendedTextToSpeechProviders } from '../../tts';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
voice_provider: ExtendedTextToSpeechProviders;
|
|
9
|
-
idle_video_url?: string;
|
|
2
|
+
import { LLM } from './llm';
|
|
3
|
+
import { Presenter } from './presenter';
|
|
4
|
+
export interface Agent {
|
|
5
|
+
id: string;
|
|
6
|
+
tags?: string[];
|
|
10
7
|
owner_id: string;
|
|
8
|
+
use_case?: string;
|
|
11
9
|
created_at: string;
|
|
12
10
|
modified_at: string;
|
|
13
|
-
id: string;
|
|
14
11
|
knowledge_id: string;
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
12
|
+
voice_provider: ExtendedTextToSpeechProviders;
|
|
13
|
+
llm?: LLM;
|
|
14
|
+
presenter?: Presenter;
|
|
15
|
+
access?: 'private' | 'pending-public' | 'unlisted' | 'rejected' | 'public';
|
|
16
|
+
preview_description?: string;
|
|
18
17
|
preview_thumbnail?: string;
|
|
18
|
+
preview_name: string;
|
|
19
19
|
}
|
|
20
|
-
|
|
21
|
-
type: VideoType.Clip;
|
|
22
|
-
background?: string;
|
|
23
|
-
presenterId: string;
|
|
24
|
-
driverId: string;
|
|
25
|
-
}
|
|
26
|
-
interface TalkAgent extends BaseAgent {
|
|
27
|
-
type: VideoType.Talk;
|
|
28
|
-
image_url: string;
|
|
29
|
-
}
|
|
30
|
-
export type Agent = ClipAgent | TalkAgent;
|
|
31
|
-
export type AgentPayload = Omit<Agent, 'created_by' | 'type' | 'created_at' | 'modified_at' | 'id' | 'owner_id' | 'idle_video_url'>;
|
|
32
|
-
export {};
|
|
20
|
+
export type AgentPayload = Omit<Agent, 'type' | 'created_at' | 'modified_at' | 'id' | 'owner_id' | 'idle_video_url'>;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export type LLMType = 'knowledge' | 'custom';
|
|
2
|
+
export type LLM = KnowledgeLLM | CustomLLM;
|
|
3
|
+
export interface BaseLLM {
|
|
4
|
+
type: LLMType;
|
|
5
|
+
instructions?: string;
|
|
6
|
+
}
|
|
7
|
+
export interface KnowledgeLLM extends BaseLLM {
|
|
8
|
+
type: 'knowledge';
|
|
9
|
+
knowledge_id: string;
|
|
10
|
+
store?: string;
|
|
11
|
+
}
|
|
12
|
+
export interface CustomLLM extends BaseLLM {
|
|
13
|
+
type: 'custom';
|
|
14
|
+
api_key?: string;
|
|
15
|
+
model?: string;
|
|
16
|
+
provider?: string;
|
|
17
|
+
version?: string;
|
|
18
|
+
config?: string;
|
|
19
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { ExtendedTextToSpeechProviders } from '../../tts';
|
|
2
|
+
export type videoType = 'talk' | 'clip';
|
|
3
|
+
export type Presenter = TalkPresenter | ClipPresenter;
|
|
4
|
+
export interface BasePresenter {
|
|
5
|
+
type: videoType;
|
|
6
|
+
voice?: ExtendedTextToSpeechProviders;
|
|
7
|
+
idle_video?: string;
|
|
8
|
+
thumbnail?: string;
|
|
9
|
+
}
|
|
10
|
+
export interface TalkPresenter extends BasePresenter {
|
|
11
|
+
type: 'talk';
|
|
12
|
+
source_url: string;
|
|
13
|
+
driver_url?: string;
|
|
14
|
+
}
|
|
15
|
+
export interface ClipPresenter extends BasePresenter {
|
|
16
|
+
type: 'clip';
|
|
17
|
+
driver_id: string;
|
|
18
|
+
background?: string;
|
|
19
|
+
presenter_id: string;
|
|
20
|
+
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@d-id/client-sdk",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "1.0.
|
|
4
|
+
"version": "1.0.2",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"description": "d-id client sdk",
|
|
7
7
|
"repository": {
|
|
@@ -34,7 +34,6 @@
|
|
|
34
34
|
"dopublish": "yarn build && npm publish --access public",
|
|
35
35
|
"preview": "vite preview"
|
|
36
36
|
},
|
|
37
|
-
"dependencies": {},
|
|
38
37
|
"devDependencies": {
|
|
39
38
|
"@preact/preset-vite": "^2.5.0",
|
|
40
39
|
"glob": "^10.3.10",
|