llmist 2.6.0 → 3.0.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.
@@ -1,6 +1,6 @@
1
1
  import { PassThrough, Readable, Writable } from 'node:stream';
2
- import { L as LLMMessage, B as BaseGadget, I as IConversationManager, a as LLMStream, b as LLMStreamChunk } from '../mock-stream-Jgg5u6Uf.cjs';
3
- export { j as MockAudioData, d as MockBuilder, k as MockImageData, f as MockManager, l as MockMatcher, n as MockMatcherContext, o as MockOptions, M as MockProviderAdapter, p as MockRegistration, q as MockResponse, r as MockStats, c as createMockAdapter, e as createMockClient, h as createMockStream, i as createTextMockStream, g as getMockManager, m as mockLLM } from '../mock-stream-Jgg5u6Uf.cjs';
2
+ import { L as LLMMessage, A as AbstractGadget, I as IConversationManager, a as LLMStream, b as LLMStreamChunk } from '../mock-stream-COHw8h9b.cjs';
3
+ export { j as MockAudioData, d as MockBuilder, k as MockImageData, f as MockManager, l as MockMatcher, n as MockMatcherContext, o as MockOptions, M as MockProviderAdapter, p as MockRegistration, q as MockResponse, r as MockStats, c as createMockAdapter, e as createMockClient, h as createMockStream, i as createTextMockStream, g as getMockManager, m as mockLLM } from '../mock-stream-COHw8h9b.cjs';
4
4
  import { ZodType } from 'zod';
5
5
  import 'tslog';
6
6
 
