create-bk-agent 0.15.0 → 0.16.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 CHANGED
@@ -26,13 +26,25 @@ Installing dependencies...
26
26
 
27
27
  ## Templates
28
28
 
29
- | Template | Use case |
30
- |----------|---------|
31
- | `coding` | Coding assistant — edit files, run commands, search code |
32
- | `domain-agent` | Multi-agent system — orchestrator + domain specialists |
33
- | `autonomous` | Autonomous agent — cron schedules, webhooks, events |
34
- | `mcp-server` | MCP server — expose tools via Model Context Protocol |
35
- | `minimal` | Bare engine — full control over everything |
29
+ ### `coding` — complete, ready to run
30
+ 10 specialized agents (backend, frontend, QA, security, architecture…) and all
31
+ coding tools (read/write files, run commands, git, search) are already configured.
32
+ Add your API key, describe your project in `AGENT.md`, and it works out of the box.
33
+ **Choose this when you want a coding assistant, not when you want to build one.**
34
+
35
+ ### `domain-agent` — blank multi-agent architecture
36
+ Orchestrator + specialists pattern with no pre-built agents or tools. You define
37
+ the agents and tools for your specific domain (Docker, AWS, databases, APIs, etc.).
38
+ The framework handles orchestration, delegation, and parallel execution.
39
+ **Choose this when you are building a new type of agent from scratch.**
40
+
41
+ | Template | What it gives you | You provide |
42
+ |----------|------------------|-------------|
43
+ | `coding` | 10 agents + all coding tools | API key + `AGENT.md` |
44
+ | `domain-agent` | Orchestration skeleton | Agents + tools for your domain |
45
+ | `autonomous` | Trigger system (cron / webhook / event) | Agent logic |
46
+ | `mcp-server` | MCP server boilerplate | Tools to expose |
47
+ | `minimal` | Bare engine | Everything |
36
48
 
37
49
  ## Providers
38
50
 
@@ -6,11 +6,11 @@ Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.askQuestions = askQuestions;
7
7
  const prompts_1 = __importDefault(require("prompts"));
8
8
  const TEMPLATES = [
9
- { title: 'coding', value: 'coding', description: 'Coding assistant — edit files, run commands, search code' },
10
- { title: 'domain-agent', value: 'domain-agent', description: 'Multi-agent — orchestrator + domain specialists (e.g. docker, AWS)' },
11
- { title: 'autonomous', value: 'autonomous', description: 'Autonomous — activates on cron schedules, webhooks, events' },
12
- { title: 'mcp-server', value: 'mcp-server', description: 'MCP server — expose tools via Model Context Protocol' },
13
- { title: 'minimal', value: 'minimal', description: 'Minimal — bare engine, full control over everything' },
9
+ { title: 'coding', value: 'coding', description: '10 agents + all coding tools included. Ready to run — improve UI and extend' },
10
+ { title: 'domain-agent', value: 'domain-agent', description: 'Blank multi-agent architecture. You define agents and tools for your domain' },
11
+ { title: 'autonomous', value: 'autonomous', description: 'Event-driven agent — cron schedules, webhooks, custom events' },
12
+ { title: 'mcp-server', value: 'mcp-server', description: 'MCP server — expose your tools to Claude Desktop / Cursor / VS Code' },
13
+ { title: 'minimal', value: 'minimal', description: 'Bare engine — full control, bring your own agents and tools' },
14
14
  ];
