drift-ml 0.2.2__tar.gz → 0.2.5__tar.gz
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.
- {drift_ml-0.2.2/drift_ml.egg-info → drift_ml-0.2.5}/PKG-INFO +1 -1
- {drift_ml-0.2.2 → drift_ml-0.2.5}/drift/__main__.py +4 -1
- {drift_ml-0.2.2 → drift_ml-0.2.5}/drift/engine_launcher.py +29 -4
- {drift_ml-0.2.2 → drift_ml-0.2.5/drift_ml.egg-info}/PKG-INFO +1 -1
- {drift_ml-0.2.2 → drift_ml-0.2.5}/pyproject.toml +1 -1
- {drift_ml-0.2.2 → drift_ml-0.2.5}/LICENSE +0 -0
- {drift_ml-0.2.2 → drift_ml-0.2.5}/README.md +0 -0
- {drift_ml-0.2.2 → drift_ml-0.2.5}/drift/__init__.py +0 -0
- {drift_ml-0.2.2 → drift_ml-0.2.5}/drift/cli/__init__.py +0 -0
- {drift_ml-0.2.2 → drift_ml-0.2.5}/drift/cli/client.py +0 -0
- {drift_ml-0.2.2 → drift_ml-0.2.5}/drift/cli/repl.py +0 -0
- {drift_ml-0.2.2 → drift_ml-0.2.5}/drift/cli/session.py +0 -0
- {drift_ml-0.2.2 → drift_ml-0.2.5}/drift/llm_adapters/__init__.py +0 -0
- {drift_ml-0.2.2 → drift_ml-0.2.5}/drift/llm_adapters/base.py +0 -0
- {drift_ml-0.2.2 → drift_ml-0.2.5}/drift/llm_adapters/gemini_cli.py +0 -0
- {drift_ml-0.2.2 → drift_ml-0.2.5}/drift/llm_adapters/local_llm.py +0 -0
- {drift_ml-0.2.2 → drift_ml-0.2.5}/drift_ml.egg-info/SOURCES.txt +0 -0
- {drift_ml-0.2.2 → drift_ml-0.2.5}/drift_ml.egg-info/dependency_links.txt +0 -0
- {drift_ml-0.2.2 → drift_ml-0.2.5}/drift_ml.egg-info/entry_points.txt +0 -0
- {drift_ml-0.2.2 → drift_ml-0.2.5}/drift_ml.egg-info/requires.txt +0 -0
- {drift_ml-0.2.2 → drift_ml-0.2.5}/drift_ml.egg-info/top_level.txt +0 -0
- {drift_ml-0.2.2 → drift_ml-0.2.5}/setup.cfg +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: drift-ml
|
|
3
|
-
Version: 0.2.
|
|
3
|
+
Version: 0.2.5
|
|
4
4
|
Summary: drift — terminal-first, chat-based AutoML. Open source. No tokens. No auth.
|
|
5
5
|
Project-URL: Homepage, https://github.com/lakshitsachdeva/intent2model
|
|
6
6
|
Project-URL: Repository, https://github.com/lakshitsachdeva/intent2model
|
|
@@ -19,7 +19,10 @@ def main() -> None:
|
|
|
19
19
|
from drift.engine_launcher import ensure_engine
|
|
20
20
|
|
|
21
21
|
if not ensure_engine():
|
|
22
|
-
print("drift: Failed to start engine.
|
|
22
|
+
print("drift: Failed to start engine.", file=sys.stderr)
|
|
23
|
+
print("drift: Check ~/.drift/bin/.engine-stderr.log", file=sys.stderr)
|
|
24
|
+
print("drift: On macOS: System Settings → Privacy & Security → allow drift-engine", file=sys.stderr)
|
|
25
|
+
print("drift: Or set DRIFT_BACKEND_URL to a running engine", file=sys.stderr)
|
|
23
26
|
sys.exit(1)
|
|
24
27
|
base_url = f"http://127.0.0.1:{os.environ.get('DRIFT_ENGINE_PORT', '8000')}"
|
|
25
28
|
run_repl(base_url=base_url)
|
|
@@ -15,8 +15,8 @@ try:
|
|
|
15
15
|
except ImportError:
|
|
16
16
|
requests = None
|
|
17
17
|
|
|
18
|
-
GITHUB_REPO = "lakshitsachdeva/
|
|
19
|
-
ENGINE_TAG = "v0.2.
|
|
18
|
+
GITHUB_REPO = "lakshitsachdeva/intent2model" # Engine binaries (same repo)
|
|
19
|
+
ENGINE_TAG = "v0.2.5" # Pinned — direct URL, no API, no rate limits
|
|
20
20
|
ENGINE_PORT = os.environ.get("DRIFT_ENGINE_PORT", "8000")
|
|
21
21
|
HEALTH_URL = f"http://127.0.0.1:{ENGINE_PORT}/health"
|
|
22
22
|
|
|
@@ -143,16 +143,40 @@ def ensure_engine() -> bool:
|
|
|
143
143
|
try:
|
|
144
144
|
bin_path.chmod(0o755)
|
|
145
145
|
subprocess.run(["xattr", "-dr", "com.apple.quarantine", str(bin_path)], check=False, capture_output=True)
|
|
146
|
+
# Ad-hoc sign so macOS Gatekeeper doesn't kill the binary (requires non-UPX build)
|
|
147
|
+
subprocess.run(["codesign", "-s", "-", "--force", str(bin_path)], check=False, capture_output=True)
|
|
146
148
|
except Exception:
|
|
147
149
|
pass
|
|
148
150
|
|
|
151
|
+
# macOS: use wrapper script via bash to avoid spawn -88
|
|
152
|
+
# Windows: use batch file so engine starts reliably (inherits PATH for gemini etc.)
|
|
153
|
+
if platform.system() == "Darwin":
|
|
154
|
+
wrapper = bin_dir / "run-engine.sh"
|
|
155
|
+
port = ENGINE_PORT
|
|
156
|
+
bin_name = bin_path.name
|
|
157
|
+
script = f'#!/bin/bash\ncd "$(dirname "$0")"\nexport DRIFT_ENGINE_PORT="{port}"\nexec ./{bin_name}\n'
|
|
158
|
+
if not wrapper.exists() or wrapper.read_text() != script:
|
|
159
|
+
wrapper.write_text(script)
|
|
160
|
+
wrapper.chmod(0o755)
|
|
161
|
+
launch_cmd = ["/bin/bash", str(wrapper)]
|
|
162
|
+
elif platform.system() == "Windows":
|
|
163
|
+
bat = bin_dir / "run-engine.bat"
|
|
164
|
+
port = ENGINE_PORT
|
|
165
|
+
bin_name = bin_path.name
|
|
166
|
+
script = f'@echo off\ncd /d "%~dp0"\nset DRIFT_ENGINE_PORT={port}\nstart /b "" {bin_name}\n'
|
|
167
|
+
if not bat.exists() or bat.read_text() != script:
|
|
168
|
+
bat.write_text(script)
|
|
169
|
+
launch_cmd = ["cmd", "/c", str(bat)]
|
|
170
|
+
else:
|
|
171
|
+
launch_cmd = [str(bin_path)]
|
|
172
|
+
|
|
149
173
|
env = {**os.environ, "DRIFT_ENGINE_PORT": ENGINE_PORT}
|
|
150
174
|
stderr_file = bin_dir / ".engine-stderr.log"
|
|
151
175
|
proc = None
|
|
152
176
|
try:
|
|
153
177
|
with open(stderr_file, "w") as errf:
|
|
154
178
|
proc = subprocess.Popen(
|
|
155
|
-
|
|
179
|
+
launch_cmd,
|
|
156
180
|
cwd=str(bin_dir),
|
|
157
181
|
env=env,
|
|
158
182
|
stdout=subprocess.DEVNULL,
|
|
@@ -174,7 +198,8 @@ def ensure_engine() -> bool:
|
|
|
174
198
|
return False
|
|
175
199
|
|
|
176
200
|
import time
|
|
177
|
-
|
|
201
|
+
print("drift: Starting engine (first run may take 30s)...", file=sys.stderr)
|
|
202
|
+
for i in range(120): # 60s — PyInstaller binary can take 30+ s to unpack
|
|
178
203
|
if _engine_running():
|
|
179
204
|
return True
|
|
180
205
|
time.sleep(0.5)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: drift-ml
|
|
3
|
-
Version: 0.2.
|
|
3
|
+
Version: 0.2.5
|
|
4
4
|
Summary: drift — terminal-first, chat-based AutoML. Open source. No tokens. No auth.
|
|
5
5
|
Project-URL: Homepage, https://github.com/lakshitsachdeva/intent2model
|
|
6
6
|
Project-URL: Repository, https://github.com/lakshitsachdeva/intent2model
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|