aimx 0.1.0__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.
- aimx/__init__.py +3 -0
- aimx/__main__.py +13 -0
- aimx/cli.py +41 -0
- aimx/commands/__init__.py +1 -0
- aimx/commands/doctor.py +17 -0
- aimx/commands/help.py +19 -0
- aimx/commands/query.py +171 -0
- aimx/commands/version.py +12 -0
- aimx/native_aim/__init__.py +1 -0
- aimx/native_aim/locator.py +55 -0
- aimx/native_aim/passthrough.py +34 -0
- aimx/router.py +39 -0
- aimx-0.1.0.dist-info/METADATA +78 -0
- aimx-0.1.0.dist-info/RECORD +17 -0
- aimx-0.1.0.dist-info/WHEEL +4 -0
- aimx-0.1.0.dist-info/entry_points.txt +2 -0
- aimx-0.1.0.dist-info/licenses/LICENSE +201 -0
aimx/__init__.py
ADDED
aimx/__main__.py
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
import sys
|
|
4
|
+
|
|
5
|
+
from aimx.cli import run_cli
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
def main(argv: list[str] | None = None) -> int:
|
|
9
|
+
return run_cli(list(sys.argv[1:] if argv is None else argv))
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
if __name__ == "__main__":
|
|
13
|
+
raise SystemExit(main())
|
aimx/cli.py
ADDED
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
import sys
|
|
4
|
+
|
|
5
|
+
from aimx.commands.doctor import render_doctor
|
|
6
|
+
from aimx.commands.help import render_help
|
|
7
|
+
from aimx.commands.query import run_query_command
|
|
8
|
+
from aimx.commands.version import render_version
|
|
9
|
+
from aimx.native_aim.locator import resolve_native_aim
|
|
10
|
+
from aimx.native_aim.passthrough import run_passthrough
|
|
11
|
+
from aimx.router import route_args
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
def run_cli(args: list[str]) -> int:
|
|
15
|
+
route = route_args(args)
|
|
16
|
+
resolution = resolve_native_aim()
|
|
17
|
+
|
|
18
|
+
if route.route_kind == "owned":
|
|
19
|
+
command = route.owned_command
|
|
20
|
+
if command == "help":
|
|
21
|
+
sys.stdout.write(f"{render_help()}\n")
|
|
22
|
+
return 0
|
|
23
|
+
if command == "version":
|
|
24
|
+
sys.stdout.write(f"{render_version(resolution.version_text)}\n")
|
|
25
|
+
return 0
|
|
26
|
+
if command == "doctor":
|
|
27
|
+
sys.stdout.write(f"{render_doctor(resolution)}\n")
|
|
28
|
+
return 0 if resolution.status == "available" else 1
|
|
29
|
+
if command == "query":
|
|
30
|
+
result = run_query_command(route.owned_args or [])
|
|
31
|
+
if result.output:
|
|
32
|
+
sys.stdout.write(f"{result.output}\n")
|
|
33
|
+
if result.error_message:
|
|
34
|
+
sys.stderr.write(f"{result.error_message}\n")
|
|
35
|
+
return result.exit_status
|
|
36
|
+
raise ValueError(f"Unsupported owned command: {command}")
|
|
37
|
+
|
|
38
|
+
result = run_passthrough(route.delegated_args or [], resolution)
|
|
39
|
+
if not result.process_started and result.error_message:
|
|
40
|
+
sys.stderr.write(f"{result.error_message}\n")
|
|
41
|
+
return result.exit_status
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""Owned aimx commands."""
|
aimx/commands/doctor.py
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from aimx.native_aim.locator import NativeAimResolution
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
def render_doctor(resolution: NativeAimResolution) -> str:
|
|
7
|
+
ready = "ready" if resolution.status == "available" else "not ready"
|
|
8
|
+
lines = [
|
|
9
|
+
f"native aim status: {resolution.status}",
|
|
10
|
+
f"passthrough: {ready}",
|
|
11
|
+
f"message: {resolution.diagnostic_message}",
|
|
12
|
+
]
|
|
13
|
+
if resolution.executable_path:
|
|
14
|
+
lines.insert(1, f"native aim path: {resolution.executable_path}")
|
|
15
|
+
if resolution.version_text:
|
|
16
|
+
lines.insert(2, f"native aim version: {resolution.version_text}")
|
|
17
|
+
return "\n".join(lines)
|
aimx/commands/help.py
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
def render_help() -> str:
|
|
5
|
+
return "\n".join(
|
|
6
|
+
[
|
|
7
|
+
"aimx - a safe companion CLI for native Aim",
|
|
8
|
+
"",
|
|
9
|
+
"Owned commands:",
|
|
10
|
+
" help Show this help message",
|
|
11
|
+
" version Show the aimx version and detected native Aim version",
|
|
12
|
+
" doctor Show native Aim availability and passthrough readiness",
|
|
13
|
+
" query Query metrics or images from a local Aim repository",
|
|
14
|
+
" Usage: aimx query <metrics|images> <expression> --repo <path> [--json]",
|
|
15
|
+
" Repo paths may point at either the repo root or its .aim directory",
|
|
16
|
+
"",
|
|
17
|
+
"All other commands are delegated to native `aim`.",
|
|
18
|
+
]
|
|
19
|
+
)
|
aimx/commands/query.py
ADDED
|
@@ -0,0 +1,171 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
import json
|
|
4
|
+
from dataclasses import dataclass
|
|
5
|
+
from pathlib import Path
|
|
6
|
+
from typing import Any
|
|
7
|
+
|
|
8
|
+
from aim import Repo
|
|
9
|
+
from aim.sdk.types import QueryReportMode
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
SUPPORTED_TARGETS = {"metrics", "images"}
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
@dataclass(frozen=True)
|
|
16
|
+
class QueryInvocation:
|
|
17
|
+
target: str
|
|
18
|
+
expression: str
|
|
19
|
+
repo_path: Path
|
|
20
|
+
output_json: bool = False
|
|
21
|
+
|
|
22
|
+
def __post_init__(self) -> None:
|
|
23
|
+
if self.target not in SUPPORTED_TARGETS:
|
|
24
|
+
raise ValueError(
|
|
25
|
+
f"Unsupported query target: {self.target}. Supported targets: metrics, images."
|
|
26
|
+
)
|
|
27
|
+
if not self.expression.strip():
|
|
28
|
+
raise ValueError("Query expression must not be empty.")
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
@dataclass(frozen=True)
|
|
32
|
+
class QueryCommandResult:
|
|
33
|
+
exit_status: int
|
|
34
|
+
output: str | None = None
|
|
35
|
+
error_message: str | None = None
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
def normalize_repo_path(path: Path) -> Path:
|
|
39
|
+
if not path.exists():
|
|
40
|
+
raise ValueError(f"Repository path does not exist: {path}")
|
|
41
|
+
if path.name == ".aim":
|
|
42
|
+
return path.parent
|
|
43
|
+
return path
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
def parse_query_invocation(args: list[str]) -> QueryInvocation:
|
|
47
|
+
if len(args) < 4:
|
|
48
|
+
raise ValueError(
|
|
49
|
+
"Usage: aimx query <metrics|images> <expression> --repo <path> [--json]"
|
|
50
|
+
)
|
|
51
|
+
|
|
52
|
+
target = args[0]
|
|
53
|
+
expression = args[1]
|
|
54
|
+
rest = args[2:]
|
|
55
|
+
|
|
56
|
+
output_json = False
|
|
57
|
+
repo_value: str | None = None
|
|
58
|
+
index = 0
|
|
59
|
+
while index < len(rest):
|
|
60
|
+
token = rest[index]
|
|
61
|
+
if token == "--json":
|
|
62
|
+
output_json = True
|
|
63
|
+
index += 1
|
|
64
|
+
continue
|
|
65
|
+
if token == "--repo":
|
|
66
|
+
if index + 1 >= len(rest):
|
|
67
|
+
raise ValueError("Missing value for --repo.")
|
|
68
|
+
repo_value = rest[index + 1]
|
|
69
|
+
index += 2
|
|
70
|
+
continue
|
|
71
|
+
raise ValueError(f"Unsupported query option: {token}")
|
|
72
|
+
|
|
73
|
+
if repo_value is None:
|
|
74
|
+
raise ValueError("Missing required --repo <path> option.")
|
|
75
|
+
|
|
76
|
+
return QueryInvocation(
|
|
77
|
+
target=target,
|
|
78
|
+
expression=expression,
|
|
79
|
+
repo_path=Path(repo_value),
|
|
80
|
+
output_json=output_json,
|
|
81
|
+
)
|
|
82
|
+
|
|
83
|
+
|
|
84
|
+
def run_query_command(args: list[str]) -> QueryCommandResult:
|
|
85
|
+
try:
|
|
86
|
+
invocation = parse_query_invocation(args)
|
|
87
|
+
normalized_repo_path = normalize_repo_path(invocation.repo_path)
|
|
88
|
+
rows = collect_query_rows(invocation, normalized_repo_path)
|
|
89
|
+
except ValueError as error:
|
|
90
|
+
return QueryCommandResult(exit_status=2, error_message=str(error))
|
|
91
|
+
except RuntimeError as error:
|
|
92
|
+
return QueryCommandResult(exit_status=2, error_message=str(error))
|
|
93
|
+
except Exception as error:
|
|
94
|
+
return QueryCommandResult(
|
|
95
|
+
exit_status=2, error_message=f"Failed to evaluate query: {error}"
|
|
96
|
+
)
|
|
97
|
+
|
|
98
|
+
payload = {
|
|
99
|
+
"target": invocation.target,
|
|
100
|
+
"expression": invocation.expression,
|
|
101
|
+
"repo_path": str(normalized_repo_path),
|
|
102
|
+
"count": len(rows),
|
|
103
|
+
"rows": rows,
|
|
104
|
+
}
|
|
105
|
+
if invocation.output_json:
|
|
106
|
+
return QueryCommandResult(exit_status=0, output=json.dumps(payload))
|
|
107
|
+
return QueryCommandResult(exit_status=0, output=render_text_output(payload))
|
|
108
|
+
|
|
109
|
+
|
|
110
|
+
def collect_query_rows(invocation: QueryInvocation, repo_path: Path) -> list[dict[str, Any]]:
|
|
111
|
+
repo = Repo(str(repo_path))
|
|
112
|
+
|
|
113
|
+
if invocation.target == "metrics":
|
|
114
|
+
rows: list[dict[str, Any]] = []
|
|
115
|
+
results = repo.query_metrics(
|
|
116
|
+
invocation.expression, report_mode=QueryReportMode.DISABLED
|
|
117
|
+
)
|
|
118
|
+
for run_collection in results.iter_runs():
|
|
119
|
+
for metric in run_collection:
|
|
120
|
+
rows.append(
|
|
121
|
+
build_row(
|
|
122
|
+
run_id=metric.run.hash,
|
|
123
|
+
target="metrics",
|
|
124
|
+
name=metric.name,
|
|
125
|
+
context=metric.context.to_dict(),
|
|
126
|
+
)
|
|
127
|
+
)
|
|
128
|
+
return rows
|
|
129
|
+
|
|
130
|
+
rows = []
|
|
131
|
+
results = repo.query_images(invocation.expression, report_mode=QueryReportMode.DISABLED)
|
|
132
|
+
for image in results.iter():
|
|
133
|
+
rows.append(
|
|
134
|
+
build_row(
|
|
135
|
+
run_id=image.run.hash,
|
|
136
|
+
target="images",
|
|
137
|
+
name=image.name,
|
|
138
|
+
context=image.context.to_dict(),
|
|
139
|
+
)
|
|
140
|
+
)
|
|
141
|
+
return rows
|
|
142
|
+
|
|
143
|
+
|
|
144
|
+
def build_row(
|
|
145
|
+
*, run_id: str, target: str, name: str, context: dict[str, Any]
|
|
146
|
+
) -> dict[str, Any]:
|
|
147
|
+
summary = f"run {run_id} {target[:-1] if target.endswith('s') else target} {name}"
|
|
148
|
+
return {
|
|
149
|
+
"run_id": run_id,
|
|
150
|
+
"target": target,
|
|
151
|
+
"name": name,
|
|
152
|
+
"context": context,
|
|
153
|
+
"summary": summary,
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
|
|
157
|
+
def render_text_output(payload: dict[str, Any]) -> str:
|
|
158
|
+
lines = [
|
|
159
|
+
f"target: {payload['target']}",
|
|
160
|
+
f"repo: {payload['repo_path']}",
|
|
161
|
+
f"expression: {payload['expression']}",
|
|
162
|
+
f"matches: {payload['count']}",
|
|
163
|
+
]
|
|
164
|
+
if payload["rows"]:
|
|
165
|
+
for row in payload["rows"]:
|
|
166
|
+
lines.append(
|
|
167
|
+
f"- run={row['run_id']} name={row['name']} context={json.dumps(row['context'], sort_keys=True)}"
|
|
168
|
+
)
|
|
169
|
+
else:
|
|
170
|
+
lines.append("No matching results found.")
|
|
171
|
+
return "\n".join(lines)
|
aimx/commands/version.py
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from aimx import __version__
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
def render_version(native_aim_version: str | None = None) -> str:
|
|
7
|
+
lines = [f"aimx {__version__}"]
|
|
8
|
+
if native_aim_version:
|
|
9
|
+
lines.append(f"native aim {native_aim_version}")
|
|
10
|
+
else:
|
|
11
|
+
lines.append("native aim unavailable")
|
|
12
|
+
return "\n".join(lines)
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""Native Aim discovery and passthrough helpers."""
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from dataclasses import dataclass
|
|
4
|
+
import shutil
|
|
5
|
+
import subprocess
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
@dataclass(frozen=True)
|
|
9
|
+
class NativeAimResolution:
|
|
10
|
+
status: str
|
|
11
|
+
executable_path: str | None
|
|
12
|
+
version_text: str | None
|
|
13
|
+
diagnostic_message: str
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
def resolve_native_aim() -> NativeAimResolution:
|
|
17
|
+
executable = shutil.which("aim")
|
|
18
|
+
if not executable:
|
|
19
|
+
return NativeAimResolution(
|
|
20
|
+
status="missing",
|
|
21
|
+
executable_path=None,
|
|
22
|
+
version_text=None,
|
|
23
|
+
diagnostic_message="native aim is not available; install native Aim or make `aim` discoverable in PATH.",
|
|
24
|
+
)
|
|
25
|
+
|
|
26
|
+
try:
|
|
27
|
+
result = subprocess.run(
|
|
28
|
+
[executable, "version"],
|
|
29
|
+
capture_output=True,
|
|
30
|
+
text=True,
|
|
31
|
+
check=False,
|
|
32
|
+
)
|
|
33
|
+
except OSError as exc:
|
|
34
|
+
return NativeAimResolution(
|
|
35
|
+
status="unusable",
|
|
36
|
+
executable_path=executable,
|
|
37
|
+
version_text=None,
|
|
38
|
+
diagnostic_message=f"native aim at {executable} could not be executed: {exc}",
|
|
39
|
+
)
|
|
40
|
+
|
|
41
|
+
if result.returncode != 0:
|
|
42
|
+
return NativeAimResolution(
|
|
43
|
+
status="unusable",
|
|
44
|
+
executable_path=executable,
|
|
45
|
+
version_text=None,
|
|
46
|
+
diagnostic_message=f"native aim at {executable} could not be executed successfully.",
|
|
47
|
+
)
|
|
48
|
+
|
|
49
|
+
version_text = (result.stdout or "").strip() or None
|
|
50
|
+
return NativeAimResolution(
|
|
51
|
+
status="available",
|
|
52
|
+
executable_path=executable,
|
|
53
|
+
version_text=version_text,
|
|
54
|
+
diagnostic_message=f"native aim available at {executable}",
|
|
55
|
+
)
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from dataclasses import dataclass
|
|
4
|
+
import subprocess
|
|
5
|
+
|
|
6
|
+
from aimx.native_aim.locator import NativeAimResolution
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
@dataclass(frozen=True)
|
|
10
|
+
class DelegatedExecutionResult:
|
|
11
|
+
process_started: bool
|
|
12
|
+
exit_status: int
|
|
13
|
+
error_message: str | None = None
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
def run_passthrough(args: list[str], resolution: NativeAimResolution) -> DelegatedExecutionResult:
|
|
17
|
+
if resolution.status == "missing":
|
|
18
|
+
return DelegatedExecutionResult(
|
|
19
|
+
process_started=False,
|
|
20
|
+
exit_status=127,
|
|
21
|
+
error_message=resolution.diagnostic_message,
|
|
22
|
+
)
|
|
23
|
+
if resolution.status == "unusable":
|
|
24
|
+
return DelegatedExecutionResult(
|
|
25
|
+
process_started=False,
|
|
26
|
+
exit_status=126,
|
|
27
|
+
error_message=resolution.diagnostic_message,
|
|
28
|
+
)
|
|
29
|
+
|
|
30
|
+
result = subprocess.run(
|
|
31
|
+
[resolution.executable_path, *args],
|
|
32
|
+
check=False,
|
|
33
|
+
)
|
|
34
|
+
return DelegatedExecutionResult(process_started=True, exit_status=result.returncode)
|
aimx/router.py
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from dataclasses import dataclass
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
OWNED_COMMANDS = {"help", "--help", "-h", "version", "doctor"}
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
@dataclass(frozen=True)
|
|
10
|
+
class CommandRoute:
|
|
11
|
+
route_kind: str
|
|
12
|
+
owned_command: str | None = None
|
|
13
|
+
owned_args: list[str] | None = None
|
|
14
|
+
delegated_args: list[str] | None = None
|
|
15
|
+
reason: str = ""
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
def route_args(args: list[str]) -> CommandRoute:
|
|
19
|
+
if not args:
|
|
20
|
+
return CommandRoute("owned", owned_command="help", reason="empty invocation")
|
|
21
|
+
|
|
22
|
+
command = args[0]
|
|
23
|
+
if command in {"help", "--help", "-h"}:
|
|
24
|
+
return CommandRoute("owned", owned_command="help", reason="reserved help command")
|
|
25
|
+
if command in {"version", "doctor"}:
|
|
26
|
+
return CommandRoute("owned", owned_command=command, reason="reserved aimx command")
|
|
27
|
+
if command == "query":
|
|
28
|
+
return CommandRoute(
|
|
29
|
+
"owned",
|
|
30
|
+
owned_command="query",
|
|
31
|
+
owned_args=list(args[1:]),
|
|
32
|
+
reason="reserved aimx query command",
|
|
33
|
+
)
|
|
34
|
+
|
|
35
|
+
return CommandRoute(
|
|
36
|
+
"passthrough",
|
|
37
|
+
delegated_args=list(args),
|
|
38
|
+
reason="unowned command delegated to native aim",
|
|
39
|
+
)
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: aimx
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: A safe CLI-first companion for native Aim
|
|
5
|
+
License-File: LICENSE
|
|
6
|
+
Requires-Python: <3.13,>=3.10
|
|
7
|
+
Description-Content-Type: text/markdown
|
|
8
|
+
|
|
9
|
+
# aimx
|
|
10
|
+
|
|
11
|
+
`aimx` is a safe, additive, CLI-first companion for native Aim.
|
|
12
|
+
|
|
13
|
+
It keeps a small owned command surface for diagnostics and guidance, and
|
|
14
|
+
delegates everything else to the native `aim` executable already available in
|
|
15
|
+
the user's environment.
|
|
16
|
+
|
|
17
|
+
## What aimx owns
|
|
18
|
+
|
|
19
|
+
- `aimx`
|
|
20
|
+
- `aimx --help`
|
|
21
|
+
- `aimx help`
|
|
22
|
+
- `aimx version`
|
|
23
|
+
- `aimx doctor`
|
|
24
|
+
- `aimx query`
|
|
25
|
+
|
|
26
|
+
These commands explain how `aimx` works, show the `aimx` version, and report
|
|
27
|
+
whether native Aim is available for passthrough. `aimx query` adds a read-only
|
|
28
|
+
CLI for querying metric and image data from a local Aim repository.
|
|
29
|
+
|
|
30
|
+
Query usage:
|
|
31
|
+
|
|
32
|
+
```bash
|
|
33
|
+
aimx query metrics "metric.name == 'loss'" --repo data
|
|
34
|
+
aimx query images "images" --repo data --json
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
`--repo` accepts either the repository root, such as `data`, or the metadata
|
|
38
|
+
directory itself, such as `data/.aim`.
|
|
39
|
+
|
|
40
|
+
## What aimx delegates
|
|
41
|
+
|
|
42
|
+
Any unowned command path is passed through to native `aim`.
|
|
43
|
+
|
|
44
|
+
Examples:
|
|
45
|
+
|
|
46
|
+
```bash
|
|
47
|
+
aimx up
|
|
48
|
+
aimx init --help
|
|
49
|
+
aimx runs --help
|
|
50
|
+
aimx runs ls
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
## Runtime contract
|
|
54
|
+
|
|
55
|
+
- `aimx` does not replace the `aim` executable.
|
|
56
|
+
- `aimx` does not modify the installed `aim` package.
|
|
57
|
+
- `aimx` does not mutate `.aim` data during help, version, doctor, or
|
|
58
|
+
passthrough flows.
|
|
59
|
+
- Native Aim remains an external runtime prerequisite for delegated commands.
|
|
60
|
+
- The repo's development dependency on Aim is only for local development and
|
|
61
|
+
testing convenience.
|
|
62
|
+
|
|
63
|
+
## Local development
|
|
64
|
+
|
|
65
|
+
```bash
|
|
66
|
+
uv sync --group dev
|
|
67
|
+
uv run pytest
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
## Quick checks
|
|
71
|
+
|
|
72
|
+
```bash
|
|
73
|
+
uv run aimx --help
|
|
74
|
+
uv run aimx version
|
|
75
|
+
uv run aimx doctor
|
|
76
|
+
uv run aimx query metrics "metric.name == 'loss'" --repo data
|
|
77
|
+
uv run aimx query images "images" --repo data/.aim --json
|
|
78
|
+
```
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
aimx/__init__.py,sha256=4t_crzhrLum--oyowUMxtjBTzUtWp7oRTF22ewEvJG4,49
|
|
2
|
+
aimx/__main__.py,sha256=UFoUaXFUjQMWSKvmmaHmBuxuKAMzcJlbu_awMSHFRC0,250
|
|
3
|
+
aimx/cli.py,sha256=NjEKKSDr2mjWNkEwRyuE5qO6SVx3xZV5XJKB89_qoLg,1552
|
|
4
|
+
aimx/router.py,sha256=GJtZXmlzXWXfRe-OZN8av0Xpo_Vjb8d3wHSFxIXI1M0,1147
|
|
5
|
+
aimx/commands/__init__.py,sha256=2nhjKw9LJdbxs3kfFATSNAgstiGFVAYdL46bjTAsmm0,27
|
|
6
|
+
aimx/commands/doctor.py,sha256=ZbPR9ibYs21VCDUhLuM3KzDqTeDDC0sn-IFSNay1-jw,626
|
|
7
|
+
aimx/commands/help.py,sha256=RmxvbDdrnI9DSNCzPLO7cPy_7VmfX4dCFHqROfmw56Y,787
|
|
8
|
+
aimx/commands/query.py,sha256=FHwPiMhNiAFlkOzHxpwga-x2lwG-WTJOoPxZG8PLpkk,5130
|
|
9
|
+
aimx/commands/version.py,sha256=snykawl-X9Z4aADrr4o1h6aC19tp4X5BjXUJDUQCbkU,338
|
|
10
|
+
aimx/native_aim/__init__.py,sha256=zv4KNDPjNnXQ2jttgiRbueM12q1g3HbnJlqLhbnOUlM,52
|
|
11
|
+
aimx/native_aim/locator.py,sha256=jtujO3jVfvcYASdIawZbzQw2iqQyEZpHP3H5aOGQad8,1608
|
|
12
|
+
aimx/native_aim/passthrough.py,sha256=jQu-4MbI02XbfrkjvBUe-e-QS4cDpp7_mh3XbvfQrrM,1002
|
|
13
|
+
aimx-0.1.0.dist-info/METADATA,sha256=t7bbsYCtIzVXqw9XcPUjjKGyZ23UgfV7KbLF81k8Cig,1851
|
|
14
|
+
aimx-0.1.0.dist-info/WHEEL,sha256=QccIxa26bgl1E6uMy58deGWi-0aeIkkangHcxk2kWfw,87
|
|
15
|
+
aimx-0.1.0.dist-info/entry_points.txt,sha256=x9GpiNzOIfNYwsgylMxgWK5AfDv7VKarWrFN9xDmY74,44
|
|
16
|
+
aimx-0.1.0.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
17
|
+
aimx-0.1.0.dist-info/RECORD,,
|
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
Apache License
|
|
2
|
+
Version 2.0, January 2004
|
|
3
|
+
http://www.apache.org/licenses/
|
|
4
|
+
|
|
5
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
6
|
+
|
|
7
|
+
1. Definitions.
|
|
8
|
+
|
|
9
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
10
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
11
|
+
|
|
12
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
13
|
+
the copyright owner that is granting the License.
|
|
14
|
+
|
|
15
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
16
|
+
other entities that control, are controlled by, or are under common
|
|
17
|
+
control with that entity. For the purposes of this definition,
|
|
18
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
19
|
+
direction or management of such entity, whether by contract or
|
|
20
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
21
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
22
|
+
|
|
23
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
24
|
+
exercising permissions granted by this License.
|
|
25
|
+
|
|
26
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
27
|
+
including but not limited to software source code, documentation
|
|
28
|
+
source, and configuration files.
|
|
29
|
+
|
|
30
|
+
"Object" form shall mean any form resulting from mechanical
|
|
31
|
+
transformation or translation of a Source form, including but
|
|
32
|
+
not limited to compiled object code, generated documentation,
|
|
33
|
+
and conversions to other media types.
|
|
34
|
+
|
|
35
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
36
|
+
Object form, made available under the License, as indicated by a
|
|
37
|
+
copyright notice that is included in or attached to the work
|
|
38
|
+
(an example is provided in the Appendix below).
|
|
39
|
+
|
|
40
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
41
|
+
form, that is based on (or derived from) the Work and for which the
|
|
42
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
43
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
44
|
+
of this License, Derivative Works shall not include works that remain
|
|
45
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
46
|
+
the Work and Derivative Works thereof.
|
|
47
|
+
|
|
48
|
+
"Contribution" shall mean any work of authorship, including
|
|
49
|
+
the original version of the Work and any modifications or additions
|
|
50
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
51
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
52
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
53
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
54
|
+
means any form of electronic, verbal, or written communication sent
|
|
55
|
+
to the Licensor or its representatives, including but not limited to
|
|
56
|
+
communication on electronic mailing lists, source code control systems,
|
|
57
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
58
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
59
|
+
excluding communication that is conspicuously marked or otherwise
|
|
60
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
61
|
+
|
|
62
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
63
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
64
|
+
subsequently incorporated within the Work.
|
|
65
|
+
|
|
66
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
67
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
68
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
69
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
70
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
71
|
+
Work and such Derivative Works in Source or Object form.
|
|
72
|
+
|
|
73
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
74
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
75
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
76
|
+
(except as stated in this section) patent license to make, have made,
|
|
77
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
78
|
+
where such license applies only to those patent claims licensable
|
|
79
|
+
by such Contributor that are necessarily infringed by their
|
|
80
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
81
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
82
|
+
institute patent litigation against any entity (including a
|
|
83
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
84
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
85
|
+
or contributory patent infringement, then any patent licenses
|
|
86
|
+
granted to You under this License for that Work shall terminate
|
|
87
|
+
as of the date such litigation is filed.
|
|
88
|
+
|
|
89
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
90
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
91
|
+
modifications, and in Source or Object form, provided that You
|
|
92
|
+
meet the following conditions:
|
|
93
|
+
|
|
94
|
+
(a) You must give any other recipients of the Work or
|
|
95
|
+
Derivative Works a copy of this License; and
|
|
96
|
+
|
|
97
|
+
(b) You must cause any modified files to carry prominent notices
|
|
98
|
+
stating that You changed the files; and
|
|
99
|
+
|
|
100
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
101
|
+
that You distribute, all copyright, patent, trademark, and
|
|
102
|
+
attribution notices from the Source form of the Work,
|
|
103
|
+
excluding those notices that do not pertain to any part of
|
|
104
|
+
the Derivative Works; and
|
|
105
|
+
|
|
106
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
107
|
+
distribution, then any Derivative Works that You distribute must
|
|
108
|
+
include a readable copy of the attribution notices contained
|
|
109
|
+
within such NOTICE file, excluding those notices that do not
|
|
110
|
+
pertain to any part of the Derivative Works, in at least one
|
|
111
|
+
of the following places: within a NOTICE text file distributed
|
|
112
|
+
as part of the Derivative Works; within the Source form or
|
|
113
|
+
documentation, if provided along with the Derivative Works; or,
|
|
114
|
+
within a display generated by the Derivative Works, if and
|
|
115
|
+
wherever such third-party notices normally appear. The contents
|
|
116
|
+
of the NOTICE file are for informational purposes only and
|
|
117
|
+
do not modify the License. You may add Your own attribution
|
|
118
|
+
notices within Derivative Works that You distribute, alongside
|
|
119
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
120
|
+
that such additional attribution notices cannot be construed
|
|
121
|
+
as modifying the License.
|
|
122
|
+
|
|
123
|
+
You may add Your own copyright statement to Your modifications and
|
|
124
|
+
may provide additional or different license terms and conditions
|
|
125
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
126
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
127
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
128
|
+
the conditions stated in this License.
|
|
129
|
+
|
|
130
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
131
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
132
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
133
|
+
this License, without any additional terms or conditions.
|
|
134
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
135
|
+
the terms of any separate license agreement you may have executed
|
|
136
|
+
with Licensor regarding such Contributions.
|
|
137
|
+
|
|
138
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
139
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
140
|
+
except as required for reasonable and customary use in describing the
|
|
141
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
142
|
+
|
|
143
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
144
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
145
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
146
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
147
|
+
implied, including, without limitation, any warranties or conditions
|
|
148
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
149
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
150
|
+
appropriateness of using or redistributing the Work and assume any
|
|
151
|
+
risks associated with Your exercise of permissions under this License.
|
|
152
|
+
|
|
153
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
154
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
155
|
+
unless required by applicable law (such as deliberate and grossly
|
|
156
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
157
|
+
liable to You for damages, including any direct, indirect, special,
|
|
158
|
+
incidental, or consequential damages of any character arising as a
|
|
159
|
+
result of this License or out of the use or inability to use the
|
|
160
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
161
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
162
|
+
other commercial damages or losses), even if such Contributor
|
|
163
|
+
has been advised of the possibility of such damages.
|
|
164
|
+
|
|
165
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
166
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
167
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
168
|
+
or other liability obligations and/or rights consistent with this
|
|
169
|
+
License. However, in accepting such obligations, You may act only
|
|
170
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
171
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
172
|
+
defend, and hold each Contributor harmless for any liability
|
|
173
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
174
|
+
of your accepting any such warranty or additional liability.
|
|
175
|
+
|
|
176
|
+
END OF TERMS AND CONDITIONS
|
|
177
|
+
|
|
178
|
+
APPENDIX: How to apply the Apache License to your work.
|
|
179
|
+
|
|
180
|
+
To apply the Apache License to your work, attach the following
|
|
181
|
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
182
|
+
replaced with your own identifying information. (Don't include
|
|
183
|
+
the brackets!) The text should be enclosed in the appropriate
|
|
184
|
+
comment syntax for the file format. We also recommend that a
|
|
185
|
+
file or class name and description of purpose be included on the
|
|
186
|
+
same "printed page" as the copyright notice for easier
|
|
187
|
+
identification within third-party archives.
|
|
188
|
+
|
|
189
|
+
Copyright [yyyy] [name of copyright owner]
|
|
190
|
+
|
|
191
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
192
|
+
you may not use this file except in compliance with the License.
|
|
193
|
+
You may obtain a copy of the License at
|
|
194
|
+
|
|
195
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
196
|
+
|
|
197
|
+
Unless required by applicable law or agreed to in writing, software
|
|
198
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
199
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
200
|
+
See the License for the specific language governing permissions and
|
|
201
|
+
limitations under the License.
|