pi-fabric 0.109.5 → 0.109.6

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.
@@ -6415,16 +6415,8 @@ function createFabricExtension(entryUrl) {
6415
6415
  const customType = "fabric-extractive-history";
6416
6416
  const messages = event.messages.filter((message) => !(message.role === "custom" && message.customType === customType));
6417
6417
  if (!extractiveConfig()?.enabled) invalidateExtractive(true);
6418
- const view = extractiveHistory?.view(context);
6419
- if (!view) return messages.length !== event.messages.length ? { messages } : void 0;
6420
- return { messages: [{
6421
- role: "custom",
6422
- customType,
6423
- content: view.text,
6424
- display: false,
6425
- timestamp: 0,
6426
- details: { advisory: true, ...view.usage ? { classifierUsage: view.usage } : {} }
6427
- }, ...messages] };
6418
+ const projected = extractiveHistory?.inject(context, messages) ?? messages;
6419
+ return projected !== messages || messages.length !== event.messages.length ? { messages: projected } : void 0;
6428
6420
  });
6429
6421
  pi.on("before_agent_start", async (event, context) => {
6430
6422
  const config = state.bootstrapped ? state.config : DEFAULT_FABRIC_CONFIG;
@@ -6592,4 +6584,4 @@ export {
6592
6584
  FABRIC_MANAGED_HOST_VERSION,
6593
6585
  createFabricExtension
6594
6586
  };
6595
- //# sourceMappingURL=chunk-N7HJRZCL.js.map
6587
+ //# sourceMappingURL=chunk-N3QMJGY6.js.map