pudu-ai 0.2.6 → 0.2.7
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/dist/cli/index.js +85 -21
- package/package.json +1 -1
package/dist/cli/index.js
CHANGED
|
@@ -828,6 +828,7 @@ async function loadCatalogCache() {
|
|
|
828
828
|
var en = {
|
|
829
829
|
appTitle: "PUDU-AI",
|
|
830
830
|
appSubtitle: "Local AI Hardware & Benchmark Lab",
|
|
831
|
+
byline: "by devjaime",
|
|
831
832
|
aboutDashboard: "Opens the live lab: your machine, installed models, and estimates. Use it to see what can run here before you benchmark or launch a tool.",
|
|
832
833
|
aboutHardware: "Detects CPU, GPU, and Unified Memory/RAM. Use it to know what this computer can host before pulling a model.",
|
|
833
834
|
aboutModels: "Lists installed models vs catalog fits. FIT/EST. SPEED are estimated (CanIRun.ai by midudev); MEASURED is llama-bench history. Use it to separate \u201Calready here\u201D from \u201Cmight run\u201D.",
|
|
@@ -1011,6 +1012,7 @@ Credits:
|
|
|
1011
1012
|
var es = {
|
|
1012
1013
|
appTitle: "PUDU-AI",
|
|
1013
1014
|
appSubtitle: "Laboratorio local de hardware y benchmarks de IA",
|
|
1015
|
+
byline: "by devjaime",
|
|
1014
1016
|
aboutDashboard: "Abre el laboratorio en vivo: equipo, modelos instalados y estimaciones. Sirve para ver qu\xE9 puede correr aqu\xED antes de medir o lanzar una herramienta.",
|
|
1015
1017
|
aboutHardware: "Detecta CPU, GPU y memoria unificada/RAM. Sirve para saber qu\xE9 puede hospedar este equipo antes de descargar un modelo.",
|
|
1016
1018
|
aboutModels: "Lista instalados frente al cat\xE1logo. FIT/EST. SPEED son estimados (CanIRun.ai de midudev); MEASURED es historial de llama-bench. Sirve para separar \u201Cya est\xE1\u201D de \u201Cpodr\xEDa correr\u201D.",
|
|
@@ -1950,7 +1952,7 @@ function setLogLevel(next) {
|
|
|
1950
1952
|
import { render } from "ink";
|
|
1951
1953
|
|
|
1952
1954
|
// src/tui/App.tsx
|
|
1953
|
-
import { Box as
|
|
1955
|
+
import { Box as Box10, useApp as useApp2, useInput as useInput4 } from "ink";
|
|
1954
1956
|
import { useMemo as useMemo2, useState as useState4 } from "react";
|
|
1955
1957
|
|
|
1956
1958
|
// src/tui/views/Dashboard.tsx
|
|
@@ -2015,11 +2017,7 @@ import { jsx, jsxs } from "react/jsx-runtime";
|
|
|
2015
2017
|
function Dashboard({ session }) {
|
|
2016
2018
|
const h = session.hardware;
|
|
2017
2019
|
return /* @__PURE__ */ jsxs(Box, { flexDirection: "column", children: [
|
|
2018
|
-
/* @__PURE__ */
|
|
2019
|
-
/* @__PURE__ */ jsx(Text, { bold: true, color: "cyan", children: t("appTitle") }),
|
|
2020
|
-
/* @__PURE__ */ jsx(Text, { dimColor: true, children: t("appSubtitle") }),
|
|
2021
|
-
/* @__PURE__ */ jsx(Text, { dimColor: true, children: t("aboutDashboard") })
|
|
2022
|
-
] }),
|
|
2020
|
+
/* @__PURE__ */ jsx(Text, { dimColor: true, children: t("aboutDashboard") }),
|
|
2023
2021
|
/* @__PURE__ */ jsx(Text, { bold: true, color: "cyan", children: t("machine") }),
|
|
2024
2022
|
/* @__PURE__ */ jsx(Text, { children: h.machineModel ?? t("unknownMachine") }),
|
|
2025
2023
|
/* @__PURE__ */ jsx(Text, { children: h.cpu.name ?? t("cpuNa") }),
|
|
@@ -2287,7 +2285,7 @@ import { jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
|
2287
2285
|
function ModelsView({ session }) {
|
|
2288
2286
|
return /* @__PURE__ */ jsxs2(Box2, { flexDirection: "column", children: [
|
|
2289
2287
|
/* @__PURE__ */ jsx2(Text2, { children: modelsText(session) }),
|
|
2290
|
-
/* @__PURE__ */ jsx2(Text2, {
|
|
2288
|
+
/* @__PURE__ */ jsx2(Text2, { color: "yellow", children: t("modelsHint") })
|
|
2291
2289
|
] });
|
|
2292
2290
|
}
|
|
2293
2291
|
|
|
@@ -2298,7 +2296,7 @@ function HardwareView({ session }) {
|
|
|
2298
2296
|
return /* @__PURE__ */ jsxs3(Box3, { flexDirection: "column", children: [
|
|
2299
2297
|
/* @__PURE__ */ jsx3(Text3, { children: hardwareText(session) }),
|
|
2300
2298
|
/* @__PURE__ */ jsx3(Text3, { children: runtimesText(session) }),
|
|
2301
|
-
/* @__PURE__ */ jsx3(Text3, {
|
|
2299
|
+
/* @__PURE__ */ jsx3(Text3, { color: "yellow", children: t("hardwareHint") })
|
|
2302
2300
|
] });
|
|
2303
2301
|
}
|
|
2304
2302
|
|
|
@@ -3059,8 +3057,73 @@ function handleAppKey(screen, input, key) {
|
|
|
3059
3057
|
return { type: "ignore" };
|
|
3060
3058
|
}
|
|
3061
3059
|
|
|
3062
|
-
// src/tui/
|
|
3060
|
+
// src/tui/Welcome.tsx
|
|
3061
|
+
import { Box as Box9, Text as Text9 } from "ink";
|
|
3063
3062
|
import { jsx as jsx9, jsxs as jsxs8 } from "react/jsx-runtime";
|
|
3063
|
+
function Welcome({ compact = false }) {
|
|
3064
|
+
if (compact) {
|
|
3065
|
+
return /* @__PURE__ */ jsxs8(Box9, { marginBottom: 1, children: [
|
|
3066
|
+
/* @__PURE__ */ jsx9(Text9, { color: "yellow", children: "\u{1F98C} " }),
|
|
3067
|
+
/* @__PURE__ */ jsx9(Text9, { bold: true, color: "cyan", children: t("appTitle") }),
|
|
3068
|
+
/* @__PURE__ */ jsxs8(Text9, { color: "magenta", children: [
|
|
3069
|
+
" ",
|
|
3070
|
+
t("byline")
|
|
3071
|
+
] })
|
|
3072
|
+
] });
|
|
3073
|
+
}
|
|
3074
|
+
return /* @__PURE__ */ jsxs8(Box9, { flexDirection: "column", marginBottom: 1, children: [
|
|
3075
|
+
/* @__PURE__ */ jsx9(Text9, { color: "yellow", children: " \\/ \\/" }),
|
|
3076
|
+
/* @__PURE__ */ jsxs8(Text9, { children: [
|
|
3077
|
+
/* @__PURE__ */ jsx9(Text9, { color: "yellow", children: " " }),
|
|
3078
|
+
/* @__PURE__ */ jsx9(Text9, { color: "cyan", children: " (\\_ _/)" })
|
|
3079
|
+
] }),
|
|
3080
|
+
/* @__PURE__ */ jsxs8(Text9, { children: [
|
|
3081
|
+
/* @__PURE__ */ jsx9(Text9, { color: "cyan", children: " / " }),
|
|
3082
|
+
/* @__PURE__ */ jsx9(Text9, { color: "white", children: "o o" }),
|
|
3083
|
+
/* @__PURE__ */ jsx9(Text9, { color: "cyan", children: " \\" }),
|
|
3084
|
+
/* @__PURE__ */ jsx9(Text9, { children: " " }),
|
|
3085
|
+
/* @__PURE__ */ jsx9(Text9, { bold: true, color: "green", children: t("appTitle") })
|
|
3086
|
+
] }),
|
|
3087
|
+
/* @__PURE__ */ jsxs8(Text9, { children: [
|
|
3088
|
+
/* @__PURE__ */ jsx9(Text9, { color: "cyan", children: " \\ " }),
|
|
3089
|
+
/* @__PURE__ */ jsx9(Text9, { color: "red", children: "^" }),
|
|
3090
|
+
/* @__PURE__ */ jsx9(Text9, { color: "cyan", children: " /" }),
|
|
3091
|
+
/* @__PURE__ */ jsx9(Text9, { children: " " }),
|
|
3092
|
+
/* @__PURE__ */ jsx9(Text9, { color: "white", children: t("appSubtitle") })
|
|
3093
|
+
] }),
|
|
3094
|
+
/* @__PURE__ */ jsxs8(Text9, { children: [
|
|
3095
|
+
/* @__PURE__ */ jsx9(Text9, { color: "green", children: " /| |\\" }),
|
|
3096
|
+
/* @__PURE__ */ jsx9(Text9, { children: " " }),
|
|
3097
|
+
/* @__PURE__ */ jsx9(Text9, { bold: true, color: "magenta", children: t("byline") })
|
|
3098
|
+
] }),
|
|
3099
|
+
/* @__PURE__ */ jsx9(Text9, { color: "green", children: " U U" })
|
|
3100
|
+
] });
|
|
3101
|
+
}
|
|
3102
|
+
function ColorNav() {
|
|
3103
|
+
return /* @__PURE__ */ jsx9(Box9, { marginTop: 1, children: /* @__PURE__ */ jsxs8(Text9, { children: [
|
|
3104
|
+
/* @__PURE__ */ jsx9(Text9, { color: "yellow", bold: true, children: "[S]" }),
|
|
3105
|
+
/* @__PURE__ */ jsx9(Text9, { color: "yellow", children: " Setup " }),
|
|
3106
|
+
/* @__PURE__ */ jsx9(Text9, { color: "green", bold: true, children: "[B]" }),
|
|
3107
|
+
/* @__PURE__ */ jsx9(Text9, { color: "green", children: " Bench " }),
|
|
3108
|
+
/* @__PURE__ */ jsx9(Text9, { color: "cyan", bold: true, children: "[M]" }),
|
|
3109
|
+
/* @__PURE__ */ jsx9(Text9, { color: "cyan", children: " Models " }),
|
|
3110
|
+
/* @__PURE__ */ jsx9(Text9, { color: "magenta", bold: true, children: "[R]" }),
|
|
3111
|
+
/* @__PURE__ */ jsx9(Text9, { color: "magenta", children: " Rec " }),
|
|
3112
|
+
/* @__PURE__ */ jsx9(Text9, { color: "blue", bold: true, children: "[T]" }),
|
|
3113
|
+
/* @__PURE__ */ jsx9(Text9, { color: "blue", children: " Tasks " }),
|
|
3114
|
+
/* @__PURE__ */ jsx9(Text9, { color: "white", bold: true, children: "[H]" }),
|
|
3115
|
+
/* @__PURE__ */ jsx9(Text9, { children: " HW " }),
|
|
3116
|
+
/* @__PURE__ */ jsx9(Text9, { color: "green", bold: true, children: "[C]" }),
|
|
3117
|
+
/* @__PURE__ */ jsx9(Text9, { color: "green", children: " Cmp " }),
|
|
3118
|
+
/* @__PURE__ */ jsx9(Text9, { color: "cyan", bold: true, children: "[L]" }),
|
|
3119
|
+
/* @__PURE__ */ jsx9(Text9, { color: "cyan", children: " Log " }),
|
|
3120
|
+
/* @__PURE__ */ jsx9(Text9, { color: "red", bold: true, children: "[Q]" }),
|
|
3121
|
+
/* @__PURE__ */ jsx9(Text9, { color: "red", children: " Quit" })
|
|
3122
|
+
] }) });
|
|
3123
|
+
}
|
|
3124
|
+
|
|
3125
|
+
// src/tui/App.tsx
|
|
3126
|
+
import { jsx as jsx10, jsxs as jsxs9 } from "react/jsx-runtime";
|
|
3064
3127
|
function App(props) {
|
|
3065
3128
|
const { exit } = useApp2();
|
|
3066
3129
|
const [screen, setScreen] = useState4(props.start ?? "home");
|
|
@@ -3075,15 +3138,16 @@ function App(props) {
|
|
|
3075
3138
|
if (result.type === "home") setScreen("home");
|
|
3076
3139
|
if (result.type === "screen") setScreen(result.screen);
|
|
3077
3140
|
});
|
|
3078
|
-
return /* @__PURE__ */
|
|
3079
|
-
screen
|
|
3080
|
-
screen === "
|
|
3081
|
-
screen === "
|
|
3082
|
-
screen === "
|
|
3083
|
-
screen === "
|
|
3084
|
-
screen === "
|
|
3085
|
-
screen === "
|
|
3086
|
-
screen === "
|
|
3141
|
+
return /* @__PURE__ */ jsxs9(Box10, { flexDirection: "column", padding: 1, children: [
|
|
3142
|
+
screen !== "benchmark" && /* @__PURE__ */ jsx10(Welcome, { compact: screen !== "home" }),
|
|
3143
|
+
screen === "home" && /* @__PURE__ */ jsx10(Dashboard, { session: props.session }),
|
|
3144
|
+
screen === "models" && /* @__PURE__ */ jsx10(ModelsView, { session: props.session }),
|
|
3145
|
+
screen === "hardware" && /* @__PURE__ */ jsx10(HardwareView, { session: props.session }),
|
|
3146
|
+
screen === "recommend" && /* @__PURE__ */ jsx10(RecommendView, { session: props.session }),
|
|
3147
|
+
screen === "compare" && /* @__PURE__ */ jsx10(CompareView, { session: props.session }),
|
|
3148
|
+
screen === "history" && /* @__PURE__ */ jsx10(HistoryView, { session: props.session }),
|
|
3149
|
+
screen === "tasks" && /* @__PURE__ */ jsx10(TasksView, { session: props.session }),
|
|
3150
|
+
screen === "benchmark" && /* @__PURE__ */ jsx10(
|
|
3087
3151
|
BenchmarkView,
|
|
3088
3152
|
{
|
|
3089
3153
|
session: props.session,
|
|
@@ -3094,14 +3158,14 @@ function App(props) {
|
|
|
3094
3158
|
onBack: () => setScreen("home")
|
|
3095
3159
|
}
|
|
3096
3160
|
),
|
|
3097
|
-
screen !== "benchmark" && /* @__PURE__ */
|
|
3161
|
+
screen !== "benchmark" && /* @__PURE__ */ jsx10(ColorNav, {})
|
|
3098
3162
|
] });
|
|
3099
3163
|
}
|
|
3100
3164
|
|
|
3101
3165
|
// src/tui/render.tsx
|
|
3102
|
-
import { jsx as
|
|
3166
|
+
import { jsx as jsx11 } from "react/jsx-runtime";
|
|
3103
3167
|
async function renderDashboard(session, preset, start) {
|
|
3104
|
-
const instance = render(/* @__PURE__ */
|
|
3168
|
+
const instance = render(/* @__PURE__ */ jsx11(App, { session, preset, start }));
|
|
3105
3169
|
await instance.waitUntilExit();
|
|
3106
3170
|
}
|
|
3107
3171
|
|