@deepdesk/deepdesk-sdk 17.0.0-rc.4 → 17.0.0-rc.6

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.mts CHANGED
@@ -998,6 +998,9 @@ type SendEventV2ArgumentMap = {
998
998
  question: string;
999
999
  sourceViewed: string;
1000
1000
  }>;
1001
+ 'knowledge assist reset': EventV2<{
1002
+ threadId?: number;
1003
+ }>;
1001
1004
  'summary feedback': EventV2<{
1002
1005
  summary: string;
1003
1006
  rating: 'up' | 'down';
@@ -1383,7 +1386,17 @@ type Transcript = Array<{
1383
1386
  source: string;
1384
1387
  text: string;
1385
1388
  }>;
1386
- type TranscriptOption = 'in-memory-transcript' | 'stored-transcript' | Transcript;
1389
+ type TranscriptOption = 'in-memory-transcript' | Transcript;
1390
+ interface EvaluateInput {
1391
+ assistantCode: string;
1392
+ threadId?: number;
1393
+ input?: any;
1394
+ transcript?: TranscriptOption;
1395
+ includeMetadata?: boolean;
1396
+ skipState?: boolean;
1397
+ expectFormat: Server.ResponseFormat;
1398
+ }
1399
+ type SummaryInput = Omit<EvaluateInput, 'assistantCode' | 'expectFormat'>;
1387
1400
 
1388
1401
  type State$1 = {
1389
1402
  data: Entity[] | null;
@@ -1872,6 +1885,7 @@ declare const styles: {
1872
1885
  readonly "formInput": string;
1873
1886
  readonly "formSubmit": string;
1874
1887
  readonly "linkContent": string;
1888
+ readonly "resetContainer": string;
1875
1889
  readonly "showMoreSources": string;
1876
1890
  readonly "source": string;
1877
1891
  readonly "sources": string;
@@ -1990,12 +2004,12 @@ interface SDKEventMap {
1990
2004
  suggestion: TextSuggestion;
1991
2005
  eventMetrics: SuggestionEventMetrics;
1992
2006
  };
1993
- 'reset': {
2007
+ reset: {
1994
2008
  text: string;
1995
2009
  selectionAfter: SelectionRange;
1996
2010
  };
1997
- 'cues': LegacyCue[];
1998
- 'replace': {
2011
+ cues: LegacyCue[];
2012
+ replace: {
1999
2013
  text: string;
2000
2014
  replace: SelectionRange;
2001
2015
  };
@@ -2005,7 +2019,7 @@ interface SDKEventMap {
2005
2019
  'edit-suggestion': EditTextSuggestionPayload;
2006
2020
  'send-message': string;
2007
2021
  'send-message-event': SendMessageEventData$1;
2008
- 'event': {
2022
+ event: {
2009
2023
  name: string;
2010
2024
  data: unknown;
2011
2025
  };
@@ -2050,6 +2064,7 @@ interface WidgetOptions {
2050
2064
  showImages?: boolean;
2051
2065
  isEmbedded?: boolean;
2052
2066
  knowledgeAssist?: KnowledgeAssistOptions;
2067
+ assistantOptions?: Omit<EvaluateInput, 'assistantCode'>;
2053
2068
  }
2054
2069
  interface KnowledgeAssistantWidgetOptions extends KnowledgeAssistOptions {
2055
2070
  customStyles?: WidgetCustomStyles;
@@ -2260,7 +2275,7 @@ declare class DeepdeskSDK {
2260
2275
  /**
2261
2276
  * Evaluate conversation lifecycle assistant
2262
2277
  * Convenient wrapper around `evaluateAssistant`.
2263
- * By default includes 'stored-transcript' and 'metadata'.
2278
+ * By default includes the server transcript and 'metadata'.
2264
2279
  */
2265
2280
  evaluateConversationAssistant(event: 'accepted' | 'new-message' | 'ended', options?: {
2266
2281
  input?: Record<string, any>;
@@ -2271,7 +2286,7 @@ declare class DeepdeskSDK {
2271
2286
  /**
2272
2287
  * Get summary from conversation
2273
2288
  */
2274
- getSummary(): Promise<string | null>;
2289
+ getSummary(args?: SummaryInput): Promise<string | null>;
2275
2290
  private handleKeyDown;
2276
2291
  private handleAfterSendMessage;
2277
2292
  handlingTimeStart(): void;
package/dist/index.d.ts CHANGED
@@ -998,6 +998,9 @@ type SendEventV2ArgumentMap = {
998
998
  question: string;
999
999
  sourceViewed: string;
1000
1000
  }>;
1001
+ 'knowledge assist reset': EventV2<{
1002
+ threadId?: number;
1003
+ }>;
1001
1004
  'summary feedback': EventV2<{
1002
1005
  summary: string;
1003
1006
  rating: 'up' | 'down';
@@ -1383,7 +1386,17 @@ type Transcript = Array<{
1383
1386
  source: string;
1384
1387
  text: string;
1385
1388
  }>;
1386
- type TranscriptOption = 'in-memory-transcript' | 'stored-transcript' | Transcript;
1389
+ type TranscriptOption = 'in-memory-transcript' | Transcript;
1390
+ interface EvaluateInput {
1391
+ assistantCode: string;
1392
+ threadId?: number;
1393
+ input?: any;
1394
+ transcript?: TranscriptOption;
1395
+ includeMetadata?: boolean;
1396
+ skipState?: boolean;
1397
+ expectFormat: Server.ResponseFormat;
1398
+ }
1399
+ type SummaryInput = Omit<EvaluateInput, 'assistantCode' | 'expectFormat'>;
1387
1400
 
1388
1401
  type State$1 = {
1389
1402
  data: Entity[] | null;
@@ -1872,6 +1885,7 @@ declare const styles: {
1872
1885
  readonly "formInput": string;
1873
1886
  readonly "formSubmit": string;
1874
1887
  readonly "linkContent": string;
1888
+ readonly "resetContainer": string;
1875
1889
  readonly "showMoreSources": string;
1876
1890
  readonly "source": string;
1877
1891
  readonly "sources": string;
@@ -1990,12 +2004,12 @@ interface SDKEventMap {
1990
2004
  suggestion: TextSuggestion;
1991
2005
  eventMetrics: SuggestionEventMetrics;
1992
2006
  };
1993
- 'reset': {
2007
+ reset: {
1994
2008
  text: string;
1995
2009
  selectionAfter: SelectionRange;
1996
2010
  };
1997
- 'cues': LegacyCue[];
1998
- 'replace': {
2011
+ cues: LegacyCue[];
2012
+ replace: {
1999
2013
  text: string;
2000
2014
  replace: SelectionRange;
2001
2015
  };
@@ -2005,7 +2019,7 @@ interface SDKEventMap {
2005
2019
  'edit-suggestion': EditTextSuggestionPayload;
2006
2020
  'send-message': string;
2007
2021
  'send-message-event': SendMessageEventData$1;
2008
- 'event': {
2022
+ event: {
2009
2023
  name: string;
2010
2024
  data: unknown;
2011
2025
  };
@@ -2050,6 +2064,7 @@ interface WidgetOptions {
2050
2064
  showImages?: boolean;
2051
2065
  isEmbedded?: boolean;
2052
2066
  knowledgeAssist?: KnowledgeAssistOptions;
2067
+ assistantOptions?: Omit<EvaluateInput, 'assistantCode'>;
2053
2068
  }
2054
2069
  interface KnowledgeAssistantWidgetOptions extends KnowledgeAssistOptions {
2055
2070
  customStyles?: WidgetCustomStyles;
@@ -2260,7 +2275,7 @@ declare class DeepdeskSDK {
2260
2275
  /**
2261
2276
  * Evaluate conversation lifecycle assistant
2262
2277
  * Convenient wrapper around `evaluateAssistant`.
2263
- * By default includes 'stored-transcript' and 'metadata'.
2278
+ * By default includes the server transcript and 'metadata'.
2264
2279
  */
2265
2280
  evaluateConversationAssistant(event: 'accepted' | 'new-message' | 'ended', options?: {
2266
2281
  input?: Record<string, any>;
@@ -2271,7 +2286,7 @@ declare class DeepdeskSDK {
2271
2286
  /**
2272
2287
  * Get summary from conversation
2273
2288
  */
2274
- getSummary(): Promise<string | null>;
2289
+ getSummary(args?: SummaryInput): Promise<string | null>;
2275
2290
  private handleKeyDown;
2276
2291
  private handleAfterSendMessage;
2277
2292
  handlingTimeStart(): void;