@tanstack/ai-devtools-core 0.0.1 → 0.0.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 CHANGED
@@ -115,7 +115,7 @@ We're looking for TanStack AI Partners to join our mission! Partner with us to p
115
115
 
116
116
  - <a href="https://github.com/tanstack/config"><b>TanStack Config</b></a> – Tooling for JS/TS packages
117
117
  - <a href="https://github.com/tanstack/db"><b>TanStack DB</b></a> – Reactive sync client store
118
- - <a href="https://github.com/tanstack/devtools">TanStack Devtools</a> – Unified devtools panel
118
+ - <a href="https://github.com/tanstack/devtools"><b>TanStack Devtools</b></a> – Unified devtools panel
119
119
  - <a href="https://github.com/tanstack/form"><b>TanStack Form</b></a> – Type‑safe form state
120
120
  - <a href="https://github.com/tanstack/pacer"><b>TanStack Pacer</b></a> – Debouncing, throttling, batching
121
121
  - <a href="https://github.com/tanstack/query"><b>TanStack Query</b></a> – Async state & caching
@@ -263,8 +263,6 @@ const AIProvider = (props) => {
263
263
  model: void 0,
264
264
  provider: "Client"
265
265
  });
266
- }, {
267
- withEventTarget: false
268
266
  }));
269
267
  cleanupFns.push(aiEventClient.on("client:message-sent", (e) => {
270
268
  const clientId = e.payload.clientId;
@@ -281,8 +279,6 @@ const AIProvider = (props) => {
281
279
  updateConversation(clientId, {
282
280
  status: "active"
283
281
  });
284
- }, {
285
- withEventTarget: false
286
282
  }));
287
283
  cleanupFns.push(aiEventClient.on("client:message-appended", (e) => {
288
284
  const clientId = e.payload.clientId;
@@ -306,8 +302,6 @@ const AIProvider = (props) => {
306
302
  source: "client"
307
303
  });
308
304
  }
309
- }, {
310
- withEventTarget: false
311
305
  }));
312
306
  cleanupFns.push(aiEventClient.on("client:loading-changed", (e) => {
313
307
  const clientId = e.payload.clientId;
@@ -316,8 +310,6 @@ const AIProvider = (props) => {
316
310
  status: e.payload.isLoading ? "active" : "completed"
317
311
  });
318
312
  }
319
- }, {
320
- withEventTarget: false
321
313
  }));
322
314
  cleanupFns.push(aiEventClient.on("client:stopped", (e) => {
323
315
  const clientId = e.payload.clientId;
@@ -327,8 +319,6 @@ const AIProvider = (props) => {
327
319
  completedAt: e.payload.timestamp
328
320
  });
329
321
  }
330
- }, {
331
- withEventTarget: false
332
322
  }));
333
323
  cleanupFns.push(aiEventClient.on("client:messages-cleared", (e) => {
334
324
  const clientId = e.payload.clientId;
@@ -339,8 +329,6 @@ const AIProvider = (props) => {
339
329
  usage: void 0
340
330
  });
341
331
  }
342
- }, {
343
- withEventTarget: false
344
332
  }));
345
333
  cleanupFns.push(aiEventClient.on("client:reloaded", (e) => {
346
334
  const clientId = e.payload.clientId;
@@ -351,8 +339,6 @@ const AIProvider = (props) => {
351
339
  status: "active"
352
340
  });
353
341
  }
354
- }, {
355
- withEventTarget: false
356
342
  }));
357
343
  cleanupFns.push(aiEventClient.on("client:error-changed", (e) => {
358
344
  const clientId = e.payload.clientId;
@@ -361,8 +347,6 @@ const AIProvider = (props) => {
361
347
  status: "error"
362
348
  });
363
349
  }
364
- }, {
365
- withEventTarget: false
366
350
  }));
367
351
  cleanupFns.push(aiEventClient.on("client:assistant-message-updated", (e) => {
368
352
  const clientId = e.payload.clientId;
@@ -377,8 +361,6 @@ const AIProvider = (props) => {
377
361
  model: conv.model
378
362
  });
379
363
  }
380
- }, {
381
- withEventTarget: false
382
364
  }));
