mirror of
https://github.com/hwchase17/langchain
synced 2024-11-08 07:10:35 +00:00
88a3a56c1a
# Add Spark SQL support * Add Spark SQL support. It can connect to Spark via building a local/remote SparkSession. * Include a notebook example I tried some complicated queries (window function, table joins), and the tool works well. Compared to the [Spark Dataframe agent](https://python.langchain.com/en/latest/modules/agents/toolkits/examples/spark.html), this tool is able to generate queries across multiple tables. --------- # Your PR Title (What it does) <!-- Thank you for contributing to LangChain! Your PR will appear in our next release under the title you set. Please make sure it highlights your valuable contribution. Replace this with a description of the change, the issue it fixes (if applicable), and relevant context. List any dependencies required for this change. After you're done, someone will review your PR. They may suggest improvements. If no one reviews your PR within a few days, feel free to @-mention the same people again, as notifications can get lost. --> <!-- Remove if not applicable --> Fixes # (issue) ## Before submitting <!-- If you're adding a new integration, include an integration test and an example notebook showing its use! --> ## Who can review? Community members can review the PR once tests pass. Tag maintainers/contributors who might be interested: <!-- For a quicker response, figure out the right person to tag with @ @hwchase17 - project lead Tracing / Callbacks - @agola11 Async - @agola11 DataLoaders - @eyurtsev Models - @hwchase17 - @agola11 Agents / Tools / Toolkits - @vowelparrot VectorStores / Retrievers / Memory - @dev2049 --> --------- Co-authored-by: Gengliang Wang <gengliang@apache.org> Co-authored-by: Mike W <62768671+skcoirz@users.noreply.github.com> Co-authored-by: Eugene Yurtsev <eyurtsev@gmail.com> Co-authored-by: UmerHA <40663591+UmerHA@users.noreply.github.com> Co-authored-by: 张城铭 <z@hyperf.io> Co-authored-by: assert <zhangchengming@kkguan.com> Co-authored-by: blob42 <spike@w530> Co-authored-by: Yuekai Zhang <zhangyuekai@foxmail.com> Co-authored-by: Richard He <he.yucheng@outlook.com> Co-authored-by: Dev 2049 <dev.dev2049@gmail.com> Co-authored-by: Leonid Ganeline <leo.gan.57@gmail.com> Co-authored-by: Alexey Nominas <60900649+Chae4ek@users.noreply.github.com> Co-authored-by: elBarkey <elbarkey@gmail.com> Co-authored-by: Davis Chase <130488702+dev2049@users.noreply.github.com> Co-authored-by: Jeffrey D <1289344+verygoodsoftwarenotvirus@users.noreply.github.com> Co-authored-by: so2liu <yangliu35@outlook.com> Co-authored-by: Viswanadh Rayavarapu <44315599+vishwa-rn@users.noreply.github.com> Co-authored-by: Chakib Ben Ziane <contact@blob42.xyz> Co-authored-by: Daniel Chalef <131175+danielchalef@users.noreply.github.com> Co-authored-by: Daniel Chalef <daniel.chalef@private.org> Co-authored-by: Jari Bakken <jari.bakken@gmail.com> Co-authored-by: escafati <scafatieugenio@gmail.com>
43 lines
1.0 KiB
Python
43 lines
1.0 KiB
Python
from langchain.agents import __all__ as agents_all
|
|
|
|
_EXPECTED = [
|
|
"Agent",
|
|
"AgentExecutor",
|
|
"AgentOutputParser",
|
|
"AgentType",
|
|
"BaseMultiActionAgent",
|
|
"BaseSingleActionAgent",
|
|
"ConversationalAgent",
|
|
"ConversationalChatAgent",
|
|
"LLMSingleActionAgent",
|
|
"MRKLChain",
|
|
"ReActChain",
|
|
"ReActTextWorldAgent",
|
|
"SelfAskWithSearchChain",
|
|
"StructuredChatAgent",
|
|
"Tool",
|
|
"ZeroShotAgent",
|
|
"create_csv_agent",
|
|
"create_json_agent",
|
|
"create_openapi_agent",
|
|
"create_pandas_dataframe_agent",
|
|
"create_pbi_agent",
|
|
"create_pbi_chat_agent",
|
|
"create_spark_dataframe_agent",
|
|
"create_spark_sql_agent",
|
|
"create_sql_agent",
|
|
"create_vectorstore_agent",
|
|
"create_vectorstore_router_agent",
|
|
"get_all_tool_names",
|
|
"initialize_agent",
|
|
"load_agent",
|
|
"load_huggingface_tool",
|
|
"load_tools",
|
|
"tool",
|
|
]
|
|
|
|
|
|
def test_public_api() -> None:
|
|
"""Test for regressions or changes in the agents public API."""
|
|
assert sorted(agents_all) == sorted(_EXPECTED)
|