15
15
  const PROVIDERS = [
16
16
  { title: 'Anthropic (Claude)', value: 'anthropic', description: 'claude-sonnet-4-6 recommended' },
package/package.json CHANGED
@@ -1,33 +1,33 @@
1
- {
2
- "name": "create-bk-agent",
3
- "version": "0.15.0",
4
- "description": "Create a new BackendKit agent project",
5
- "main": "dist/src/index.js",
6
- "bin": {
7
- "create-bk-agent": "./dist/bin/create-bk-agent.js"
8
- },
9
- "files": [
10
- "dist/",
11
- "templates/"
12
- ],
13
- "repository": {
14
- "type": "git",
15
- "url": "https://github.com/BackendKit-labs/backendkit-agent-framework.git",
16
- "directory": "packages/create-bk-agent"
17
- },
18
- "publishConfig": { "access": "public" },
19
- "engines": { "node": ">=20.0.0" },
20
- "scripts": {
21
- "build": "tsc",
22
- "prepack": "node scripts/copy-templates.js && npm run build",
23
- "typecheck": "tsc --noEmit"
24
- },
25
- "dependencies": {
26
- "prompts": "^2.4.2"
27
- },
28
- "devDependencies": {
29
- "@types/node": "^20.0.0",
30
- "@types/prompts": "^2.4.9",
31
- "typescript": "^5.4.0"
32
- }
33
- }
1
+ {
2
+ "name": "create-bk-agent",
3
+ "version": "0.16.0",
4
+ "description": "Create a new BackendKit agent project",
5
+ "main": "dist/src/index.js",
6
+ "bin": {
7
+ "create-bk-agent": "./dist/bin/create-bk-agent.js"
8
+ },
9
+ "files": [
10
+ "dist/",
11
+ "templates/"
12
+ ],
13
+ "repository": {
14
+ "type": "git",
15
+ "url": "https://github.com/BackendKit-labs/backendkit-agent-framework.git",
16
+ "directory": "packages/create-bk-agent"
17
+ },
18
+ "publishConfig": { "access": "public" },
19
+ "engines": { "node": ">=20.0.0" },
20
+ "scripts": {
21
+ "build": "tsc",
22
+ "prepack": "node scripts/copy-templates.js && npm run build",
23
+ "typecheck": "tsc --noEmit"
24
+ },
25
+ "dependencies": {
26
+ "prompts": "^2.4.2"
27
+ },
28
+ "devDependencies": {
29
+ "@types/node": "^20.0.0",
30
+ "@types/prompts": "^2.4.9",
31
+ "typescript": "^5.4.0"
32
+ }
33
+ }
@@ -1,48 +1,42 @@
1
- import 'dotenv/config';
2
- import * as readline from 'readline';
3
- import { createCodingEngine } from '@backendkit-labs/agent-coding';
4
- import { CallbackTransport } from '@backendkit-labs/agent-core';
5
-
6
- // ── Provider setup ────────────────────────────────────────────────────────────
7
-
8
- const provider = process.env.LLM_PROVIDER ?? 'anthropic';
9
- const apiKey = process.env.ANTHROPIC_API_KEY ?? process.env.OPENAI_API_KEY ?? process.env.LLM_API_KEY ?? '';
10
- const model = process.env.LLM_MODEL;
11
-
12
- if (!apiKey) {
13
- console.error('Missing API key. Set ANTHROPIC_API_KEY or OPENAI_API_KEY in .env');
14
- process.exit(1);
15
- }
16
-
17
- // ── Engine ────────────────────────────────────────────────────────────────────
18
-
19
- const transport = new CallbackTransport((event) => {
20
- if (event.type === 'token') process.stdout.write(event.content);
21
- if (event.type === 'tool_call') console.log(`\n⚙ ${event.name}`);
22
- if (event.type === 'block_end') console.log();
23
- if (event.type === 'error') console.error(`\nError: ${event.message}`);
24
- });
25
-
26
- const engine = createCodingEngine({
27
- providers: { [provider]: { apiKey, ...(model ? { model } : {}) } },
28
- defaultProvider: provider,
29
- workingDir: process.cwd(),
30
- appName: 'my-coding-agent',
31
- transport,
32
- });
33
-
34
- // ── REPL ──────────────────────────────────────────────────────────────────────
35
-
36
- const rl = readline.createInterface({ input: process.stdin, output: process.stdout });
37
-
38
- function prompt() {
39
- rl.question('\n> ', async (input) => {
40
- const trimmed = input.trim();
41
- if (!trimmed || trimmed === '/exit') { rl.close(); return; }
42
- await engine.run(trimmed);
43
- prompt();
44
- });
45
- }
46
-
47
- console.log('Coding agent ready. Type your request or /exit to quit.\n');
48
- prompt();
1
+ import 'dotenv/config';
2
+ import * as readline from 'readline';
3
+ import { createCodingEngine, TerminalTransport } from '@backendkit-labs/agent-coding';
4
+
5
+ // ── Provider setup ────────────────────────────────────────────────────────────
6
+
7
+ const provider = process.env.LLM_PROVIDER ?? 'anthropic';
8
+ const apiKey = process.env.ANTHROPIC_API_KEY ?? process.env.OPENAI_API_KEY ?? process.env.LLM_API_KEY ?? '';
9
+ const model = process.env.LLM_MODEL;
10
+
11
+ if (!apiKey) {
12
+ console.error('Missing API key. Set ANTHROPIC_API_KEY or OPENAI_API_KEY in .env');
13
+ process.exit(1);
14
+ }
15
+
16
+ // ── Engine ────────────────────────────────────────────────────────────────────
17
+
18
+ const transport = new TerminalTransport();
19
+
20
+ const engine = createCodingEngine({
21
+ providers: { [provider]: { apiKey, ...(model ? { model } : {}) } },
22
+ defaultProvider: provider,
23
+ workingDir: process.cwd(),
24
+ appName: 'my-coding-agent',
25
+ transport,
26
+ });
27
+
28
+ // ── REPL ──────────────────────────────────────────────────────────────────────
29
+
30
+ const rl = readline.createInterface({ input: process.stdin, output: process.stdout });
31
+
32
+ function prompt() {
33
+ rl.question('\n❯ ', async (input) => {
34
+ const trimmed = input.trim();
35
+ if (!trimmed || trimmed === '/exit') { rl.close(); return; }
36
+ await engine.run(trimmed);
37
+ prompt();
38
+ });
39
+ }
40
+
41
+ console.log('Coding agent ready. Type your request or /exit to quit.\n');
42
+ prompt();