From 4e182afdd017351d1c88d31109f55c6b1047d8e0 Mon Sep 17 00:00:00 2001 From: bgodlin <37313677+bgodlin@users.noreply.github.com> Date: Tue, 11 Jun 2024 19:11:35 +0000 Subject: [PATCH 1/5] Featuring SQ mech tool --- packages/subquery/__init__.py | 19 +++ packages/subquery/customs/__init__.py | 19 +++ .../customs/graphql-data-fetching/__init__.py | 20 +++ .../graphql-data-fetching/component.yaml | 14 ++ .../graphql-response-analyser.py | 121 ++++++++++++++++++ 5 files changed, 193 insertions(+) create mode 100644 packages/subquery/__init__.py create mode 100644 packages/subquery/customs/__init__.py create mode 100644 packages/subquery/customs/graphql-data-fetching/__init__.py create mode 100644 packages/subquery/customs/graphql-data-fetching/component.yaml create mode 100644 packages/subquery/customs/graphql-data-fetching/graphql-response-analyser.py diff --git a/packages/subquery/__init__.py b/packages/subquery/__init__.py new file mode 100644 index 00000000..ba697745 --- /dev/null +++ b/packages/subquery/__init__.py @@ -0,0 +1,19 @@ +#!/usr/bin/env python3 +# -*- coding: utf-8 -*- +# ------------------------------------------------------------------------------ +# +# Copyright 2024 Valory AG +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# ------------------------------------------------------------------------------ diff --git a/packages/subquery/customs/__init__.py b/packages/subquery/customs/__init__.py new file mode 100644 index 00000000..ba697745 --- /dev/null +++ b/packages/subquery/customs/__init__.py @@ -0,0 +1,19 @@ +#!/usr/bin/env python3 +# -*- coding: utf-8 -*- +# ------------------------------------------------------------------------------ +# +# Copyright 2024 Valory AG +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# ------------------------------------------------------------------------------ diff --git a/packages/subquery/customs/graphql-data-fetching/__init__.py b/packages/subquery/customs/graphql-data-fetching/__init__.py new file mode 100644 index 00000000..4888dbc7 --- /dev/null +++ b/packages/subquery/customs/graphql-data-fetching/__init__.py @@ -0,0 +1,20 @@ +# -*- coding: utf-8 -*- +# ------------------------------------------------------------------------------ +# +# Copyright 2023-2024 Valory AG +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# ------------------------------------------------------------------------------ + +"""This module explains the output of the GraphQL server within a given context, including a description of the indexed data being served and the query itself.""" diff --git a/packages/subquery/customs/graphql-data-fetching/component.yaml b/packages/subquery/customs/graphql-data-fetching/component.yaml new file mode 100644 index 00000000..bda93389 --- /dev/null +++ b/packages/subquery/customs/graphql-data-fetching/component.yaml @@ -0,0 +1,14 @@ +name: graphql-response-analyser +author: subquery +version: 0.1.0 +type: custom +description: This module explains the output of the GraphQL server within a given context, including a description of the indexed data being served and the query itself. +license: Apache-2.0 +aea_version: '>=1.0.0, <2.0.0' +entry_point: graphql-response-analyser.py +callable: run +dependencies: + openai: + version: ==1.11.0 + tiktoken: + version: ==0.5.1 diff --git a/packages/subquery/customs/graphql-data-fetching/graphql-response-analyser.py b/packages/subquery/customs/graphql-data-fetching/graphql-response-analyser.py new file mode 100644 index 00000000..024abc27 --- /dev/null +++ b/packages/subquery/customs/graphql-data-fetching/graphql-response-analyser.py @@ -0,0 +1,121 @@ +# -*- coding: utf-8 -*- +# ------------------------------------------------------------------------------ +# +# Copyright 2023-2024 Valory AG +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# ------------------------------------------------------------------------------ + +"""This module accepts a GraphQL endpoint, executes queries based on a given description, and explains the response in natural language""" + +from typing import Any, Dict, Optional, Tuple +import os +from openai import OpenAI +import json +import requests + +client: Optional[OpenAI] = None + + +# Analyze data and generate response using OpenAI +def analyse_data_and_generate_response(description, query, data): + return f""" + + You're a GraphQL query response analyzer. You will be provided with context about the data served by the endpoint, as well as the executed query, to give you a better understanding. Based on this, you are expected to return a short bullet point description of the response in natural language. + + Description: + + {json.dumps(description)} + + Query: + + {json.dumps(query)} + + Reponse: + + {json.dumps(data)} + + """ + + +class OpenAIClientManager: + """Client context manager for OpenAI.""" + + def __init__(self, api_key: str): + self.api_key = api_key + + def __enter__(self) -> OpenAI: + global client + if client is None: + client = OpenAI(api_key=self.api_key) + return client + + def __exit__(self, exc_type, exc_value, traceback) -> None: + global client + if client is not None: + client.close() + client = None + + +DEFAULT_OPENAI_SETTINGS = { + "max_tokens": 500, + "temperature": 0.7, +} +PREFIX = "openai-" +ENGINES = { + "chat": ["gpt-3.5-turbo", "gpt-4"], + "completion": ["gpt-3.5-turbo-instruct"], +} +ALLOWED_TOOLS = [PREFIX + value for values in ENGINES.values() for value in values] + + +def fetch_data_from_indexer(endpoint, query): + response = requests.post(endpoint, json={"query": query}) + if response.status_code == 200: + return response.json() + else: + raise Exception( + f"Failed to fetch schema: {response.status_code}, {response.text}" + ) + + +def run(**kwargs) -> Tuple[Optional[str], Optional[Dict[str, Any]], Any, Any]: + """Run the task""" + with OpenAIClientManager(kwargs["api_keys"]["openai"]): + max_tokens = kwargs.get("max_tokens", DEFAULT_OPENAI_SETTINGS["max_tokens"]) + temperature = kwargs.get("temperature", DEFAULT_OPENAI_SETTINGS["temperature"]) + endpoint = kwargs.get("endpoint") + description = kwargs.get("description") + tool = kwargs["tool"] + query = kwargs["query"] + requested_data = fetch_data_from_indexer(endpoint, query) + engine = tool.replace(PREFIX, "") + messages = [ + { + "role": "user", + "content": analyse_data_and_generate_response( + description, query, requested_data + ), + }, + ] + response = client.chat.completions.create( + model=engine, + messages=messages, + temperature=temperature, + max_tokens=max_tokens, + n=1, + timeout=120, + stop=None, + ) + return response.choices[0].message.content, None, None, None From 41a53976ffdf35c008c956dea7a23edb93d38d15 Mon Sep 17 00:00:00 2001 From: bgodlin <37313677+bgodlin@users.noreply.github.com> Date: Tue, 25 Jun 2024 15:16:49 +0000 Subject: [PATCH 2/5] Added a test to verify the successful query response analysis --- .../__init__.py | 0 .../component.yaml | 4 +-- .../graphql_response_analyser.py} | 5 +-- tests/test_tools.py | 36 +++++++++++++++++++ tox.ini | 2 +- 5 files changed, 42 insertions(+), 5 deletions(-) rename packages/subquery/customs/{graphql-data-fetching => graphql_response_analyser}/__init__.py (100%) rename packages/subquery/customs/{graphql-data-fetching => graphql_response_analyser}/component.yaml (82%) rename packages/subquery/customs/{graphql-data-fetching/graphql-response-analyser.py => graphql_response_analyser/graphql_response_analyser.py} (91%) diff --git a/packages/subquery/customs/graphql-data-fetching/__init__.py b/packages/subquery/customs/graphql_response_analyser/__init__.py similarity index 100% rename from packages/subquery/customs/graphql-data-fetching/__init__.py rename to packages/subquery/customs/graphql_response_analyser/__init__.py diff --git a/packages/subquery/customs/graphql-data-fetching/component.yaml b/packages/subquery/customs/graphql_response_analyser/component.yaml similarity index 82% rename from packages/subquery/customs/graphql-data-fetching/component.yaml rename to packages/subquery/customs/graphql_response_analyser/component.yaml index bda93389..ec9f52b1 100644 --- a/packages/subquery/customs/graphql-data-fetching/component.yaml +++ b/packages/subquery/customs/graphql_response_analyser/component.yaml @@ -1,11 +1,11 @@ -name: graphql-response-analyser +name: graphql_response_analyser author: subquery version: 0.1.0 type: custom description: This module explains the output of the GraphQL server within a given context, including a description of the indexed data being served and the query itself. license: Apache-2.0 aea_version: '>=1.0.0, <2.0.0' -entry_point: graphql-response-analyser.py +entry_point: graphql_response_analyser.py callable: run dependencies: openai: diff --git a/packages/subquery/customs/graphql-data-fetching/graphql-response-analyser.py b/packages/subquery/customs/graphql_response_analyser/graphql_response_analyser.py similarity index 91% rename from packages/subquery/customs/graphql-data-fetching/graphql-response-analyser.py rename to packages/subquery/customs/graphql_response_analyser/graphql_response_analyser.py index 024abc27..c6abe3c5 100644 --- a/packages/subquery/customs/graphql-data-fetching/graphql-response-analyser.py +++ b/packages/subquery/customs/graphql_response_analyser/graphql_response_analyser.py @@ -20,7 +20,6 @@ """This module accepts a GraphQL endpoint, executes queries based on a given description, and explains the response in natural language""" from typing import Any, Dict, Optional, Tuple -import os from openai import OpenAI import json import requests @@ -32,7 +31,7 @@ def analyse_data_and_generate_response(description, query, data): return f""" - You're a GraphQL query response analyzer. You will be provided with context about the data served by the endpoint, as well as the executed query, to give you a better understanding. Based on this, you are expected to return a short bullet point description of the response in natural language. + You're a GraphQL query response analyzer. You will be provided with context about the data served by the endpoint, as well as the executed query, to give you a better understanding. Description: @@ -46,6 +45,8 @@ def analyse_data_and_generate_response(description, query, data): {json.dumps(data)} + Based on the provided context, please generate a bullet-pointed summary in a machine-readable JSON format. The JSON structure should have an array object named 'analysis_result,' with each analytical conclusion represented as a separate string element within the array. + """ diff --git a/tests/test_tools.py b/tests/test_tools.py index bb0c7882..45a22b6d 100644 --- a/tests/test_tools.py +++ b/tests/test_tools.py @@ -31,6 +31,9 @@ from packages.valory.customs.prediction_request import prediction_request from packages.valory.skills.task_execution.utils.apis import KeyChain from packages.valory.skills.task_execution.utils.benchmarks import TokenCounterCallback + +from packages.subquery.customs.graphql_response_analyser import graphql_response_analyser + from tests.constants import ( OPENAI_SECRET_KEY, STABILITY_API_KEY, @@ -175,3 +178,36 @@ def _validate_response(self, response: Any) -> None: super()._validate_response(response) expected_num_tx_params = 2 assert len(response[2].keys()) == expected_num_tx_params + +test_query = """ +{ + transfers { + aggregates { + keys + sum { + value + } + } + } +} +""" + +class TestGraphResponseAnalyser(): + """Check successful query output analysis""" + + tool_callable: str = "run" + tool_module = graphql_response_analyser + + def test_run(self) -> None: + """Test run method.""" + kwargs = dict( + tool = "openai-gpt-3.5-turbo", + request="When was the first transfer?", + query = test_query, + endpoint="https://api.subquery.network/sq/subquery/cusdnew__c3Vic", + description="This project manages and indexes data pertaining to cUSD (CELO USD) ERC-20 token transfers and approvals recorded within a dedicated smart contract. The stored data includes information on approvals granted and transfers executed. These entities provide insights into the authorization and movement of USDT tokens within the CELO ecosystem, facilitating analysis and monitoring of token transactions.", + api_keys={"openai": OPENAI_SECRET_KEY} + ) + func = getattr(self.tool_module, self.tool_callable) + response = func(**kwargs) + assert "analysis_result" in response[0] \ No newline at end of file diff --git a/tox.ini b/tox.ini index b38610c0..6e9f2175 100644 --- a/tox.ini +++ b/tox.ini @@ -20,7 +20,7 @@ deps = {[deps-tests]deps} open-autonomy==0.14.10 fastapi==0.110.3 - openai==0.27.2 + openai==1.11.0 requests==2.28.1 mech-client==0.2.5 py-multibase==1.0.3 From 6c4a857f58b2d2cac4049141ccda44e161b6a8c5 Mon Sep 17 00:00:00 2001 From: bgodlin <37313677+bgodlin@users.noreply.github.com> Date: Tue, 23 Jul 2024 17:14:04 +0000 Subject: [PATCH 3/5] Logic was revised --- .../graphql_response_analyser/component.yaml | 2 +- .../graphql_response_analyser.py | 106 ++++++++++++++---- tests/subquery/examples.py | 53 +++++++++ tests/test_tools.py | 35 +++--- 4 files changed, 152 insertions(+), 44 deletions(-) create mode 100644 tests/subquery/examples.py diff --git a/packages/subquery/customs/graphql_response_analyser/component.yaml b/packages/subquery/customs/graphql_response_analyser/component.yaml index ec9f52b1..8cdbfb6c 100644 --- a/packages/subquery/customs/graphql_response_analyser/component.yaml +++ b/packages/subquery/customs/graphql_response_analyser/component.yaml @@ -2,7 +2,7 @@ name: graphql_response_analyser author: subquery version: 0.1.0 type: custom -description: This module explains the output of the GraphQL server within a given context, including a description of the indexed data being served and the query itself. +description: This module explains the output of the GraphQL chain data indexer within a given context, including a description of the indexed data being served and the query itself. license: Apache-2.0 aea_version: '>=1.0.0, <2.0.0' entry_point: graphql_response_analyser.py diff --git a/packages/subquery/customs/graphql_response_analyser/graphql_response_analyser.py b/packages/subquery/customs/graphql_response_analyser/graphql_response_analyser.py index c6abe3c5..ac61215f 100644 --- a/packages/subquery/customs/graphql_response_analyser/graphql_response_analyser.py +++ b/packages/subquery/customs/graphql_response_analyser/graphql_response_analyser.py @@ -17,9 +17,10 @@ # # ------------------------------------------------------------------------------ -"""This module accepts a GraphQL endpoint, executes queries based on a given description, and explains the response in natural language""" +"""Contains the job definitions""" from typing import Any, Dict, Optional, Tuple +import os from openai import OpenAI import json import requests @@ -27,26 +28,38 @@ client: Optional[OpenAI] = None +def generate_graphql_query(user_request, schema, description, examples): + return ( + f""" + You are a GraphQL query generator. Based on the following GraphQL schema and the user's natural language request, generate a valid GraphQL query. + + GraphQL Project Description: "{description}" + + User Request: "{user_request}" + + GraphQL Schema: {json.dumps(schema)} + + Example Queries: + + """ + + examples + + """ + + GraphQL Query: + +""" + ) + + # Analyze data and generate response using OpenAI -def analyse_data_and_generate_response(description, query, data): +def analyze_data_and_generate_response(data): return f""" - You're a GraphQL query response analyzer. You will be provided with context about the data served by the endpoint, as well as the executed query, to give you a better understanding. - - Description: - - {json.dumps(description)} - - Query: - - {json.dumps(query)} + Once the query you have given was executed, the following data was fetched: - Reponse: - - {json.dumps(data)} + JSON Data: {json.dumps(data)} Based on the provided context, please generate a bullet-pointed summary in a machine-readable JSON format. The JSON structure should have an array object named 'analysis_result,' with each analytical conclusion represented as a separate string element within the array. - """ @@ -81,6 +94,33 @@ def __exit__(self, exc_type, exc_value, traceback) -> None: ALLOWED_TOOLS = [PREFIX + value for values in ENGINES.values() for value in values] +# Fetch the GraphQL schema using introspection query +def fetch_graphql_schema(endpoint): + introspection_query = """ + { + __schema { + types { + name + fields { + name + type { + kind + name + } + } + } + } + } + """ + response = requests.post(endpoint, json={"query": introspection_query}) + if response.status_code == 200: + return response.json() + else: + raise Exception( + f"Failed to fetch schema: {response.status_code}, {response.text}" + ) + + def fetch_data_from_indexer(endpoint, query): response = requests.post(endpoint, json={"query": query}) if response.status_code == 200: @@ -98,16 +138,40 @@ def run(**kwargs) -> Tuple[Optional[str], Optional[Dict[str, Any]], Any, Any]: temperature = kwargs.get("temperature", DEFAULT_OPENAI_SETTINGS["temperature"]) endpoint = kwargs.get("endpoint") description = kwargs.get("description") + request = kwargs.get("request") + examples = kwargs.get("examples") tool = kwargs["tool"] - query = kwargs["query"] - requested_data = fetch_data_from_indexer(endpoint, query) + schema = fetch_graphql_schema(endpoint) + prompt = generate_graphql_query(request, schema, description, examples) + if tool not in ALLOWED_TOOLS: + return ( + f"Tool {tool} is not in the list of supported tools.", + None, + None, + None, + ) engine = tool.replace(PREFIX, "") messages = [ + {"role": "user", "content": prompt}, + ] + response = client.chat.completions.create( + model=engine, + messages=messages, + temperature=temperature, + max_tokens=max_tokens, + n=1, + timeout=120, + stop=None, + ) + query_to_be_used = response.choices[0].message.content + print(query_to_be_used) + requested_data = fetch_data_from_indexer(endpoint, query_to_be_used) + messages = [ + {"role": "user", "content": prompt}, + {"role": "user", "content": query_to_be_used}, { "role": "user", - "content": analyse_data_and_generate_response( - description, query, requested_data - ), + "content": analyze_data_and_generate_response(requested_data), }, ] response = client.chat.completions.create( @@ -119,4 +183,4 @@ def run(**kwargs) -> Tuple[Optional[str], Optional[Dict[str, Any]], Any, Any]: timeout=120, stop=None, ) - return response.choices[0].message.content, None, None, None + return response.choices[0].message.content, prompt, None, None \ No newline at end of file diff --git a/tests/subquery/examples.py b/tests/subquery/examples.py new file mode 100644 index 00000000..88a0b280 --- /dev/null +++ b/tests/subquery/examples.py @@ -0,0 +1,53 @@ +query_examples = """ +1. + +# Provide me a list of addresses that have made the highest number of transfers to a specific address + +query MyQuery { + account(id: "0x0000000000000000000000000000000000000000") { + id + receivedTransfers { + groupedAggregates(groupBy: FROM_ID) { + keys + distinctCount { + id + } + } + } + } +} + +2. + +# Please provide a list of addresses who transfered the highest amounts within the certain timeframe. + +query MyQuery { + account(id: "0x0000000000000000000000000000000000000000") { + id + receivedTransfers( + first: 5 + filter: {and: [{timestamp: {greaterThan: "0"}}, {timestamp: {lessThan: "1000"}}]} + ) { + groupedAggregates(groupBy: FROM_ID) { + keys + sum { + value + } + } + } + } +} + +3. + +# Please provide a first transfer ever indexed + +query MyQuery { + transfers(first: 1, orderBy: TIMESTAMP_ASC) { + nodes { + id + value + } + } +} +""" \ No newline at end of file diff --git a/tests/test_tools.py b/tests/test_tools.py index b3734394..e2d25e68 100644 --- a/tests/test_tools.py +++ b/tests/test_tools.py @@ -33,7 +33,10 @@ from packages.valory.skills.task_execution.utils.apis import KeyChain from packages.valory.skills.task_execution.utils.benchmarks import TokenCounterCallback -from packages.subquery.customs.graphql_response_analyser import graphql_response_analyser +from packages.subquery.customs.graphql_response_analyser import ( + graphql_response_analyser +) +from tests.subquery.examples import query_examples from tests.constants import ( OPENAI_SECRET_KEY, @@ -190,35 +193,23 @@ class TestDALLEGeneration(BaseToolTest): ] tool_module = dalle_request -test_query = """ -{ - transfers { - aggregates { - keys - sum { - value - } - } - } -} -""" - -class TestGraphResponseAnalyser(): + +class TestGraphResponseAnalyser: """Check successful query output analysis""" - + tool_callable: str = "run" tool_module = graphql_response_analyser def test_run(self) -> None: """Test run method.""" kwargs = dict( - tool = "openai-gpt-3.5-turbo", + tool="openai-gpt-3.5-turbo", request="When was the first transfer?", - query = test_query, - endpoint="https://api.subquery.network/sq/subquery/cusdnew__c3Vic", - description="This project manages and indexes data pertaining to cUSD (CELO USD) ERC-20 token transfers and approvals recorded within a dedicated smart contract. The stored data includes information on approvals granted and transfers executed. These entities provide insights into the authorization and movement of USDT tokens within the CELO ecosystem, facilitating analysis and monitoring of token transactions.", - api_keys={"openai": OPENAI_SECRET_KEY} + examples=query_examples, + endpoint="https://api.subquery.network/sq/subquery/cusdnew", + description="This project manages and indexes data pertaining to cUSD (CELO USD) ERC-20 token transfers and approvals recorded within a dedicated smart contract. The stored data includes information on approvals granted and transfers executed. These entities provide insights into the authorization and movement of cUSD tokens within the CELO ecosystem, facilitating analysis and monitoring of token transactions.", + api_keys={"openai": OPENAI_SECRET_KEY}, ) func = getattr(self.tool_module, self.tool_callable) response = func(**kwargs) - assert "analysis_result" in response[0] \ No newline at end of file + assert "analysis_result" in response[0] From 593ac4450292bcc1cc4c1e4dcf46437f16905f37 Mon Sep 17 00:00:00 2001 From: bgodlin <37313677+bgodlin@users.noreply.github.com> Date: Thu, 1 Aug 2024 15:19:42 +0000 Subject: [PATCH 4/5] Comments Addressed --- .../graphql_response_analyser/component.yaml | 9 +++++---- tests/subquery/examples.py | 19 +++++++++++++++++++ 2 files changed, 24 insertions(+), 4 deletions(-) diff --git a/packages/subquery/customs/graphql_response_analyser/component.yaml b/packages/subquery/customs/graphql_response_analyser/component.yaml index 8cdbfb6c..d8291a50 100644 --- a/packages/subquery/customs/graphql_response_analyser/component.yaml +++ b/packages/subquery/customs/graphql_response_analyser/component.yaml @@ -8,7 +8,8 @@ aea_version: '>=1.0.0, <2.0.0' entry_point: graphql_response_analyser.py callable: run dependencies: - openai: - version: ==1.11.0 - tiktoken: - version: ==0.5.1 + openai: + version: ==1.11.0 + tiktoken: + version: ==0.5.1 + requests: {} diff --git a/tests/subquery/examples.py b/tests/subquery/examples.py index 88a0b280..39204f24 100644 --- a/tests/subquery/examples.py +++ b/tests/subquery/examples.py @@ -1,3 +1,22 @@ +# -*- coding: utf-8 -*- +# ------------------------------------------------------------------------------ +# +# Copyright 2024 Valory AG +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# ------------------------------------------------------------------------------ + query_examples = """ 1. From b1d089f9b977b633a8e58cd1d2e3f089b60ef069 Mon Sep 17 00:00:00 2001 From: bgodlin <37313677+bgodlin@users.noreply.github.com> Date: Thu, 8 Aug 2024 15:42:01 +0000 Subject: [PATCH 5/5] fingerprint; fingerprint_ignore_patterns added --- .../subquery/customs/graphql_response_analyser/component.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/subquery/customs/graphql_response_analyser/component.yaml b/packages/subquery/customs/graphql_response_analyser/component.yaml index d8291a50..fcd53c8b 100644 --- a/packages/subquery/customs/graphql_response_analyser/component.yaml +++ b/packages/subquery/customs/graphql_response_analyser/component.yaml @@ -6,6 +6,10 @@ description: This module explains the output of the GraphQL chain data indexer w license: Apache-2.0 aea_version: '>=1.0.0, <2.0.0' entry_point: graphql_response_analyser.py +fingerprint: + __init__.py: + graphql_response_analyser.py: +fingerprint_ignore_patterns: [] callable: run dependencies: openai: