@juspay/neurolink 12.12.12 → 12.12.14

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.
Files changed (35) hide show
  1. package/CHANGELOG.md +2 -2
  2. package/dist/browser/neurolink.min.js +363 -363
  3. package/dist/core/baseProvider.js +7 -4
  4. package/dist/core/modules/structuredOutputPolicy.d.ts +6 -6
  5. package/dist/core/modules/structuredOutputPolicy.js +6 -6
  6. package/dist/core/nativeGenerateLoop.js +11 -0
  7. package/dist/core/nativeToolFormat.js +3 -2
  8. package/dist/neurolink.js +4 -2
  9. package/dist/providers/amazonSagemaker.js +1 -0
  10. package/dist/providers/anthropic/cacheControl.d.ts +21 -4
  11. package/dist/providers/anthropic/cacheControl.js +37 -4
  12. package/dist/providers/anthropic/client.js +21 -12
  13. package/dist/providers/configuredOpenAICompat.d.ts +1 -1
  14. package/dist/providers/configuredOpenAICompat.js +1 -1
  15. package/dist/providers/googleAiStudio/client.js +2 -3
  16. package/dist/providers/googleVertex/client.js +2 -2
  17. package/dist/providers/openaiChatCompletionsBase.d.ts +4 -4
  18. package/dist/providers/openaiChatCompletionsBase.js +11 -10
  19. package/dist/types/context.d.ts +0 -22
  20. package/dist/types/generate.d.ts +2 -17
  21. package/dist/types/providers.d.ts +1 -27
  22. package/dist/types/service.d.ts +0 -12
  23. package/dist/utils/anthropicCacheBreakpoints.d.ts +6 -6
  24. package/dist/utils/anthropicCacheBreakpoints.js +6 -6
  25. package/dist/utils/json/coerce.d.ts +3 -2
  26. package/dist/utils/json/coerce.js +3 -2
  27. package/dist/utils/tokenUtils.d.ts +0 -1
  28. package/dist/utils/tokenUtils.js +0 -1
  29. package/dist/utils/tool.js +0 -3
  30. package/docs-site/static/search-index.json +1 -1
  31. package/package.json +3 -1
  32. package/dist/context/stepBudgetGuard.d.ts +0 -61
  33. package/dist/context/stepBudgetGuard.js +0 -357
  34. package/dist/core/serviceRegistry.d.ts +0 -40
  35. package/dist/core/serviceRegistry.js +0 -112
@@ -44,8 +44,9 @@ export function schemaAccepts(schema, value) {
44
44
  * object/array case is handled by `coerceJsonToSchema`; this covers the
45
45
  * residual scalar root after that path returns null. Encapsulates the JSON
46
46
  * parsing, the empty-string normalization, and the `schemaAccepts` gate so the
47
- * same policy cannot drift between consumers (`neurolink.recoverStructuredData`
48
- * and `GenerationHandler.coerceTextMode`).
47
+ * same policy cannot drift between consumers. `neurolink.recoverStructuredData`
48
+ * is the only one left; `GenerationHandler.coerceTextMode` was the other until
49
+ * the ai-package path was deleted.
49
50
  */
50
51
  export function recoverScalarRoot(text, schema) {
51
52
  try {
@@ -3,7 +3,6 @@
3
3
  * Handles multiple provider formats and optional fields
4
4
  *
5
5
  * Consolidates token extraction logic from:
6
- * - GenerationHandler.ts
7
6
  * - analytics.ts
8
7
  * - streamAnalytics.ts
9
8
  */
@@ -3,7 +3,6 @@
3
3
  * Handles multiple provider formats and optional fields
4
4
  *
5
5
  * Consolidates token extraction logic from:
6
- * - GenerationHandler.ts
7
6
  * - analytics.ts
8
7
  * - streamAnalytics.ts
9
8
  */
@@ -41,6 +41,3 @@ export function jsonSchema(schema, options = {}) {
41
41
  return wrapper;
42
42
  }
43
43
  export const stepCountIs = (stepCount) => ({ steps }) => steps.length === stepCount;
44
- // `Output` still comes from the upstream package: its only consumer is the
45
- // GenerationHandler path that the native provider loops made unreachable, and
46
- // that whole path is removed in a following change rather than kept alive here.