Skip to content

Commit 20ae6bb

Browse files
committed
Update links
1 parent 36f8b7c commit 20ae6bb

File tree

17 files changed

+91
-21
lines changed

17 files changed

+91
-21
lines changed

text_2_sql/autogen/Iteration 5 - Agentic Vector Based Text2SQL.ipynb

Lines changed: 32 additions & 13 deletions
Large diffs are not rendered by default.

text_2_sql/autogen/pyproject.toml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,12 @@ dependencies = [
1010
"autogen-ext[azure,openai]==0.4.0.dev7",
1111
"grpcio>=1.68.1",
1212
"pyyaml>=6.0.2",
13+
"text-2-sql-core",
1314
]
1415

1516
[dependency-groups]
1617
dev = [
18+
"autogen-text-2-sql",
1719
"black>=24.10.0",
1820
"ipykernel>=6.29.5",
1921
"jupyter>=1.1.1",
@@ -24,4 +26,5 @@ dev = [
2426
]
2527

2628
[tool.uv.sources]
27-
text_2_sql_core = { path = "text_2_sql/text_2_sql_core" }
29+
autogen-text-2-sql = { workspace = true }
30+
text-2-sql-core = { workspace = true }

text_2_sql/autogen/__init__.py renamed to text_2_sql/autogen/src/autogen_text_2_sql/__init__.py

File renamed without changes.

text_2_sql/autogen/src/autogen/autogen_text_2_sql.py renamed to text_2_sql/autogen/src/autogen_text_2_sql/autogen_text_2_sql.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22
# Licensed under the MIT License.
33
from autogen_agentchat.task import TextMentionTermination, MaxMessageTermination
44
from autogen_agentchat.teams import SelectorGroupChat
5-
from creators.llm_model_creator import LLMModelCreator
6-
from creators.llm_agent_creator import LLMAgentCreator
5+
from autogen_text_2_sql.creators.llm_model_creator import LLMModelCreator
6+
from autogen_text_2_sql.creators.llm_agent_creator import LLMAgentCreator
77
import logging
8-
from custom_agents.sql_query_cache_agent import SqlQueryCacheAgent
8+
from autogen_text_2_sql.custom_agents.sql_query_cache_agent import SqlQueryCacheAgent
99
import json
1010
import os
1111

text_2_sql/autogen/src/autogen/creators/llm_agent_creator.py renamed to text_2_sql/autogen/src/autogen_text_2_sql/creators/llm_agent_creator.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import yaml
44
from autogen_core.components.tools import FunctionTool
55
from autogen_agentchat.agents import AssistantAgent
6-
from ..text_2_sql_core.connectors.sql import SqlConnector
6+
from text_2_sql_core.connectors.sql import SqlConnector
77
from llm_model_creator import LLMModelCreator
88
from jinja2 import Template
99
from datetime import datetime

text_2_sql/autogen/src/autogen/creators/llm_model_creator.py renamed to text_2_sql/autogen/src/autogen_text_2_sql/creators/llm_model_creator.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Copyright (c) Microsoft Corporation.
22
# Licensed under the MIT License.
33
from autogen_ext.models import AzureOpenAIChatCompletionClient
4-
from ..text_2_sql_core.utils.environment import IdentityType, get_identity_type
4+
from text_2_sql_core.utils.environment import IdentityType, get_identity_type
55

66
from azure.identity import DefaultAzureCredential, get_bearer_token_provider
77
import os

text_2_sql/autogen/src/autogen/__init__.py renamed to text_2_sql/autogen/src/autogen_text_2_sql/custom_agents/__init__.py

File renamed without changes.

text_2_sql/autogen/src/autogen/custom_agents/sql_query_cache_agent.py renamed to text_2_sql/autogen/src/autogen_text_2_sql/custom_agents/sql_query_cache_agent.py

File renamed without changes.

text_2_sql/semantic_kernel/Iteration 2 - Prompt Based Text2SQL.ipynb

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,29 @@
1717
"\n",
1818
"This notebook demonstrates how the SQL plugin can be integrated with Semantic Kernel and Azure OpenAI to answer questions from the database based on the schemas provided. \n",
1919
"\n",
20-
"A multi-shot approach is used for SQL generation for more reliable results and reduced token usage. More details can be found in the README.md."
20+
"A multi-shot approach is used for SQL generation for more reliable results and reduced token usage. More details can be found in the README.md.\n",
21+
"\n",
22+
"### Dependencies\n",
23+
"\n",
24+
"To install dependencies:\n",
25+
"\n",
26+
"`uv sync --package semantic_kernel_text_2_sql`\n",
27+
"\n",
28+
"`uv add --editable ../text_2_sql_core/`"
29+
]
30+
},
31+
{
32+
"cell_type": "code",
33+
"execution_count": null,
34+
"metadata": {},
35+
"outputs": [],
36+
"source": [
37+
"# This is only needed for this notebook to work\n",
38+
"import sys\n",
39+
"from pathlib import Path\n",
40+
"\n",
41+
"# Add the parent directory of `src` to the path\n",
42+
"sys.path.append(str(Path.cwd() / \"src\"))"
2143
]
2244
},
2345
{

text_2_sql/semantic_kernel/Iterations 3 & 4 - Vector Based Text2SQL.ipynb

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,29 @@
1717
"\n",
1818
"This notebook demonstrates how the SQL plugin can be integrated with Semantic Kernel and Azure OpenAI to answer questions from the database based on the schemas provided. \n",
1919
"\n",
20-
"A multi-shot approach is used for SQL generation for more reliable results and reduced token usage. More details can be found in the README.md."
20+
"A multi-shot approach is used for SQL generation for more reliable results and reduced token usage. More details can be found in the README.md.\n",
21+
"\n",
22+
"### Dependencies\n",
23+
"\n",
24+
"To install dependencies:\n",
25+
"\n",
26+
"`uv sync --package semantic_kernel_text_2_sql`\n",
27+
"\n",
28+
"`uv add --editable ../text_2_sql_core/`"
29+
]
30+
},
31+
{
32+
"cell_type": "code",
33+
"execution_count": null,
34+
"metadata": {},
35+
"outputs": [],
36+
"source": [
37+
"# This is only needed for this notebook to work\n",
38+
"import sys\n",
39+
"from pathlib import Path\n",
40+
"\n",
41+
"# Add the parent directory of `src` to the path\n",
42+
"sys.path.append(str(Path.cwd() / \"src\"))"
2143
]
2244
},
2345
{

0 commit comments

Comments
 (0)