@dudousxd/nestjs-agent 1.25.1 → 1.26.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,4 +1,4 @@
1
- import { ResolveToolUiCatalog, ModelProvider, AgentStore, ToolRegistry, RolesPolicy, ApprovalPolicy, QuotaStore, TokenStreamSink, PromptBuilder, PromptContributor, Persona, ToolTransientRetrySetting, Retriever, AgentPricingStore, HistoryPolicy, InputProcessor, OutputProcessor, AgentIntake, SkillsConfig, MemoryConfig, ToolSpec, ToolHandler, createFunctionalTool, QuotaProvider, QuotaQuery, QuotaReport, ActionApprovalMode, BackgroundActorResolver, ActionProposal, TextActionProposalConfig, ModelCatalog, EmptyRoles, ActorResolver, AgentHistoryWindow, SkillProvider, ScopeResolver, MemoryProvider, AgentRegistry, PersonaCatalogEntry, Actor, AttachmentStagingStore, ChatQueueStore, ChatQueueState, AgentRunner, AgentRunInput, AgentStreamEvent, QueuePauseReason } from '@dudousxd/nestjs-agent-core';
1
+ import { ResolveToolUiCatalog, ModelProvider, AgentStore, ToolRegistry, RolesPolicy, ApprovalPolicy, QuotaStore, TokenStreamSink, PromptBuilder, PromptContributor, Persona, ToolTransientRetrySetting, Retriever, AgentPricingStore, HistoryPolicy, InputProcessor, OutputProcessor, AgentIntake, SkillsConfig, MemoryConfig, ToolSpec, ToolHandler, createFunctionalTool, QuotaProvider, QuotaQuery, QuotaReport, ActionApprovalMode, BackgroundActorResolver, ActionProposal, TextActionProposalConfig, ModelsDevOptions, ModelCatalog, EmptyRoles, ActorResolver, AgentHistoryWindow, SkillProvider, ScopeResolver, MemoryProvider, AgentRegistry, PersonaCatalogEntry, Actor, AttachmentStagingStore, ChatQueueStore, ChatQueueState, AgentRunner, AgentRunInput, AgentStreamEvent, QueuePauseReason } from '@dudousxd/nestjs-agent-core';
2
2
  import { Catalog } from '@dudousxd/nestjs-agent-core/genui';
3
3
  import { StandardSchemaV1 } from '@standard-schema/spec';
4
4
  import { Provider, InjectionToken, Type, FactoryProvider, CanActivate, ModuleMetadata, OptionalFactoryDependency } from '@nestjs/common';
@@ -320,6 +320,18 @@ interface AgentModuleOptions {
320
320
  * turns instead.
321
321
  */
322
322
  model?: ModelProvider;
323
+ /**
324
+ * Where a configured model with no price row gets one, at boot. On application bootstrap every
325
+ * model the `model` provider describes (`aiSdkModel` / `aiSdkModels`) that the bound
326
+ * `AGENT_PRICING_STORE` does not price gets the current [models.dev](https://models.dev) list price
327
+ * written as its row — only when it has none, so a price you set is never overwritten. A model that
328
+ * still has no price, and whose provider reports no cost (anything but OpenRouter / the Vercel AI
329
+ * Gateway), is named in one boot warning: it would record a `null` cost on every turn.
330
+ *
331
+ * Omit → models.dev, except under `NODE_ENV=test` (no network from a test suite unless asked).
332
+ * `{ url, fetch }` points at a mirror; `false` never fetches (the warning still runs).
333
+ */
334
+ priceCatalog?: ModelsDevOptions | false;
323
335
  /**
324
336
  * Run turns on something other than this library's loop — e.g. `openCode({ host })`. The engine
325
337
  * binds `AGENT_RUNNER`; the routes, store, sink, approvals and queue stay the library's. STATIC
@@ -1,4 +1,4 @@
1
- import { ResolveToolUiCatalog, ModelProvider, AgentStore, ToolRegistry, RolesPolicy, ApprovalPolicy, QuotaStore, TokenStreamSink, PromptBuilder, PromptContributor, Persona, ToolTransientRetrySetting, Retriever, AgentPricingStore, HistoryPolicy, InputProcessor, OutputProcessor, AgentIntake, SkillsConfig, MemoryConfig, ToolSpec, ToolHandler, createFunctionalTool, QuotaProvider, QuotaQuery, QuotaReport, ActionApprovalMode, BackgroundActorResolver, ActionProposal, TextActionProposalConfig, ModelCatalog, EmptyRoles, ActorResolver, AgentHistoryWindow, SkillProvider, ScopeResolver, MemoryProvider, AgentRegistry, PersonaCatalogEntry, Actor, AttachmentStagingStore, ChatQueueStore, ChatQueueState, AgentRunner, AgentRunInput, AgentStreamEvent, QueuePauseReason } from '@dudousxd/nestjs-agent-core';
1
+ import { ResolveToolUiCatalog, ModelProvider, AgentStore, ToolRegistry, RolesPolicy, ApprovalPolicy, QuotaStore, TokenStreamSink, PromptBuilder, PromptContributor, Persona, ToolTransientRetrySetting, Retriever, AgentPricingStore, HistoryPolicy, InputProcessor, OutputProcessor, AgentIntake, SkillsConfig, MemoryConfig, ToolSpec, ToolHandler, createFunctionalTool, QuotaProvider, QuotaQuery, QuotaReport, ActionApprovalMode, BackgroundActorResolver, ActionProposal, TextActionProposalConfig, ModelsDevOptions, ModelCatalog, EmptyRoles, ActorResolver, AgentHistoryWindow, SkillProvider, ScopeResolver, MemoryProvider, AgentRegistry, PersonaCatalogEntry, Actor, AttachmentStagingStore, ChatQueueStore, ChatQueueState, AgentRunner, AgentRunInput, AgentStreamEvent, QueuePauseReason } from '@dudousxd/nestjs-agent-core';
2
2
  import { Catalog } from '@dudousxd/nestjs-agent-core/genui';
3
3
  import { StandardSchemaV1 } from '@standard-schema/spec';
4
4
  import { Provider, InjectionToken, Type, FactoryProvider, CanActivate, ModuleMetadata, OptionalFactoryDependency } from '@nestjs/common';
@@ -320,6 +320,18 @@ interface AgentModuleOptions {
320
320
  * turns instead.
321
321
  */
322
322
  model?: ModelProvider;
323
+ /**
324
+ * Where a configured model with no price row gets one, at boot. On application bootstrap every
325
+ * model the `model` provider describes (`aiSdkModel` / `aiSdkModels`) that the bound
326
+ * `AGENT_PRICING_STORE` does not price gets the current [models.dev](https://models.dev) list price
327
+ * written as its row — only when it has none, so a price you set is never overwritten. A model that
328
+ * still has no price, and whose provider reports no cost (anything but OpenRouter / the Vercel AI
329
+ * Gateway), is named in one boot warning: it would record a `null` cost on every turn.
330
+ *
331
+ * Omit → models.dev, except under `NODE_ENV=test` (no network from a test suite unless asked).
332
+ * `{ url, fetch }` points at a mirror; `false` never fetches (the warning still runs).
333
+ */
334
+ priceCatalog?: ModelsDevOptions | false;
323
335
  /**
324
336
  * Run turns on something other than this library's loop — e.g. `openCode({ host })`. The engine
325
337
  * binds `AGENT_RUNNER`; the routes, store, sink, approvals and queue stay the library's. STATIC