ollanet 0.6.3 → 0.6.5

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/show.js CHANGED
@@ -8,20 +8,24 @@ import { ollamaShow } from "./ollama-chat.js";
8
8
  import { failUsage, isHelpFlag, printHelp, takeFlag } from "./argv.js";
9
9
  import { resolveTarget } from "./target.js";
10
10
  import { looksTuned } from "./tuned.js";
11
+ import { expandMachineModel, loadConfig } from "./config.js";
11
12
  function showTimeoutMs() {
12
13
  return envInt("OLLAMA_SHOW_TIMEOUT_MS", 30_000);
13
14
  }
14
15
  export function helpText() {
15
16
  return `Usage:
16
17
  ollanet show <machine> <model>
18
+ ollanet show <alias>
17
19
  ollanet show --machine <name> --model <name>
18
20
 
19
21
  Examples:
20
22
  ollanet show studio gemma4-ctx32k
23
+ ollanet show desk
21
24
  ollanet show localhost llama3.2:1b --json
22
25
 
23
26
  Reads /api/show on that host — Modelfile, parameters, capabilities.
24
27
  Tuned Finetuna-style names are marked [tuned].
28
+ A single alias name expands to that alias's machine + model.
25
29
 
26
30
  Options:
27
31
  --machine <name> Host (discovered name, MagicDNS, hostname, or IP[:port])
@@ -112,14 +116,20 @@ function printShow(result) {
112
116
  }
113
117
  export async function main() {
114
118
  const parsed = parseArgs(process.argv.slice(2));
115
- if (!parsed.machine || !parsed.model) {
116
- if (!parsed.machine)
119
+ const config = await loadConfig();
120
+ const expanded = expandMachineModel(config, parsed.machine, parsed.model);
121
+ if (!expanded.machine || !expanded.model) {
122
+ if (!expanded.machine)
117
123
  console.error("Machine is required.");
118
124
  else
119
125
  console.error("Model is required.");
120
126
  usage();
121
127
  }
122
- const result = await showModel({ machine: parsed.machine, model: parsed.model });
128
+ const result = await showModel({
129
+ machine: expanded.machine,
130
+ model: expanded.model,
131
+ config,
132
+ });
123
133
  if (parsed.json) {
124
134
  process.stdout.write(`${JSON.stringify(result, null, 2)}\n`);
125
135
  return;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "ollanet",
3
- "version": "0.6.3",
4
- "description": "Discover and talk to Ollama on any reachable network — CLI, MCP, and a Node library",
3
+ "version": "0.6.5",
4
+ "description": "Private Ollama operations for any reachable network — CLI for humans, MCP for agents, Node for apps",
5
5
  "type": "module",
6
6
  "bin": {
7
7
  "ollanet": "./dist/cli.js"
@@ -36,6 +36,7 @@
36
36
  "ps": "tsx src/cli.ts ps",
37
37
  "chats": "tsx src/cli.ts chats",
38
38
  "bench": "tsx src/cli.ts bench",
39
+ "alias": "tsx src/cli.ts alias",
39
40
  "mcp": "tsx src/cli.ts mcp",
40
41
  "start": "tsx src/cli.ts scan",
41
42
  "typecheck": "tsc --noEmit",