Adding Transformer
Extract transaction hashes from instructions. Use case: Transform raw Portal data before logging.Query from Transformer
Build query dynamically in transformer. Use case: Self-contained transformers that specify their own data requirements.Key Distinction: Transformers can operate in two ways:
- Pure transformation (first example): Only implements
transform()— processes data after the Portal query is executed. - Query-aware transformation (second example): Implements both
query()andtransform()— contributes to building the Portal query and processes the resulting data.
query() method, it augments the Portal query before data is fetched, allowing transformers to be self-contained with their data requirements.