383
365
  cleanupFns.push(aiEventClient.on("client:tool-call-updated", (e) => {
384
366
  const {
@@ -408,8 +390,6 @@ const AIProvider = (props) => {
408
390
  } else {
409
391
  setToolCalls(clientId, messageIndex, [...toolCalls, toolCall]);
410
392
  }
411
- }, {
412
- withEventTarget: false
413
393
  }));
414
394
  cleanupFns.push(aiEventClient.on("client:approval-requested", (e) => {
415
395
  const {
@@ -431,8 +411,6 @@ const AIProvider = (props) => {
431
411
  approvalId,
432
412
  state: "approval-requested"
433
413
  });
434
- }, {
435
- withEventTarget: false
436
414
  }));
437
415
  cleanupFns.push(aiEventClient.on("tool:result-added", (e) => {
438
416
  const {
@@ -468,8 +446,6 @@ const AIProvider = (props) => {
468
446
  return;
469
447
  }
470
448
  }
471
- }, {
472
- withEventTarget: false
473
449
  }));
474
450
  cleanupFns.push(aiEventClient.on("tool:approval-responded", (e) => {
475
451
  const {
@@ -491,8 +467,6 @@ const AIProvider = (props) => {
491
467
  return;
492
468
  }
493
469
  }
494
- }, {
495
- withEventTarget: false
496
470
  }));
497
471
  cleanupFns.push(aiEventClient.on("stream:chunk:content", (e) => {
498
472
  const streamId = e.payload.streamId;
@@ -514,8 +488,6 @@ const AIProvider = (props) => {
514
488
  ensureMessageForChunk(conversationId, e.payload.messageId, e.payload.timestamp);
515
489
  addChunk(conversationId, chunk);
516
490
  }
517
- }, {
518
- withEventTarget: false
519
491
  }));
520
492
  cleanupFns.push(aiEventClient.on("stream:chunk:tool-call", (e) => {
521
493
  const streamId = e.payload.streamId;
@@ -538,8 +510,6 @@ const AIProvider = (props) => {
538
510
  ensureMessageForChunk(conversationId, e.payload.messageId, e.payload.timestamp);
539
511
  addChunk(conversationId, chunk);
540
512
  }
541
- }, {
542
- withEventTarget: false
543
513
  }));
544
514
  cleanupFns.push(aiEventClient.on("stream:chunk:tool-result", (e) => {
545
515
  const streamId = e.payload.streamId;
@@ -575,8 +545,6 @@ const AIProvider = (props) => {
575
545
  }
576
546
  }
577
547
  }
578
- }, {
579
- withEventTarget: false
580
548
  }));
581
549
  cleanupFns.push(aiEventClient.on("stream:chunk:thinking", (e) => {
582
550
  const streamId = e.payload.streamId;
@@ -606,8 +574,6 @@ const AIProvider = (props) => {
606
574
  ensureMessageForChunk(conversationId, e.payload.messageId, e.payload.timestamp);
607
575
  addChunk(conversationId, chunk);
608
576
  }
609
- }, {
610
- withEventTarget: false
611
577
  }));
612
578
  cleanupFns.push(aiEventClient.on("stream:chunk:done", (e) => {
613
579
  const streamId = e.payload.streamId;
@@ -638,8 +604,6 @@ const AIProvider = (props) => {
638
604
  status: "completed",
639
605
  completedAt: e.payload.timestamp
640
606
  });
641
- }, {
642
- withEventTarget: false
643
607
  }));
644
608
  cleanupFns.push(aiEventClient.on("stream:chunk:error", (e) => {
645
609
  const streamId = e.payload.streamId;
@@ -664,8 +628,6 @@ const AIProvider = (props) => {
664
628
  status: "error",
665
629
  completedAt: e.payload.timestamp
666
630
  });
667
- }, {
668
- withEventTarget: false
669
631
  }));
670
632
  cleanupFns.push(aiEventClient.on("stream:ended", (e) => {
671
633
  const streamId = e.payload.streamId;
@@ -675,8 +637,6 @@ const AIProvider = (props) => {
675
637
  status: "completed",
676
638
  completedAt: e.payload.timestamp
677
639
  });
678
- }, {
679
- withEventTarget: false
680
640
  }));
681
641
  cleanupFns.push(aiEventClient.on("stream:approval-requested", (e) => {
682
642
  const {
@@ -723,8 +683,6 @@ const AIProvider = (props) => {
723
683
  }
724
684
  }
725
685
  }
726
- }, {
727
- withEventTarget: false
728
686
  }));
