reasoning-deployment-service 0.3.3__py3-none-any.whl → 0.3.4__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- reasoning_deployment_service/runner.py +43 -60
- {reasoning_deployment_service-0.3.3.dist-info → reasoning_deployment_service-0.3.4.dist-info}/METADATA +5 -7
- {reasoning_deployment_service-0.3.3.dist-info → reasoning_deployment_service-0.3.4.dist-info}/RECORD +6 -8
- reasoning_deployment_service/gui_editor/requirements_minimal.txt +0 -54
- reasoning_deployment_service/gui_editor/run_program.sh +0 -55
- {reasoning_deployment_service-0.3.3.dist-info → reasoning_deployment_service-0.3.4.dist-info}/WHEEL +0 -0
- {reasoning_deployment_service-0.3.3.dist-info → reasoning_deployment_service-0.3.4.dist-info}/entry_points.txt +0 -0
- {reasoning_deployment_service-0.3.3.dist-info → reasoning_deployment_service-0.3.4.dist-info}/top_level.txt +0 -0
|
@@ -1,13 +1,7 @@
|
|
|
1
|
-
import os
|
|
2
1
|
import sys
|
|
3
|
-
import subprocess
|
|
4
|
-
from pathlib import Path
|
|
5
|
-
from dotenv import load_dotenv
|
|
6
2
|
import argparse
|
|
7
|
-
|
|
8
|
-
from reasoning_deployment_service import
|
|
9
|
-
ReasoningEngineDeploymentService,
|
|
10
|
-
)
|
|
3
|
+
from pathlib import Path
|
|
4
|
+
from reasoning_deployment_service import ReasoningEngineDeploymentService
|
|
11
5
|
from reasoning_deployment_service.gui_editor import GUIEditor
|
|
12
6
|
from reasoning_deployment_service.cli_editor import CLIRunner
|
|
13
7
|
|
|
@@ -19,40 +13,35 @@ class Runner:
|
|
|
19
13
|
parser.add_argument(
|
|
20
14
|
"--mode",
|
|
21
15
|
choices=["create", "auth", "cli", "gui", "populate_files"],
|
|
22
|
-
required=False,
|
|
23
16
|
help="Operation mode to run",
|
|
24
17
|
)
|
|
18
|
+
parser.add_argument(
|
|
19
|
+
"--agent-path",
|
|
20
|
+
help="Dotted path to your agent (e.g. Invoice_agent.agent:root_agent). "
|
|
21
|
+
"If omitted, falls back to your_agent_import.py in project root."
|
|
22
|
+
)
|
|
25
23
|
args = parser.parse_args()
|
|
26
24
|
|
|
27
|
-
# --- Ensure .gitignore covers junk ---
|
|
28
25
|
Runner._ensure_gitignore()
|
|
29
26
|
|
|
30
|
-
# ---
|
|
31
|
-
|
|
32
|
-
Runner._create_agent_import()
|
|
33
|
-
|
|
34
|
-
# --- Always ensure venv exists & is up to date ---
|
|
35
|
-
venv_python = Runner._ensure_venv()
|
|
36
|
-
|
|
37
|
-
# --- Install dependencies into venv ---
|
|
38
|
-
Runner._install_deps(venv_python)
|
|
27
|
+
# --- Load root_agent dynamically ---
|
|
28
|
+
root_agent = Runner._load_agent(args.agent_path)
|
|
39
29
|
|
|
40
|
-
# ---
|
|
30
|
+
# --- Check env config ---
|
|
41
31
|
if not Path(".env.agent").exists() or not Path("aix_agent.yaml").exists():
|
|
42
32
|
print("Missing .env.agent or aix_agent.yaml.")
|
|
43
33
|
print("Options:\n 5) Generate placeholder config\n q) Quit")
|
|
44
34
|
choice = input("Enter choice: ").strip()
|
|
45
35
|
if choice == "5":
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
return
|
|
36
|
+
svc = ReasoningEngineDeploymentService(root_agent, deployment_environment="DEV")
|
|
37
|
+
svc._check_required_files_exist()
|
|
38
|
+
sys.exit(0)
|
|
50
39
|
|
|
51
|
-
# ---
|
|
40
|
+
# --- Run mode or menu ---
|
|
52
41
|
if args.mode:
|
|
53
|
-
Runner._dispatch(args.mode,
|
|
42
|
+
Runner._dispatch(args.mode, root_agent)
|
|
54
43
|
else:
|
|
55
|
-
Runner._menu(
|
|
44
|
+
Runner._menu(root_agent)
|
|
56
45
|
|
|
57
46
|
# ------------------ HELPERS ------------------
|
|
58
47
|
|
|
@@ -61,44 +50,38 @@ class Runner:
|
|
|
61
50
|
gi = Path(".gitignore")
|
|
62
51
|
if not gi.exists():
|
|
63
52
|
gi.write_text("# Generated by Runner\n")
|
|
64
|
-
patterns = [
|
|
53
|
+
patterns = [
|
|
54
|
+
".venv", ".venv_deploy", "venv", "__pycache__",
|
|
55
|
+
"deploy_env", "your_agent_import.py"
|
|
56
|
+
]
|
|
65
57
|
content = gi.read_text().splitlines()
|
|
66
58
|
for p in patterns:
|
|
67
59
|
if p not in content:
|
|
68
|
-
|
|
69
|
-
f.write(f"{p}\n")
|
|
70
|
-
|
|
71
|
-
@staticmethod
|
|
72
|
-
def _create_agent_import():
|
|
73
|
-
agent_dir = input("Enter the directory where your root_agent (agent.py) lives: ").strip()
|
|
74
|
-
if not Path(agent_dir, "agent.py").exists():
|
|
75
|
-
print(f"Error: {agent_dir}/agent.py not found")
|
|
76
|
-
sys.exit(1)
|
|
77
|
-
import_path = agent_dir.replace("/", ".") + ".agent"
|
|
78
|
-
Path("your_agent_import.py").write_text(f"from {import_path} import root_agent\n")
|
|
79
|
-
print(f"Created your_agent_import.py pointing to {agent_dir}/agent.py")
|
|
60
|
+
gi.write_text(gi.read_text() + f"\n{p}\n")
|
|
80
61
|
|
|
81
62
|
@staticmethod
|
|
82
|
-
def
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
63
|
+
def _load_agent(agent_path_arg: str):
|
|
64
|
+
"""Load root_agent either from --agent-path or your_agent_import.py."""
|
|
65
|
+
sys.path.insert(0, str(Path.cwd())) # ensure project root on sys.path
|
|
66
|
+
|
|
67
|
+
if agent_path_arg:
|
|
68
|
+
import importlib
|
|
69
|
+
if ":" in agent_path_arg:
|
|
70
|
+
module_path, attr = agent_path_arg.split(":")
|
|
71
|
+
else:
|
|
72
|
+
module_path, attr = agent_path_arg, "root_agent"
|
|
73
|
+
module = importlib.import_module(module_path)
|
|
74
|
+
return getattr(module, attr)
|
|
88
75
|
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
subprocess.check_call([venv_python, "-m", "pip", "install", "keyring", "keyrings.google-artifactregistry-auth"])
|
|
93
|
-
# Install reasoning-deployment-service itself (current package)
|
|
94
|
-
subprocess.check_call([venv_python, "-m", "pip", "install", "reasoning-deployment-service"])
|
|
76
|
+
if Path("your_agent_import.py").exists():
|
|
77
|
+
from your_agent_import import root_agent
|
|
78
|
+
return root_agent
|
|
95
79
|
|
|
96
|
-
|
|
97
|
-
|
|
80
|
+
print("Error: No agent path provided and your_agent_import.py not found.")
|
|
81
|
+
sys.exit(1)
|
|
98
82
|
|
|
99
83
|
@staticmethod
|
|
100
|
-
def _dispatch(mode,
|
|
101
|
-
from your_agent_import import root_agent
|
|
84
|
+
def _dispatch(mode, root_agent):
|
|
102
85
|
svc = ReasoningEngineDeploymentService(root_agent, deployment_environment="DEV")
|
|
103
86
|
|
|
104
87
|
if mode == "create":
|
|
@@ -113,10 +96,10 @@ class Runner:
|
|
|
113
96
|
svc._check_required_files_exist()
|
|
114
97
|
|
|
115
98
|
@staticmethod
|
|
116
|
-
def _menu(
|
|
99
|
+
def _menu(root_agent):
|
|
117
100
|
print("Choose an operation:\n1) Create/Update\n2) Auth only\n3) CLI\n4) GUI\nq) Quit")
|
|
118
|
-
choice = input("Enter choice: ").strip()
|
|
101
|
+
choice = input("Enter choice: ").strip().lower()
|
|
119
102
|
mapping = {"1": "create", "2": "auth", "3": "cli", "4": "gui"}
|
|
120
|
-
if choice
|
|
103
|
+
if choice == "q":
|
|
121
104
|
sys.exit(0)
|
|
122
|
-
Runner._dispatch(mapping.get(choice, ""),
|
|
105
|
+
Runner._dispatch(mapping.get(choice, ""), root_agent)
|
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: reasoning-deployment-service
|
|
3
|
-
Version: 0.3.
|
|
3
|
+
Version: 0.3.4
|
|
4
4
|
Summary: Deployment helper for Vertex AI Reasoning Engines & Agent Spaces
|
|
5
|
-
Author: AxG-AI-Exchange-GenAI-Initiative
|
|
6
5
|
Author-email: Sergio Estrada <sergio.estrada@accenture.com>
|
|
7
6
|
License: Apache-2.0
|
|
8
7
|
Project-URL: Homepage, https://github.com/AxG-AI-Exchange-GenAI-Initiative/AIXAgentDeploymentService
|
|
9
8
|
Project-URL: Repository, https://github.com/AxG-AI-Exchange-GenAI-Initiative/AIXAgentDeploymentService
|
|
10
9
|
Project-URL: Issues, https://github.com/AxG-AI-Exchange-GenAI-Initiative/AIXAgentDeploymentService/issues
|
|
11
|
-
Requires-Python: >=3.
|
|
10
|
+
Requires-Python: >=3.9
|
|
12
11
|
Description-Content-Type: text/markdown
|
|
13
12
|
Requires-Dist: requests>=2.28
|
|
14
13
|
Requires-Dist: python-dotenv>=1.0
|
|
15
14
|
Requires-Dist: google-auth>=2.20
|
|
16
15
|
Requires-Dist: google-cloud-storage>=2.16
|
|
16
|
+
Requires-Dist: google-cloud-aiplatform[adk,agent-engines]>=1.88.0
|
|
17
|
+
Requires-Dist: protobuf<7.0.0,>=4.21
|
|
17
18
|
Requires-Dist: keyring>=24.0
|
|
18
19
|
Requires-Dist: keyrings.google-artifactregistry-auth>=1.1
|
|
19
|
-
Requires-Dist:
|
|
20
|
-
Requires-Dist: protobuf<7.0.0,>=4.21
|
|
20
|
+
Requires-Dist: PyYAML>=6.0
|
|
21
21
|
Requires-Dist: click>=8.0
|
|
22
22
|
Provides-Extra: dev
|
|
23
23
|
Requires-Dist: pytest; extra == "dev"
|
|
@@ -25,8 +25,6 @@ Requires-Dist: build; extra == "dev"
|
|
|
25
25
|
Requires-Dist: twine; extra == "dev"
|
|
26
26
|
Requires-Dist: black; extra == "dev"
|
|
27
27
|
Requires-Dist: ruff; extra == "dev"
|
|
28
|
-
Dynamic: author
|
|
29
|
-
Dynamic: requires-python
|
|
30
28
|
|
|
31
29
|
# Reasoning Deployment Service
|
|
32
30
|
|
{reasoning_deployment_service-0.3.3.dist-info → reasoning_deployment_service-0.3.4.dist-info}/RECORD
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
reasoning_deployment_service/__init__.py,sha256=xDuKt9gGviQiTV6vXBdkBvygnlAOIrwnUjVaMGZy0L4,670
|
|
2
2
|
reasoning_deployment_service/reasoning_deployment_service.py,sha256=0QHU2IqqojwFI2wPJ0izrskiHiwBfxdBEB9I_YxYbSA,29133
|
|
3
|
-
reasoning_deployment_service/runner.py,sha256=
|
|
3
|
+
reasoning_deployment_service/runner.py,sha256=Vv8LYj4E8TQ0vmXoQXpe4Sm0Og-C1OD6JSFd6i6JWkk,3874
|
|
4
4
|
reasoning_deployment_service/cli_editor/__init__.py,sha256=bN8NPkw8riB92pj2lAwJZuEMOQIO_RRuge0ehnJTW1I,118
|
|
5
5
|
reasoning_deployment_service/cli_editor/api_client.py,sha256=PUXPWUslFOksKMrcKjJSK_gVJkTI0bO_bqtCEYeM85g,27897
|
|
6
6
|
reasoning_deployment_service/cli_editor/cli_runner.py,sha256=w8jv2ep6TiYfpc_KnlvDOJ9hsCSuZcix4Rv4GQcZO4g,15729
|
|
@@ -9,8 +9,6 @@ reasoning_deployment_service/cli_editor/google_deps.py,sha256=PhGwdKEC96GdlFHkQr
|
|
|
9
9
|
reasoning_deployment_service/cli_editor/reasoning_engine_creator.py,sha256=6QC8Y9yZAT8SYNkT_R00g_SSOYuwEkIxAN9lBG3br2k,19564
|
|
10
10
|
reasoning_deployment_service/gui_editor/__init__.py,sha256=e5e88iNTk1GC243DRsQFi5E7PqMaT2SXmqOez9FbYzo,128
|
|
11
11
|
reasoning_deployment_service/gui_editor/main.py,sha256=4UzgGUga_xIYIWRVo-80PzhJ1Dlou8PaUXoRiLcLhp8,10914
|
|
12
|
-
reasoning_deployment_service/gui_editor/requirements_minimal.txt,sha256=tiv36KUcIx496Ewuh_FqXyhMhGOrtqsYfKEdn85XXYQ,1179
|
|
13
|
-
reasoning_deployment_service/gui_editor/run_program.sh,sha256=xfim6JJiDc7KtGckcVl_K732WtZYfvBogLfslYBXb0Q,1489
|
|
14
12
|
reasoning_deployment_service/gui_editor/src/__init__.py,sha256=q4YBECQGHtHV_TF4MyL36ElWe6tdVgmoNchN1lQU7z4,25
|
|
15
13
|
reasoning_deployment_service/gui_editor/src/core/__init__.py,sha256=kH-6PxUQ-uVn79ihXN3eLyv_oFhReVsVz-f-kEK_qUo,46
|
|
16
14
|
reasoning_deployment_service/gui_editor/src/core/api_client.py,sha256=rGyFKRyBY_MjRsnWxVI1IX1WAYTEfM1V5X3l1iR8GaI,26845
|
|
@@ -23,8 +21,8 @@ reasoning_deployment_service/gui_editor/src/ui/authorization_view.py,sha256=uiyN
|
|
|
23
21
|
reasoning_deployment_service/gui_editor/src/ui/reasoning_engine_view.py,sha256=tCvSPEf4dW0NRdAqfs3yT5Pa873gYeLzCMMIt2r2T4o,14644
|
|
24
22
|
reasoning_deployment_service/gui_editor/src/ui/reasoning_engines_view.py,sha256=IRjFlBbY98usAZa0roOonjvWQOsF6NBW4bBg_k8KnKI,7860
|
|
25
23
|
reasoning_deployment_service/gui_editor/src/ui/ui_components.py,sha256=HdQHy-oSZ3GobQ3FNdH7y_w3ANbFiuf2rMoflAmff0A,55366
|
|
26
|
-
reasoning_deployment_service-0.3.
|
|
27
|
-
reasoning_deployment_service-0.3.
|
|
28
|
-
reasoning_deployment_service-0.3.
|
|
29
|
-
reasoning_deployment_service-0.3.
|
|
30
|
-
reasoning_deployment_service-0.3.
|
|
24
|
+
reasoning_deployment_service-0.3.4.dist-info/METADATA,sha256=SGmPBaX-F-ReutdQgR8vi4fdLKjI9W-r6O2nDrQpTbU,4991
|
|
25
|
+
reasoning_deployment_service-0.3.4.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
26
|
+
reasoning_deployment_service-0.3.4.dist-info/entry_points.txt,sha256=onGKjR5ONTtRv3aqEtK863iw9Ty1kLcjfZlsplkRZrA,84
|
|
27
|
+
reasoning_deployment_service-0.3.4.dist-info/top_level.txt,sha256=GKuQS1xHUYLZbatw9DmcYdBxxLhWhhGkV4FmFxgKdp0,29
|
|
28
|
+
reasoning_deployment_service-0.3.4.dist-info/RECORD,,
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
# Bare minimum requirements for Agent Space Deployment Service
|
|
2
|
-
# Core functionality dependencies only
|
|
3
|
-
|
|
4
|
-
# Google Cloud & Vertex AI (CORE REQUIREMENT)
|
|
5
|
-
google-cloud-aiplatform==1.108.0
|
|
6
|
-
vertexai==1.43.0
|
|
7
|
-
google-auth==2.40.3
|
|
8
|
-
google-auth-oauthlib==1.2.2
|
|
9
|
-
google-api-python-client==2.178.0
|
|
10
|
-
|
|
11
|
-
# Environment management (CORE REQUIREMENT)
|
|
12
|
-
python-dotenv==1.1.1
|
|
13
|
-
|
|
14
|
-
# HTTP requests (CORE REQUIREMENT)
|
|
15
|
-
requests==2.32.4
|
|
16
|
-
|
|
17
|
-
# Google Cloud dependencies (CORE REQUIREMENT)
|
|
18
|
-
google-api-core==2.25.1
|
|
19
|
-
googleapis-common-protos==1.70.0
|
|
20
|
-
grpcio==1.74.0
|
|
21
|
-
protobuf==6.31.1
|
|
22
|
-
|
|
23
|
-
# Authentication dependencies (CORE REQUIREMENT)
|
|
24
|
-
google-auth-httplib2==0.2.0
|
|
25
|
-
cachetools==5.5.2
|
|
26
|
-
pyasn1==0.6.1
|
|
27
|
-
pyasn1_modules==0.4.2
|
|
28
|
-
rsa==4.9.1
|
|
29
|
-
|
|
30
|
-
# Core Python utilities (CORE REQUIREMENT)
|
|
31
|
-
certifi==2025.8.3
|
|
32
|
-
urllib3==2.5.0
|
|
33
|
-
six==1.17.0
|
|
34
|
-
|
|
35
|
-
# OPTIONAL: For enhanced functionality
|
|
36
|
-
# Uncomment if you need these features:
|
|
37
|
-
|
|
38
|
-
# For MCP server support:
|
|
39
|
-
# mcp==1.12.4
|
|
40
|
-
|
|
41
|
-
# For FastAPI endpoints (if you plan to add web interface):
|
|
42
|
-
# fastapi==0.116.1
|
|
43
|
-
# uvicorn==0.35.0
|
|
44
|
-
# pydantic==2.11.7
|
|
45
|
-
|
|
46
|
-
# For document processing in agents:
|
|
47
|
-
# PyPDF2==3.0.1
|
|
48
|
-
# python-docx==1.2.0
|
|
49
|
-
|
|
50
|
-
# For web scraping/HTTP in agents:
|
|
51
|
-
# httpx==0.28.1
|
|
52
|
-
|
|
53
|
-
# For YAML configuration:
|
|
54
|
-
# PyYAML==6.0.2
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env bash
|
|
2
|
-
set -e
|
|
3
|
-
|
|
4
|
-
VENV_DIR=".venv"
|
|
5
|
-
|
|
6
|
-
# Detect Python executable
|
|
7
|
-
if command -v python3 &>/dev/null; then
|
|
8
|
-
PYTHON=python3
|
|
9
|
-
elif command -v python &>/dev/null; then
|
|
10
|
-
PYTHON=python
|
|
11
|
-
else
|
|
12
|
-
echo "❌ Python is not installed. Please install Python 3.9+."
|
|
13
|
-
exit 1
|
|
14
|
-
fi
|
|
15
|
-
|
|
16
|
-
# Create venv if missing
|
|
17
|
-
if [ ! -d "$VENV_DIR" ]; then
|
|
18
|
-
echo "🔧 Creating virtual environment..."
|
|
19
|
-
$PYTHON -m venv "$VENV_DIR"
|
|
20
|
-
fi
|
|
21
|
-
|
|
22
|
-
# Activate venv (POSIX)
|
|
23
|
-
if [ -f "$VENV_DIR/bin/activate" ]; then
|
|
24
|
-
source "$VENV_DIR/bin/activate"
|
|
25
|
-
# Activate venv (Windows Git Bash or Cygwin)
|
|
26
|
-
elif [ -f "$VENV_DIR/Scripts/activate" ]; then
|
|
27
|
-
source "$VENV_DIR/Scripts/activate"
|
|
28
|
-
else
|
|
29
|
-
echo "❌ Could not find venv activation script."
|
|
30
|
-
exit 1
|
|
31
|
-
fi
|
|
32
|
-
|
|
33
|
-
# Install Tkinter if on Linux
|
|
34
|
-
if [[ "$OSTYPE" == "linux-gnu"* ]]; then
|
|
35
|
-
echo "🖼 Installing Tkinter for Linux..."
|
|
36
|
-
if command -v apt-get &>/dev/null; then
|
|
37
|
-
sudo apt-get update && sudo apt-get install -y python3-tk
|
|
38
|
-
elif command -v dnf &>/dev/null; then
|
|
39
|
-
sudo dnf install -y python3-tkinter
|
|
40
|
-
elif command -v pacman &>/dev/null; then
|
|
41
|
-
sudo pacman -S --noconfirm tk
|
|
42
|
-
else
|
|
43
|
-
echo "⚠️ Could not determine package manager. Install python3-tk manually."
|
|
44
|
-
fi
|
|
45
|
-
fi
|
|
46
|
-
|
|
47
|
-
# Install dependencies
|
|
48
|
-
echo "📦 Installing dependencies..."
|
|
49
|
-
pip3 install --upgrade pip
|
|
50
|
-
# Install the reasoning deployment service with GUI extras
|
|
51
|
-
pip3 install "reasoning-deployment-service[gui]"
|
|
52
|
-
|
|
53
|
-
# Run your app
|
|
54
|
-
echo "🚀 Starting app..."
|
|
55
|
-
$PYTHON main.py
|
{reasoning_deployment_service-0.3.3.dist-info → reasoning_deployment_service-0.3.4.dist-info}/WHEEL
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|