@@ -324,7 +324,7 @@ interface TestGadgetOptions {
324
324
  * expect(skipped.validatedParams).toEqual({ a: 5 }); // No defaults applied
325
325
  * ```
326
326
  */
327
- declare function testGadget(gadget: BaseGadget, params: Record<string, unknown>, options?: TestGadgetOptions): Promise<TestGadgetResult>;
327
+ declare function testGadget(gadget: AbstractGadget, params: Record<string, unknown>, options?: TestGadgetOptions): Promise<TestGadgetResult>;
328
328
  /**
329
329
  * Test multiple parameter sets against a gadget.
330
330
  *
@@ -348,7 +348,7 @@ declare function testGadget(gadget: BaseGadget, params: Record<string, unknown>,
348
348
  * expect(results[2].error).toBeDefined();
349
349
  * ```
350
350
  */
351
- declare function testGadgetBatch(gadget: BaseGadget, paramSets: Record<string, unknown>[], options?: TestGadgetOptions): Promise<TestGadgetResult[]>;
351
+ declare function testGadgetBatch(gadget: AbstractGadget, paramSets: Record<string, unknown>[], options?: TestGadgetOptions): Promise<TestGadgetResult[]>;
352
352
 
353
353
  /**
354
354
  * Mock ConversationManager for testing compaction and agent components.
@@ -383,7 +383,7 @@ declare class MockConversationManager implements IConversationManager {
383
383
  constructor(history?: LLMMessage[], baseMessages?: LLMMessage[]);
384
384
  addUserMessage(content: string): void;
385
385
  addAssistantMessage(content: string): void;
386
- addGadgetCall(gadgetName: string, parameters: Record<string, unknown>, result: string): void;
386
+ addGadgetCallResult(gadgetName: string, parameters: Record<string, unknown>, result: string): void;
387
387
  getMessages(): LLMMessage[];
388
388
  getHistoryMessages(): LLMMessage[];
389
389
  getBaseMessages(): LLMMessage[];
@@ -457,7 +457,7 @@ interface RecordedCall {
457
457
  /**
458
458
  * Mock gadget with call tracking capabilities.
459
459
  */
460
- interface MockGadget extends BaseGadget {
460
+ interface MockGadget extends AbstractGadget {
461
461
  /** Get all recorded calls */
462
462
  getCalls(): RecordedCall[];
463
463
  /** Get number of times the gadget was executed */
@@ -1,6 +1,6 @@
1
1
  import { PassThrough, Readable, Writable } from 'node:stream';
2
- import { L as LLMMessage, B as BaseGadget, I as IConversationManager, a as LLMStream, b as LLMStreamChunk } from '../mock-stream-Jgg5u6Uf.js';
3
- export { j as MockAudioData, d as MockBuilder, k as MockImageData, f as MockManager, l as MockMatcher, n as MockMatcherContext, o as MockOptions, M as MockProviderAdapter, p as MockRegistration, q as MockResponse, r as MockStats, c as createMockAdapter, e as createMockClient, h as createMockStream, i as createTextMockStream, g as getMockManager, m as mockLLM } from '../mock-stream-Jgg5u6Uf.js';
2
+ import { L as LLMMessage, A as AbstractGadget, I as IConversationManager, a as LLMStream, b as LLMStreamChunk } from '../mock-stream-COHw8h9b.js';
3
+ export { j as MockAudioData, d as MockBuilder, k as MockImageData, f as MockManager, l as MockMatcher, n as MockMatcherContext, o as MockOptions, M as MockProviderAdapter, p as MockRegistration, q as MockResponse, r as MockStats, c as createMockAdapter, e as createMockClient, h as createMockStream, i as createTextMockStream, g as getMockManager, m as mockLLM } from '../mock-stream-COHw8h9b.js';
4
4
  import { ZodType } from 'zod';
5
5
  import 'tslog';
6
6
 
@@ -324,7 +324,7 @@ interface TestGadgetOptions {
324
324
  * expect(skipped.validatedParams).toEqual({ a: 5 }); // No defaults applied
325
325
  * ```
326
326
  */
327
- declare function testGadget(gadget: BaseGadget, params: Record<string, unknown>, options?: TestGadgetOptions): Promise<TestGadgetResult>;
327
+ declare function testGadget(gadget: AbstractGadget, params: Record<string, unknown>, options?: TestGadgetOptions): Promise<TestGadgetResult>;
328
328
  /**
329
329
  * Test multiple parameter sets against a gadget.
330
330
  *
@@ -348,7 +348,7 @@ declare function testGadget(gadget: BaseGadget, params: Record<string, unknown>,
348
348
  * expect(results[2].error).toBeDefined();
349
349
  * ```
350
350
  */
351
- declare function testGadgetBatch(gadget: BaseGadget, paramSets: Record<string, unknown>[], options?: TestGadgetOptions): Promise<TestGadgetResult[]>;
351
+ declare function testGadgetBatch(gadget: AbstractGadget, paramSets: Record<string, unknown>[], options?: TestGadgetOptions): Promise<TestGadgetResult[]>;
352
352
 
353
353
  /**
354
354
  * Mock ConversationManager for testing compaction and agent components.
@@ -383,7 +383,7 @@ declare class MockConversationManager implements IConversationManager {
383
383
  constructor(history?: LLMMessage[], baseMessages?: LLMMessage[]);
384
384
  addUserMessage(content: string): void;
385
385
  addAssistantMessage(content: string): void;
386
- addGadgetCall(gadgetName: string, parameters: Record<string, unknown>, result: string): void;
386
+ addGadgetCallResult(gadgetName: string, parameters: Record<string, unknown>, result: string): void;
387
387
  getMessages(): LLMMessage[];
388
388
  getHistoryMessages(): LLMMessage[];
389
389
  getBaseMessages(): LLMMessage[];
@@ -457,7 +457,7 @@ interface RecordedCall {
457
457
  /**
458
458
  * Mock gadget with call tracking capabilities.
459
459
  */
460
- interface MockGadget extends BaseGadget {
460
+ interface MockGadget extends AbstractGadget {
461
461
  /** Get all recorded calls */
462
462
  getCalls(): RecordedCall[];
463
463
  /** Get number of times the gadget was executed */
@@ -38,7 +38,7 @@ import {
38
38
  testGadget,
39
39
  testGadgetBatch,
40
40
  waitFor
41
- } from "../chunk-364PEMVT.js";
41
+ } from "../chunk-67MMSOAT.js";
42
42
  export {
43
43
  MockBuilder,
44
44
  MockConversationManager,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "llmist",
3
- "version": "2.6.0",
3
+ "version": "3.0.0",
4
4
  "description": "TypeScript LLM client with streaming tool execution. Tools fire mid-stream. Built-in function calling works with any model—no structured outputs or native tool support required.",
5
5
  "type": "module",
6
6
  "main": "dist/index.cjs",