@gr33n-ai/jade-sdk-client 0.1.0 → 0.1.3
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/README.md +1 -1
- package/dist/index.cjs +927 -0
- package/dist/index.d.cts +236 -4
- package/dist/index.d.ts +236 -4
- package/dist/index.js +916 -1
- package/package.json +2 -7
- package/dist/react/index.cjs +0 -2082
- package/dist/react/index.d.cts +0 -95
- package/dist/react/index.d.ts +0 -95
- package/dist/react/index.js +0 -2070
- package/dist/types-peBknkiN.d.cts +0 -145
- package/dist/types-peBknkiN.d.ts +0 -145
package/dist/react/index.d.cts
DELETED
|
@@ -1,95 +0,0 @@
|
|
|
1
|
-
import { UseAgentSessionOptions, UseAgentSessionReturn, AgentProvider } from '@gr33n-ai/agent-sdk-client/react';
|
|
2
|
-
export * from '@gr33n-ai/agent-sdk-client/react';
|
|
3
|
-
import { P as ProcessingOptions, a as ProcessedEntry, M as MediaInfo } from '../types-peBknkiN.cjs';
|
|
4
|
-
import { ConversationEntry, AgentClientConfig } from '@gr33n-ai/agent-sdk-client';
|
|
5
|
-
|
|
6
|
-
interface UseJadeSessionOptions extends UseAgentSessionOptions {
|
|
7
|
-
/** Skip Skill context injection entries (default: true) */
|
|
8
|
-
skipSkillContext?: boolean;
|
|
9
|
-
/** Processing options */
|
|
10
|
-
processingOptions?: ProcessingOptions;
|
|
11
|
-
}
|
|
12
|
-
interface UseJadeSessionReturn extends UseAgentSessionReturn {
|
|
13
|
-
/** Processed conversation entries with tool pairing and parsing */
|
|
14
|
-
processedConversation: ProcessedEntry[];
|
|
15
|
-
/** All media extracted from conversation (deduplicated, sorted by timestamp) */
|
|
16
|
-
media: MediaInfo[];
|
|
17
|
-
}
|
|
18
|
-
/**
|
|
19
|
-
* Hook for managing Jade agent sessions with enhanced conversation processing.
|
|
20
|
-
*
|
|
21
|
-
* Extends useAgentSession with:
|
|
22
|
-
* - Processed conversation (tool call/result pairing, parsed inputs/results)
|
|
23
|
-
* - Media extraction from generated content
|
|
24
|
-
*
|
|
25
|
-
* @example
|
|
26
|
-
* ```tsx
|
|
27
|
-
* const {
|
|
28
|
-
* conversation,
|
|
29
|
-
* processedConversation,
|
|
30
|
-
* media,
|
|
31
|
-
* isStreaming,
|
|
32
|
-
* sendMessage,
|
|
33
|
-
* } = useJadeSession();
|
|
34
|
-
*
|
|
35
|
-
* // Render processed entries
|
|
36
|
-
* {processedConversation.map((entry, i) => (
|
|
37
|
-
* <MessageRenderer key={i} entry={entry} />
|
|
38
|
-
* ))}
|
|
39
|
-
*
|
|
40
|
-
* // Show media gallery
|
|
41
|
-
* {media.map((item) => (
|
|
42
|
-
* <MediaThumbnail key={item.url} {...item} />
|
|
43
|
-
* ))}
|
|
44
|
-
* ```
|
|
45
|
-
*/
|
|
46
|
-
declare function useJadeSession(options?: UseJadeSessionOptions): UseJadeSessionReturn;
|
|
47
|
-
|
|
48
|
-
/**
|
|
49
|
-
* Hook for extracting media from conversation entries.
|
|
50
|
-
*
|
|
51
|
-
* @param conversation - Array of conversation entries
|
|
52
|
-
* @returns Array of media info objects (deduplicated, sorted by timestamp)
|
|
53
|
-
*
|
|
54
|
-
* @example
|
|
55
|
-
* ```tsx
|
|
56
|
-
* const media = useMedia(conversation);
|
|
57
|
-
*
|
|
58
|
-
* {media.map((item) => (
|
|
59
|
-
* <MediaThumbnail
|
|
60
|
-
* key={item.url}
|
|
61
|
-
* url={item.url}
|
|
62
|
-
* type={item.type}
|
|
63
|
-
* prompt={item.prompt}
|
|
64
|
-
* />
|
|
65
|
-
* ))}
|
|
66
|
-
* ```
|
|
67
|
-
*/
|
|
68
|
-
declare function useMedia(conversation: ConversationEntry[]): MediaInfo[];
|
|
69
|
-
|
|
70
|
-
/**
|
|
71
|
-
* JadeProvider for Jade SDK.
|
|
72
|
-
* Re-exports AgentProvider with Jade branding.
|
|
73
|
-
*/
|
|
74
|
-
|
|
75
|
-
/**
|
|
76
|
-
* Configuration for JadeProvider.
|
|
77
|
-
*/
|
|
78
|
-
type JadeClientConfig = AgentClientConfig;
|
|
79
|
-
/**
|
|
80
|
-
* Provider component for Jade SDK.
|
|
81
|
-
* Wraps your app to provide the agent client context.
|
|
82
|
-
*
|
|
83
|
-
* @example
|
|
84
|
-
* ```tsx
|
|
85
|
-
* <JadeProvider config={{
|
|
86
|
-
* endpoint: 'https://api.jade.gr33n.ai',
|
|
87
|
-
* getAuthToken: () => authToken,
|
|
88
|
-
* }}>
|
|
89
|
-
* <App />
|
|
90
|
-
* </JadeProvider>
|
|
91
|
-
* ```
|
|
92
|
-
*/
|
|
93
|
-
declare const JadeProvider: typeof AgentProvider;
|
|
94
|
-
|
|
95
|
-
export { type JadeClientConfig, JadeProvider, type UseJadeSessionOptions, type UseJadeSessionReturn, useJadeSession, useMedia };
|
package/dist/react/index.d.ts
DELETED
|
@@ -1,95 +0,0 @@
|
|
|
1
|
-
import { UseAgentSessionOptions, UseAgentSessionReturn, AgentProvider } from '@gr33n-ai/agent-sdk-client/react';
|
|
2
|
-
export * from '@gr33n-ai/agent-sdk-client/react';
|
|
3
|
-
import { P as ProcessingOptions, a as ProcessedEntry, M as MediaInfo } from '../types-peBknkiN.js';
|
|
4
|
-
import { ConversationEntry, AgentClientConfig } from '@gr33n-ai/agent-sdk-client';
|
|
5
|
-
|
|
6
|
-
interface UseJadeSessionOptions extends UseAgentSessionOptions {
|
|
7
|
-
/** Skip Skill context injection entries (default: true) */
|
|
8
|
-
skipSkillContext?: boolean;
|
|
9
|
-
/** Processing options */
|
|
10
|
-
processingOptions?: ProcessingOptions;
|
|
11
|
-
}
|
|
12
|
-
interface UseJadeSessionReturn extends UseAgentSessionReturn {
|
|
13
|
-
/** Processed conversation entries with tool pairing and parsing */
|
|
14
|
-
processedConversation: ProcessedEntry[];
|
|
15
|
-
/** All media extracted from conversation (deduplicated, sorted by timestamp) */
|
|
16
|
-
media: MediaInfo[];
|
|
17
|
-
}
|
|
18
|
-
/**
|
|
19
|
-
* Hook for managing Jade agent sessions with enhanced conversation processing.
|
|
20
|
-
*
|
|
21
|
-
* Extends useAgentSession with:
|
|
22
|
-
* - Processed conversation (tool call/result pairing, parsed inputs/results)
|
|
23
|
-
* - Media extraction from generated content
|
|
24
|
-
*
|
|
25
|
-
* @example
|
|
26
|
-
* ```tsx
|
|
27
|
-
* const {
|
|
28
|
-
* conversation,
|
|
29
|
-
* processedConversation,
|
|
30
|
-
* media,
|
|
31
|
-
* isStreaming,
|
|
32
|
-
* sendMessage,
|
|
33
|
-
* } = useJadeSession();
|
|
34
|
-
*
|
|
35
|
-
* // Render processed entries
|
|
36
|
-
* {processedConversation.map((entry, i) => (
|
|
37
|
-
* <MessageRenderer key={i} entry={entry} />
|
|
38
|
-
* ))}
|
|
39
|
-
*
|
|
40
|
-
* // Show media gallery
|
|
41
|
-
* {media.map((item) => (
|
|
42
|
-
* <MediaThumbnail key={item.url} {...item} />
|
|
43
|
-
* ))}
|
|
44
|
-
* ```
|
|
45
|
-
*/
|
|
46
|
-
declare function useJadeSession(options?: UseJadeSessionOptions): UseJadeSessionReturn;
|
|
47
|
-
|
|
48
|
-
/**
|
|
49
|
-
* Hook for extracting media from conversation entries.
|
|
50
|
-
*
|
|
51
|
-
* @param conversation - Array of conversation entries
|
|
52
|
-
* @returns Array of media info objects (deduplicated, sorted by timestamp)
|
|
53
|
-
*
|
|
54
|
-
* @example
|
|
55
|
-
* ```tsx
|
|
56
|
-
* const media = useMedia(conversation);
|
|
57
|
-
*
|
|
58
|
-
* {media.map((item) => (
|
|
59
|
-
* <MediaThumbnail
|
|
60
|
-
* key={item.url}
|
|
61
|
-
* url={item.url}
|
|
62
|
-
* type={item.type}
|
|
63
|
-
* prompt={item.prompt}
|
|
64
|
-
* />
|
|
65
|
-
* ))}
|
|
66
|
-
* ```
|
|
67
|
-
*/
|
|
68
|
-
declare function useMedia(conversation: ConversationEntry[]): MediaInfo[];
|
|
69
|
-
|
|
70
|
-
/**
|
|
71
|
-
* JadeProvider for Jade SDK.
|
|
72
|
-
* Re-exports AgentProvider with Jade branding.
|
|
73
|
-
*/
|
|
74
|
-
|
|
75
|
-
/**
|
|
76
|
-
* Configuration for JadeProvider.
|
|
77
|
-
*/
|
|
78
|
-
type JadeClientConfig = AgentClientConfig;
|
|
79
|
-
/**
|
|
80
|
-
* Provider component for Jade SDK.
|
|
81
|
-
* Wraps your app to provide the agent client context.
|
|
82
|
-
*
|
|
83
|
-
* @example
|
|
84
|
-
* ```tsx
|
|
85
|
-
* <JadeProvider config={{
|
|
86
|
-
* endpoint: 'https://api.jade.gr33n.ai',
|
|
87
|
-
* getAuthToken: () => authToken,
|
|
88
|
-
* }}>
|
|
89
|
-
* <App />
|
|
90
|
-
* </JadeProvider>
|
|
91
|
-
* ```
|
|
92
|
-
*/
|
|
93
|
-
declare const JadeProvider: typeof AgentProvider;
|
|
94
|
-
|
|
95
|
-
export { type JadeClientConfig, JadeProvider, type UseJadeSessionOptions, type UseJadeSessionReturn, useJadeSession, useMedia };
|