@alejandroroman/agent-kit 0.1.0 → 0.1.1

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/chat.js CHANGED
@@ -11,8 +11,17 @@ const DATA_DIR = path.join(process.cwd(), "data");
11
11
  const SKILLS_DIR = path.join(process.cwd(), "skills");
12
12
  export async function chat(agentName) {
13
13
  if (!agentName) {
14
- console.error("Usage: agent-kit chat <agent>");
15
- process.exit(1);
14
+ const config = loadConfig(CONFIG_PATH);
15
+ const names = Object.keys(config.agents);
16
+ if (names.length === 1) {
17
+ agentName = names[0];
18
+ }
19
+ else {
20
+ console.error("Usage: agent-kit chat <agent>");
21
+ if (names.length > 0)
22
+ console.error(`Available: ${names.join(", ")}`);
23
+ process.exit(1);
24
+ }
16
25
  }
17
26
  await resolveApiKey({ save: false });
18
27
  const config = loadConfig(CONFIG_PATH);
package/dist/cli/start.js CHANGED
@@ -34,9 +34,10 @@ export async function start() {
34
34
  dataDir: DATA_DIR,
35
35
  }, apiPort);
36
36
  // Build primary agent runtime (for REPL)
37
- const agentName = process.argv[3] ?? DEFAULT_AGENT;
37
+ const agentNames = Object.keys(config.agents);
38
+ const agentName = process.argv[3] ?? (agentNames.length === 1 ? agentNames[0] : DEFAULT_AGENT);
38
39
  if (!config.agents[agentName]) {
39
- const names = Object.keys(config.agents).join(", ");
40
+ const names = agentNames.join(", ");
40
41
  console.error(`Agent "${agentName}" not found. Available: ${names}`);
41
42
  process.exit(1);
42
43
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alejandroroman/agent-kit",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "exports": {