mirror of
https://github.com/hwchase17/langchain
synced 2024-11-18 09:25:54 +00:00
4cb5f4c353
This PR should make it easier for linters to do type checking and for IDEs to jump to definition of code. See #20050 as a template for this PR. - As a byproduct: Added 3 missed `test_imports`. - Added missed `SolarChat` in to __init___.py Added it into test_import ut. - Added `# type: ignore` to fix linting. It is not clear, why linting errors appear after ^ changes. --------- Co-authored-by: Eugene Yurtsev <eyurtsev@gmail.com>
146 lines
3.6 KiB
Python
146 lines
3.6 KiB
Python
from langchain_community.tools import __all__, _module_lookup
|
|
|
|
EXPECTED_ALL = [
|
|
"AINAppOps",
|
|
"AINOwnerOps",
|
|
"AINRuleOps",
|
|
"AINTransfer",
|
|
"AINValueOps",
|
|
"AIPluginTool",
|
|
"APIOperation",
|
|
"ArxivQueryRun",
|
|
"AzureAiServicesDocumentIntelligenceTool",
|
|
"AzureAiServicesImageAnalysisTool",
|
|
"AzureAiServicesSpeechToTextTool",
|
|
"AzureAiServicesTextToSpeechTool",
|
|
"AzureAiServicesTextAnalyticsForHealthTool",
|
|
"AzureCogsFormRecognizerTool",
|
|
"AzureCogsImageAnalysisTool",
|
|
"AzureCogsSpeech2TextTool",
|
|
"AzureCogsText2SpeechTool",
|
|
"AzureCogsTextAnalyticsHealthTool",
|
|
"BaseGraphQLTool",
|
|
"BaseRequestsTool",
|
|
"BaseSQLDatabaseTool",
|
|
"BaseSparkSQLTool",
|
|
"BaseTool",
|
|
"BearlyInterpreterTool",
|
|
"BingSearchResults",
|
|
"BingSearchRun",
|
|
"BraveSearch",
|
|
"ClickTool",
|
|
"CogniswitchKnowledgeSourceFile",
|
|
"CogniswitchKnowledgeSourceURL",
|
|
"CogniswitchKnowledgeRequest",
|
|
"CogniswitchKnowledgeStatus",
|
|
"ConneryAction",
|
|
"CopyFileTool",
|
|
"CurrentWebPageTool",
|
|
"DeleteFileTool",
|
|
"DuckDuckGoSearchResults",
|
|
"DuckDuckGoSearchRun",
|
|
"E2BDataAnalysisTool",
|
|
"EdenAiExplicitImageTool",
|
|
"EdenAiObjectDetectionTool",
|
|
"EdenAiParsingIDTool",
|
|
"EdenAiParsingInvoiceTool",
|
|
"EdenAiSpeechToTextTool",
|
|
"EdenAiTextModerationTool",
|
|
"EdenAiTextToSpeechTool",
|
|
"EdenaiTool",
|
|
"ElevenLabsText2SpeechTool",
|
|
"ExtractHyperlinksTool",
|
|
"ExtractTextTool",
|
|
"FileSearchTool",
|
|
"GetElementsTool",
|
|
"GmailCreateDraft",
|
|
"GmailGetMessage",
|
|
"GmailGetThread",
|
|
"GmailSearch",
|
|
"GmailSendMessage",
|
|
"GoogleCloudTextToSpeechTool",
|
|
"GooglePlacesTool",
|
|
"GoogleSearchResults",
|
|
"GoogleSearchRun",
|
|
"GoogleSerperResults",
|
|
"GoogleSerperRun",
|
|
"HumanInputRun",
|
|
"IFTTTWebhook",
|
|
"InfoPowerBITool",
|
|
"InfoSQLDatabaseTool",
|
|
"InfoSparkSQLTool",
|
|
"JiraAction",
|
|
"JsonGetValueTool",
|
|
"JsonListKeysTool",
|
|
"ListDirectoryTool",
|
|
"ListPowerBITool",
|
|
"ListSQLDatabaseTool",
|
|
"ListSparkSQLTool",
|
|
"MetaphorSearchResults",
|
|
"MoveFileTool",
|
|
"NasaAction",
|
|
"NavigateBackTool",
|
|
"NavigateTool",
|
|
"O365CreateDraftMessage",
|
|
"O365SearchEmails",
|
|
"O365SearchEvents",
|
|
"O365SendEvent",
|
|
"O365SendMessage",
|
|
"OpenAPISpec",
|
|
"OpenWeatherMapQueryRun",
|
|
"PubmedQueryRun",
|
|
"PolygonAggregates",
|
|
"PolygonFinancials",
|
|
"PolygonLastQuote",
|
|
"PolygonTickerNews",
|
|
"RedditSearchRun",
|
|
"RedditSearchSchema",
|
|
"QueryCheckerTool",
|
|
"QueryPowerBITool",
|
|
"QuerySQLCheckerTool",
|
|
"QuerySQLDataBaseTool",
|
|
"QuerySparkSQLTool",
|
|
"ReadFileTool",
|
|
"RequestsDeleteTool",
|
|
"RequestsGetTool",
|
|
"RequestsPatchTool",
|
|
"RequestsPostTool",
|
|
"RequestsPutTool",
|
|
"SceneXplainTool",
|
|
"SearchAPIRun",
|
|
"SearchAPIResults",
|
|
"SearxSearchResults",
|
|
"SearxSearchRun",
|
|
"ShellTool",
|
|
"SlackGetChannel",
|
|
"SlackGetMessage",
|
|
"SlackScheduleMessage",
|
|
"SlackSendMessage",
|
|
"SleepTool",
|
|
"StackExchangeTool",
|
|
"StdInInquireTool",
|
|
"SteamWebAPIQueryRun",
|
|
"SteamshipImageGenerationTool",
|
|
"StructuredTool",
|
|
"Tool",
|
|
"VectorStoreQATool",
|
|
"VectorStoreQAWithSourcesTool",
|
|
"WikipediaQueryRun",
|
|
"WolframAlphaQueryRun",
|
|
"WriteFileTool",
|
|
"YahooFinanceNewsTool",
|
|
"YouSearchTool",
|
|
"YouTubeSearchTool",
|
|
"ZapierNLAListActions",
|
|
"ZapierNLARunAction",
|
|
"authenticate",
|
|
"format_tool_to_openai_function",
|
|
"tool",
|
|
"MerriamWebsterQueryRun",
|
|
]
|
|
|
|
|
|
def test_all_imports() -> None:
|
|
assert set(__all__) == set(EXPECTED_ALL)
|
|
assert set(__all__) == set(_module_lookup.keys())
|