729
687
  cleanupFns.push(aiEventClient.on("processor:text-updated", (e) => {
730
688
  const streamId = e.payload.streamId;
@@ -745,8 +703,6 @@ const AIProvider = (props) => {
745
703
  content: e.payload.content
746
704
  });
747
705
  }
748
- }, {
749
- withEventTarget: false
750
706
  }));
751
707
  cleanupFns.push(aiEventClient.on("processor:tool-call-state-changed", (e) => {
752
708
  const streamId = e.payload.streamId;
@@ -769,8 +725,6 @@ const AIProvider = (props) => {
769
725
  setToolCalls(conversationId, conv.messages.length - 1, [...toolCalls, toolCall]);
770
726
  }
771
727
  }
772
- }, {
773
- withEventTarget: false
774
728
  }));
775
729
  cleanupFns.push(aiEventClient.on("processor:tool-result-state-changed", (e) => {
776
730
  const streamId = e.payload.streamId;
@@ -789,8 +743,6 @@ const AIProvider = (props) => {
789
743
  return;
790
744
  }
791
745
  }
792
- }, {
793
- withEventTarget: false
794
746
  }));
795
747
  cleanupFns.push(aiEventClient.on("chat:started", (e) => {
796
748
  const streamId = e.payload.streamId;
@@ -828,8 +780,6 @@ const AIProvider = (props) => {
828
780
  });
829
781
  }
830
782
  }
831
- }, {
832
- withEventTarget: false
833
783
  }));
834
784
  cleanupFns.push(aiEventClient.on("chat:completed", (e) => {
835
785
  const {
@@ -850,8 +800,6 @@ const AIProvider = (props) => {
850
800
  updateMessageUsage(conversationId, e.payload.messageId, usage);
851
801
  }
852
802
  }
853
- }, {
854
- withEventTarget: false
855
803
  }));
856
804
  cleanupFns.push(aiEventClient.on("chat:iteration", (e) => {
857
805
  const {
@@ -864,8 +812,6 @@ const AIProvider = (props) => {
864
812
  iterationCount: iterationNumber
865
813
  });
866
814
  }
867
- }, {
868
- withEventTarget: false
869
815
  }));
870
816
  cleanupFns.push(aiEventClient.on("usage:tokens", (e) => {
871
817
  const {
@@ -880,8 +826,6 @@ const AIProvider = (props) => {
880
826
  });
881
827
  updateMessageUsage(conversationId, messageId, usage);
882
828
  }
883
- }, {
884
- withEventTarget: false
885
829
  }));
886
830
  cleanupFns.push(aiEventClient.on("tool:call-completed", (e) => {
887
831
  const {
@@ -934,8 +878,6 @@ const AIProvider = (props) => {
934
878
  return;
935
879
  }
936
880
  }
937
- }, {
938
- withEventTarget: false
939
881
  }));
940
882
  cleanupFns.push(aiEventClient.on("embedding:started", (e) => {
941
883
  const {
@@ -973,8 +915,6 @@ const AIProvider = (props) => {
973
915
  setState("conversations", conversationId, "embeddings", [...embeddings, embeddingOp]);
974
916
  setState("conversations", conversationId, "hasEmbedding", true);
975
917
  }
976
- }, {
977
- withEventTarget: false
978
918
  }));
979
919
  cleanupFns.push(aiEventClient.on("embedding:completed", (e) => {
980
920
  const {
@@ -992,8 +932,6 @@ const AIProvider = (props) => {
992
932
  op.status = "completed";
993
933
  }));
994
934
  }
995
- }, {
996
- withEventTarget: false
997
935
  }));
998
936
  cleanupFns.push(aiEventClient.on("summarize:started", (e) => {
999
937
  const {
@@ -1030,8 +968,6 @@ const AIProvider = (props) => {
1030
968
  setState("conversations", conversationId, "summaries", [...summaries, summarizeOp]);
1031
969
  setState("conversations", conversationId, "hasSummarize", true);
1032
970
  }
1033
- }, {
1034
- withEventTarget: false
1035
971
  }));
1036
972
  cleanupFns.push(aiEventClient.on("summarize:completed", (e) => {
1037
973
  const {
@@ -1051,8 +987,6 @@ const AIProvider = (props) => {
1051
987
  op.status = "completed";
1052
988
  }));
1053
989
  }
1054
- }, {
1055
- withEventTarget: false
1056
990
  }));
1057
991
  onCleanup(() => {
1058
992
  for (const cleanup of cleanupFns) {