ltcai 6.1.0 → 6.3.0
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.
- package/README.md +36 -38
- package/docs/CHANGELOG.md +75 -1
- package/frontend/src/App.tsx +3 -1286
- package/frontend/src/components/LanguageSwitcher.tsx +23 -0
- package/frontend/src/components/ProductFlow.tsx +32 -669
- package/frontend/src/components/onboarding/AnalysisScreen.tsx +127 -0
- package/frontend/src/components/onboarding/DownloadConsentPanel.tsx +29 -0
- package/frontend/src/components/onboarding/InstallScreen.tsx +208 -0
- package/frontend/src/components/onboarding/LanguageChooser.tsx +23 -0
- package/frontend/src/components/onboarding/LoginScreen.tsx +131 -0
- package/frontend/src/components/onboarding/ProductFlowScreens.tsx +13 -0
- package/frontend/src/components/onboarding/RecommendationScreen.tsx +59 -0
- package/frontend/src/components/onboarding/recommendationModel.ts +132 -0
- package/frontend/src/features/admin/AdminConsole.tsx +294 -0
- package/frontend/src/features/brain/BrainCarePanel.tsx +254 -0
- package/frontend/src/features/brain/BrainComposer.tsx +66 -0
- package/frontend/src/features/brain/BrainConversation.tsx +131 -0
- package/frontend/src/features/brain/BrainGraphLayer.tsx +132 -0
- package/frontend/src/features/brain/BrainHome.tsx +232 -0
- package/frontend/src/features/brain/BrainMemoryLayer.tsx +38 -0
- package/frontend/src/features/brain/BrainOverviewPanel.tsx +74 -0
- package/frontend/src/features/brain/BrainRelationshipLayer.tsx +43 -0
- package/frontend/src/features/brain/DepthEmergence.tsx +53 -0
- package/frontend/src/features/brain/brainData.ts +98 -0
- package/frontend/src/features/brain/graphLayout.ts +26 -0
- package/frontend/src/features/brain/types.ts +44 -0
- package/frontend/src/features/review/ReviewCard.tsx +3 -1
- package/frontend/src/features/review/ReviewInbox.tsx +11 -1
- package/frontend/src/i18n.ts +290 -0
- package/frontend/src/pages/Brain.tsx +63 -5
- package/frontend/src/pages/Capture.tsx +102 -13
- package/frontend/src/pages/Library.tsx +72 -6
- package/frontend/src/styles.css +220 -0
- package/lattice_brain/__init__.py +1 -1
- package/lattice_brain/runtime/multi_agent.py +1 -1
- package/latticeai/__init__.py +1 -1
- package/latticeai/api/tools.py +50 -23
- package/latticeai/app_factory.py +59 -76
- package/latticeai/cli/entrypoint.py +283 -0
- package/latticeai/core/marketplace.py +1 -1
- package/latticeai/core/workspace_os.py +1 -1
- package/latticeai/integrations/__init__.py +0 -0
- package/latticeai/integrations/telegram_bot.py +1009 -0
- package/latticeai/runtime/chat_wiring.py +119 -0
- package/latticeai/runtime/lifespan_runtime.py +1 -1
- package/latticeai/runtime/model_wiring.py +40 -0
- package/latticeai/runtime/platform_runtime_wiring.py +86 -0
- package/latticeai/runtime/review_wiring.py +37 -0
- package/latticeai/runtime/router_registration.py +49 -30
- package/latticeai/runtime/tail_wiring.py +21 -0
- package/latticeai/services/p_reinforce.py +258 -0
- package/latticeai/services/router_context.py +52 -0
- package/ltcai_cli.py +7 -279
- package/p_reinforce.py +4 -255
- package/package.json +3 -2
- package/scripts/check_i18n_literals.mjs +52 -0
- package/scripts/release_smoke.py +133 -0
- package/scripts/wheel_smoke.py +4 -0
- package/src-tauri/Cargo.lock +1 -1
- package/src-tauri/Cargo.toml +1 -1
- package/src-tauri/tauri.conf.json +1 -1
- package/static/app/asset-manifest.json +5 -5
- package/static/app/assets/index-D76dWuQk.js +16 -0
- package/static/app/assets/index-D76dWuQk.js.map +1 -0
- package/static/app/assets/index-Div5vMlq.css +2 -0
- package/static/app/index.html +2 -2
- package/telegram_bot.py +9 -1002
- package/static/app/assets/index-B744yblP.css +0 -2
- package/static/app/assets/index-DYaUKNfl.js +0 -16
- package/static/app/assets/index-DYaUKNfl.js.map +0 -1
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
"""Release smoke checks for exact-version release artifacts.
|
|
3
|
+
|
|
4
|
+
This complements ``validate_release_artifacts.py`` by opening the generated
|
|
5
|
+
artifacts and proving the installable surfaces are coherent:
|
|
6
|
+
|
|
7
|
+
- wheel installs/imports in a fresh environment via ``wheel_smoke.py``
|
|
8
|
+
- npm tgz contains the package metadata, CLI bin, and static assets
|
|
9
|
+
- static asset manifest points at files that exist on disk
|
|
10
|
+
- Tauri DMG/app bundle exists, and can optionally be launched briefly
|
|
11
|
+
"""
|
|
12
|
+
|
|
13
|
+
from __future__ import annotations
|
|
14
|
+
|
|
15
|
+
import argparse
|
|
16
|
+
import json
|
|
17
|
+
import os
|
|
18
|
+
import subprocess
|
|
19
|
+
import sys
|
|
20
|
+
import tarfile
|
|
21
|
+
import time
|
|
22
|
+
from pathlib import Path
|
|
23
|
+
|
|
24
|
+
REPO_ROOT = Path(__file__).resolve().parents[1]
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
def run(cmd: list[str], **kwargs) -> None:
|
|
28
|
+
print("+", " ".join(str(item) for item in cmd), flush=True)
|
|
29
|
+
subprocess.run(cmd, check=True, **kwargs)
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
def smoke_wheel(version: str, skip_health: bool) -> None:
|
|
33
|
+
wheel = REPO_ROOT / "dist" / f"ltcai-{version}-py3-none-any.whl"
|
|
34
|
+
if not wheel.is_file():
|
|
35
|
+
raise SystemExit(f"missing wheel: {wheel}")
|
|
36
|
+
cmd = [sys.executable, str(REPO_ROOT / "scripts" / "wheel_smoke.py"), "--wheel", str(wheel)]
|
|
37
|
+
if skip_health:
|
|
38
|
+
cmd.append("--skip-health")
|
|
39
|
+
run(cmd, cwd=REPO_ROOT)
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
def smoke_npm_tgz(version: str) -> None:
|
|
43
|
+
tgz = REPO_ROOT / f"ltcai-{version}.tgz"
|
|
44
|
+
if not tgz.is_file():
|
|
45
|
+
raise SystemExit(f"missing npm tgz: {tgz}")
|
|
46
|
+
required = {
|
|
47
|
+
"package/package.json",
|
|
48
|
+
"package/bin/ltcai.js",
|
|
49
|
+
"package/static/app/index.html",
|
|
50
|
+
"package/static/app/asset-manifest.json",
|
|
51
|
+
}
|
|
52
|
+
with tarfile.open(tgz, "r:gz") as archive:
|
|
53
|
+
names = set(archive.getnames())
|
|
54
|
+
missing = sorted(required - names)
|
|
55
|
+
if missing:
|
|
56
|
+
raise SystemExit(f"{tgz.name} missing entries: {missing}")
|
|
57
|
+
package_data = json.loads(archive.extractfile("package/package.json").read().decode("utf-8")) # type: ignore[union-attr]
|
|
58
|
+
if package_data.get("version") != version:
|
|
59
|
+
raise SystemExit(f"{tgz.name} package.json version {package_data.get('version')!r} != {version!r}")
|
|
60
|
+
print(f"npm tgz smoke ok: {tgz.name}")
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
def smoke_static_assets(version: str) -> None:
|
|
64
|
+
manifest_path = REPO_ROOT / "static" / "app" / "asset-manifest.json"
|
|
65
|
+
if not manifest_path.is_file():
|
|
66
|
+
raise SystemExit(f"missing static manifest: {manifest_path}")
|
|
67
|
+
manifest = json.loads(manifest_path.read_text(encoding="utf-8"))
|
|
68
|
+
if manifest.get("version") != version:
|
|
69
|
+
raise SystemExit(f"static manifest version {manifest.get('version')!r} != {version!r}")
|
|
70
|
+
required_paths = {"/static/app/index.html"}
|
|
71
|
+
required_paths.update(str(path) for path in manifest.get("assets", {}).values())
|
|
72
|
+
missing = []
|
|
73
|
+
for static_path in required_paths:
|
|
74
|
+
rel = static_path.removeprefix("/static/")
|
|
75
|
+
path = REPO_ROOT / "static" / rel
|
|
76
|
+
if not path.is_file():
|
|
77
|
+
missing.append(static_path)
|
|
78
|
+
if missing:
|
|
79
|
+
raise SystemExit(f"static manifest references missing files: {missing}")
|
|
80
|
+
print(f"static asset smoke ok: {len(required_paths)} files")
|
|
81
|
+
|
|
82
|
+
|
|
83
|
+
def smoke_tauri(version: str, launch: bool) -> None:
|
|
84
|
+
dmg = REPO_ROOT / "src-tauri" / "target" / "release" / "bundle" / "dmg" / f"Lattice AI_{version}_aarch64.dmg"
|
|
85
|
+
app = REPO_ROOT / "src-tauri" / "target" / "release" / "bundle" / "macos" / "Lattice AI.app"
|
|
86
|
+
macos_dir = app / "Contents" / "MacOS"
|
|
87
|
+
executable = app / "Contents" / "MacOS" / "Lattice AI"
|
|
88
|
+
if not executable.exists() and macos_dir.is_dir():
|
|
89
|
+
candidates = [path for path in macos_dir.iterdir() if path.is_file() and os.access(path, os.X_OK)]
|
|
90
|
+
if candidates:
|
|
91
|
+
executable = candidates[0]
|
|
92
|
+
missing = [path for path in (dmg, app, executable) if not path.exists()]
|
|
93
|
+
if missing:
|
|
94
|
+
raise SystemExit("missing Tauri artifact(s): " + ", ".join(str(path) for path in missing))
|
|
95
|
+
if launch:
|
|
96
|
+
env = {
|
|
97
|
+
**os.environ,
|
|
98
|
+
"LATTICEAI_ENABLE_TELEGRAM": "false",
|
|
99
|
+
"LATTICEAI_AUTOLOAD_MODELS": "false",
|
|
100
|
+
}
|
|
101
|
+
proc = subprocess.Popen([str(executable)], cwd=REPO_ROOT, env=env)
|
|
102
|
+
time.sleep(4)
|
|
103
|
+
if proc.poll() not in (None, 0):
|
|
104
|
+
raise SystemExit(f"Tauri executable exited early with {proc.returncode}")
|
|
105
|
+
if proc.poll() is None:
|
|
106
|
+
proc.terminate()
|
|
107
|
+
try:
|
|
108
|
+
proc.wait(timeout=5)
|
|
109
|
+
except subprocess.TimeoutExpired:
|
|
110
|
+
proc.kill()
|
|
111
|
+
proc.wait(timeout=5)
|
|
112
|
+
print("Tauri launch smoke ok")
|
|
113
|
+
else:
|
|
114
|
+
print(f"Tauri artifact smoke ok: {dmg.name}")
|
|
115
|
+
|
|
116
|
+
|
|
117
|
+
def main() -> int:
|
|
118
|
+
parser = argparse.ArgumentParser(description=__doc__)
|
|
119
|
+
parser.add_argument("version", help="exact version to smoke, e.g. 6.2.0")
|
|
120
|
+
parser.add_argument("--skip-wheel-health", action="store_true", help="skip FastAPI /health check inside wheel smoke")
|
|
121
|
+
parser.add_argument("--launch-tauri", action="store_true", help="briefly launch the built Tauri executable")
|
|
122
|
+
args = parser.parse_args()
|
|
123
|
+
|
|
124
|
+
smoke_wheel(args.version, args.skip_wheel_health)
|
|
125
|
+
smoke_npm_tgz(args.version)
|
|
126
|
+
smoke_static_assets(args.version)
|
|
127
|
+
smoke_tauri(args.version, args.launch_tauri)
|
|
128
|
+
print(f"release smoke passed for v{args.version}")
|
|
129
|
+
return 0
|
|
130
|
+
|
|
131
|
+
|
|
132
|
+
if __name__ == "__main__":
|
|
133
|
+
raise SystemExit(main())
|
package/scripts/wheel_smoke.py
CHANGED
|
@@ -46,9 +46,13 @@ WHEEL_MODULES = [
|
|
|
46
46
|
"latticeai",
|
|
47
47
|
"latticeai.server_app",
|
|
48
48
|
"latticeai.app_factory",
|
|
49
|
+
"latticeai.cli.entrypoint",
|
|
50
|
+
"latticeai.integrations",
|
|
51
|
+
"latticeai.integrations.telegram_bot",
|
|
49
52
|
"latticeai.models.router",
|
|
50
53
|
"latticeai.core.mcp_registry",
|
|
51
54
|
"latticeai.api.knowledge_graph",
|
|
55
|
+
"latticeai.services.p_reinforce",
|
|
52
56
|
"ltcai_cli",
|
|
53
57
|
"auto_setup",
|
|
54
58
|
"server",
|
package/src-tauri/Cargo.lock
CHANGED
package/src-tauri/Cargo.toml
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "6.
|
|
2
|
+
"version": "6.3.0",
|
|
3
3
|
"generated_at": "vite",
|
|
4
4
|
"entrypoints": {
|
|
5
5
|
"app": "/static/app/index.html"
|
|
6
6
|
},
|
|
7
7
|
"assets": {
|
|
8
8
|
"../node_modules/@tauri-apps/api/core.js": "/static/app/assets/core-CwxXejkd.js",
|
|
9
|
-
"index.html": "/static/app/assets/index-
|
|
10
|
-
"assets/index-
|
|
9
|
+
"index.html": "/static/app/assets/index-D76dWuQk.js",
|
|
10
|
+
"assets/index-Div5vMlq.css": "/static/app/assets/index-Div5vMlq.css"
|
|
11
11
|
},
|
|
12
12
|
"vite": {
|
|
13
13
|
"../node_modules/@tauri-apps/api/core.js": {
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"isDynamicEntry": true
|
|
18
18
|
},
|
|
19
19
|
"index.html": {
|
|
20
|
-
"file": "assets/index-
|
|
20
|
+
"file": "assets/index-D76dWuQk.js",
|
|
21
21
|
"name": "index",
|
|
22
22
|
"src": "index.html",
|
|
23
23
|
"isEntry": true,
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"../node_modules/@tauri-apps/api/core.js"
|
|
26
26
|
],
|
|
27
27
|
"css": [
|
|
28
|
-
"assets/index-
|
|
28
|
+
"assets/index-Div5vMlq.css"
|
|
29
29
|
]
|
|
30
30
|
}
|
|
31
31
|
}
|