@linnlabs/linnkit 0.31.0 → 0.31.1

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.
@@ -7767,7 +7767,33 @@ var TOOL_CONTEXT_RUNTIME_RESERVED_KEYS = [
7767
7767
  "parentToolCallId",
7768
7768
  "modelInputAdmission"
7769
7769
  ];
7770
- var runtimeBindings = /* @__PURE__ */ new WeakMap();
7770
+ var TOOL_CONTEXT_RUNTIME_BINDINGS_KEY = /* @__PURE__ */ Symbol.for(
7771
+ "@linnlabs/linnkit/tool-context-runtime-bindings/v1"
7772
+ );
7773
+ function isRuntimeBindingRegistry(value) {
7774
+ return value instanceof WeakMap;
7775
+ }
7776
+ function resolveRuntimeBindingRegistry() {
7777
+ const existing = Reflect.get(globalThis, TOOL_CONTEXT_RUNTIME_BINDINGS_KEY);
7778
+ if (existing !== void 0) {
7779
+ if (!isRuntimeBindingRegistry(existing)) {
7780
+ throw new Error("Linnkit ToolContext runtime binding registry has an incompatible owner.");
7781
+ }
7782
+ return existing;
7783
+ }
7784
+ const registry = /* @__PURE__ */ new WeakMap();
7785
+ const installed = Reflect.defineProperty(globalThis, TOOL_CONTEXT_RUNTIME_BINDINGS_KEY, {
7786
+ value: registry,
7787
+ configurable: false,
7788
+ enumerable: false,
7789
+ writable: false
7790
+ });
7791
+ if (!installed) {
7792
+ throw new Error("Cannot install Linnkit ToolContext runtime binding registry.");
7793
+ }
7794
+ return registry;
7795
+ }
7796
+ var runtimeBindings = resolveRuntimeBindingRegistry();
7771
7797
  function toEventSource(source) {
7772
7798
  if (typeof source === "function") {
7773
7799
  return source;