assemblyai 4.4.1 → 4.4.2-beta.0

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.
@@ -789,7 +789,7 @@ export type LemurQuestionAnswerResponse = LemurBaseResponse & {
789
789
  * ```js
790
790
  * {
791
791
  * "transcript_ids": [
792
- * "64nygnr62k-405c-4ae8-8a6b-d90b40ff3cce"
792
+ * "47b95ba5-8889-44d8-bc80-5de38306e582"
793
793
  * ],
794
794
  * "context": "This is an interview about wildfires.",
795
795
  * "final_model": "default",
@@ -901,7 +901,6 @@ export type ListTranscriptParams = {
901
901
  };
902
902
 
903
903
  /**
904
- * Details of the transcript page.
905
904
  * Details of the transcript page. Transcripts are sorted from newest to oldest. The previous URL always points to a page with older transcripts.
906
905
  * @example
907
906
  * ```js
@@ -924,12 +923,10 @@ export type PageDetails = {
924
923
  */
925
924
  limit: number;
926
925
  /**
927
- * The URL to the next page of transcripts
928
926
  * The URL to the next page of transcripts. The next URL always points to a page with newer transcripts.
929
927
  */
930
928
  next_url: string | null;
931
929
  /**
932
- * The URL to the previous page of transcripts
933
930
  * The URL to the next page of transcripts. The previous URL always points to a page with older transcripts.
934
931
  */
935
932
  prev_url: string | null;
@@ -1234,7 +1231,7 @@ export type SentencesResponse = {
1234
1231
  export type Sentiment = "POSITIVE" | "NEUTRAL" | "NEGATIVE";
1235
1232
 
1236
1233
  /**
1237
- * The result of the sentiment analysis model
1234
+ * The result of the Sentiment Analysis model
1238
1235
  * @example
1239
1236
  * ```js
1240
1237
  * {
@@ -2239,7 +2236,7 @@ export type Transcript = {
2239
2236
  auto_highlights: boolean;
2240
2237
  /**
2241
2238
  * An array of results for the Key Phrases model, if it is enabled.
2242
- * See {@link https://www.assemblyai.com/docs/models/key-phrases | Key phrases } for more information.
2239
+ * See {@link https://www.assemblyai.com/docs/models/key-phrases | Key Phrases } for more information.
2243
2240
  */
2244
2241
  auto_highlights_result?: AutoHighlightsResult | null;
2245
2242
  /**
@@ -2361,7 +2358,7 @@ export type Transcript = {
2361
2358
  sentiment_analysis?: boolean | null;
2362
2359
  /**
2363
2360
  * An array of results for the Sentiment Analysis model, if it is enabled.
2364
- * See {@link https://www.assemblyai.com/docs/models/sentiment-analysis | Sentiment analysis } for more information.
2361
+ * See {@link https://www.assemblyai.com/docs/models/sentiment-analysis | Sentiment Analysis } for more information.
2365
2362
  */
2366
2363
  sentiment_analysis_results?: SentimentAnalysisResult[] | null;
2367
2364
  /**
@@ -2438,7 +2435,7 @@ export type Transcript = {
2438
2435
  */
2439
2436
  webhook_status_code?: number | null;
2440
2437
  /**
2441
- * The URL to which we send webhooks upon trancription completion
2438
+ * The URL to which we send webhooks upon transcription completion
2442
2439
  */
2443
2440
  webhook_url?: string | null;
2444
2441
  /**
@@ -2497,19 +2494,100 @@ export type TranscriptLanguageCode =
2497
2494
  | "it"
2498
2495
  | "pt"
2499
2496
  | "nl"
2500
- | "hi"
2501
- | "ja"
2497
+ | "af"
2498
+ | "sq"
2499
+ | "am"
2500
+ | "ar"
2501
+ | "hy"
2502
+ | "as"
2503
+ | "az"
2504
+ | "ba"
2505
+ | "eu"
2506
+ | "be"
2507
+ | "bn"
2508
+ | "bs"
2509
+ | "br"
2510
+ | "bg"
2511
+ | "my"
2512
+ | "ca"
2502
2513
  | "zh"
2514
+ | "hr"
2515
+ | "cs"
2516
+ | "da"
2517
+ | "et"
2518
+ | "fo"
2503
2519
  | "fi"
2520
+ | "gl"
2521
+ | "ka"
2522
+ | "el"
2523
+ | "gu"
2524
+ | "ht"
2525
+ | "ha"
2526
+ | "haw"
2527
+ | "he"
2528
+ | "hi"
2529
+ | "hu"
2530
+ | "is"
2531
+ | "id"
2532
+ | "ja"
2533
+ | "jw"
2534
+ | "kn"
2535
+ | "kk"
2536
+ | "km"
2504
2537
  | "ko"
2538
+ | "lo"
2539
+ | "la"
2540
+ | "lv"
2541
+ | "ln"
2542
+ | "lt"
2543
+ | "lb"
2544
+ | "mk"
2545
+ | "mg"
2546
+ | "ms"
2547
+ | "ml"
2548
+ | "mt"
2549
+ | "mi"
2550
+ | "mr"
2551
+ | "mn"
2552
+ | "ne"
2553
+ | "no"
2554
+ | "nn"
2555
+ | "oc"
2556
+ | "pa"
2557
+ | "ps"
2558
+ | "fa"
2505
2559
  | "pl"
2560
+ | "ro"
2506
2561
  | "ru"
2562
+ | "sa"
2563
+ | "sr"
2564
+ | "sn"
2565
+ | "sd"
2566
+ | "si"
2567
+ | "sk"
2568
+ | "sl"
2569
+ | "so"
2570
+ | "su"
2571
+ | "sw"
2572
+ | "sv"
2573
+ | "tl"
2574
+ | "tg"
2575
+ | "ta"
2576
+ | "tt"
2577
+ | "te"
2578
+ | "th"
2579
+ | "bo"
2507
2580
  | "tr"
2581
+ | "tk"
2508
2582
  | "uk"
2509
- | "vi";
2583
+ | "ur"
2584
+ | "uz"
2585
+ | "vi"
2586
+ | "cy"
2587
+ | "yi"
2588
+ | "yo";
2510
2589
 
2511
2590
  /**
2512
- * A list of transcripts
2513
2591
  * A list of transcripts. Transcripts are sorted from newest to oldest. The previous URL always points to a page with older transcripts.
2514
2592
  * @example
2515
2593
  * ```js
@@ -2649,7 +2727,7 @@ export type TranscriptOptionalParams = {
2649
2727
  */
2650
2728
  auto_chapters?: boolean;
2651
2729
  /**
2652
- * Whether Key Phrases is enabled, either true or false
2730
+ * Enable Key Phrases, either true or false
2653
2731
  */
2654
2732
  auto_highlights?: boolean;
2655
2733
  /**
@@ -2661,7 +2739,7 @@ export type TranscriptOptionalParams = {
2661
2739
  */
2662
2740
  content_safety?: boolean;
2663
2741
  /**
2664
- * The confidence threshold for content moderation. Values must be between 25 and 100.
2742
+ * The confidence threshold for the Content Moderation model. Values must be between 25 and 100.
2665
2743
  */
2666
2744
  content_safety_confidence?: number;
2667
2745
  /**
@@ -2669,7 +2747,7 @@ export type TranscriptOptionalParams = {
2669
2747
  */
2670
2748
  custom_spelling?: TranscriptCustomSpelling[];
2671
2749
  /**
2672
- * Whether custom topics is enabled, either true or false
2750
+ * Enable custom topics, either true or false
2673
2751
  */
2674
2752
  custom_topics?: boolean;
2675
2753
  /**
@@ -2702,7 +2780,7 @@ export type TranscriptOptionalParams = {
2702
2780
  */
2703
2781
  language_code?: LiteralUnion<TranscriptLanguageCode, string> | null;
2704
2782
  /**
2705
- * Whether {@link https://www.assemblyai.com/docs/models/speech-recognition#automatic-language-detection | Automatic language detection } was enabled in the transcription request, either true or false.
2783
+ * Enable {@link https://www.assemblyai.com/docs/models/speech-recognition#automatic-language-detection | Automatic language detection }, either true or false.
2706
2784
  */
2707
2785
  language_detection?: boolean;
2708
2786
  /**
@@ -2770,7 +2848,7 @@ export type TranscriptOptionalParams = {
2770
2848
  */
2771
2849
  summary_type?: SummaryType;
2772
2850
  /**
2773
- * The list of custom topics provided, if custom topics is enabled
2851
+ * The list of custom topics
2774
2852
  */
2775
2853
  topics?: string[];
2776
2854
  /**
@@ -2784,7 +2862,7 @@ export type TranscriptOptionalParams = {
2784
2862
  */
2785
2863
  webhook_auth_header_value?: string | null;
2786
2864
  /**
2787
- * The URL to which AssemblyAI send webhooks upon trancription completion
2865
+ * The URL to which AssemblyAI send webhooks upon transcription completion
2788
2866
  */
2789
2867
  webhook_url?: string;
2790
2868
  /**
package/src/utils/path.ts CHANGED
@@ -1,6 +1,7 @@
1
1
  export function getPath(path: string) {
2
2
  if (path.startsWith("http")) return null;
3
3
  if (path.startsWith("https")) return null;
4
+ if (path.startsWith("data:")) return null;
4
5
  if (path.startsWith("file://")) return path.substring(7);
5
6
  if (path.startsWith("file:")) return path.substring(5);
6
7
  return path;
@@ -1,15 +0,0 @@
1
- var ws = null;
2
-
3
- if (typeof WebSocket !== "undefined") {
4
- ws = WebSocket;
5
- } else if (typeof MozWebSocket !== "undefined") {
6
- ws = MozWebSocket;
7
- } else if (typeof global !== "undefined") {
8
- ws = global.WebSocket || global.MozWebSocket;
9
- } else if (typeof window !== "undefined") {
10
- ws = window.WebSocket || window.MozWebSocket;
11
- } else if (typeof self !== "undefined") {
12
- ws = self.WebSocket || self.MozWebSocket;
13
- }
14
-
15
- export default ws;
@@ -1 +0,0 @@
1
- module.exports = require("ws");
@@ -1,2 +0,0 @@
1
- import ws from "ws";
2
- export default ws;
@@ -1,2 +0,0 @@
1
- import ws from "ws";
2
- export default ws;