botholomew 0.8.3 → 0.8.4
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 +23 -12
- package/package.json +2 -2
- package/src/config/loader.ts +3 -0
- package/src/config/schemas.ts +2 -0
- package/src/utils/logger.ts +47 -3
package/README.md
CHANGED
|
@@ -8,15 +8,17 @@
|
|
|
8
8
|
|
|
9
9
|

|
|
10
10
|
|
|
11
|
-
**
|
|
11
|
+
**An AI agent for knowledge work.** Botholomew is an autonomous agent
|
|
12
12
|
that works its way through a task queue — reading email, summarizing
|
|
13
13
|
documents, researching topics, organizing notes, and maintaining context
|
|
14
14
|
over time — while you sleep, work, or chat with it.
|
|
15
15
|
|
|
16
|
-
Unlike coding agents, Botholomew has **no shell
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
16
|
+
Unlike coding agents, Botholomew has **no shell and no direct access to
|
|
17
|
+
your filesystem**. It can't edit files on disk — instead, it ingests local
|
|
18
|
+
files, folders, and URLs into a DuckDB-backed context store that it can
|
|
19
|
+
read, search, and summarize. External capabilities (email, Slack, the web,
|
|
20
|
+
and hundreds of other services) are granted deliberately, per project,
|
|
21
|
+
through MCP servers wired up via [MCPX](https://github.com/evantahler/mcpx).
|
|
20
22
|
|
|
21
23
|
---
|
|
22
24
|
|
|
@@ -27,19 +29,19 @@ is granted deliberately, per project, through MCP servers.
|
|
|
27
29
|
long-running `--persist` worker, or point cron at `botholomew worker run`.
|
|
28
30
|
- **Portable.** Each project is a `.botholomew/` directory — markdown +
|
|
29
31
|
DuckDB. Copy it, share it, check it in (or `.gitignore` it).
|
|
30
|
-
- **
|
|
31
|
-
|
|
32
|
-
and OpenAI
|
|
32
|
+
- **Your data, your disk.** Project state — tasks, threads, ingested
|
|
33
|
+
context, embeddings — lives in `.botholomew/`, indexed in DuckDB with
|
|
34
|
+
HNSW for vector search. Model calls go direct to Anthropic and OpenAI;
|
|
35
|
+
any further reach is scoped to the MCP servers you add.
|
|
33
36
|
- **Extensible.** External tools come from MCP servers via
|
|
34
37
|
[MCPX](https://github.com/evantahler/mcpx) — run them locally (Gmail,
|
|
35
38
|
Slack, GitHub) or connect through an MCP gateway like
|
|
36
39
|
[Arcade.dev](https://www.arcade.dev/) to reach hundreds of
|
|
37
40
|
authenticated services without managing each server yourself.
|
|
38
41
|
Reusable workflows are defined as markdown "skills" (slash commands).
|
|
39
|
-
- **Safe by default.** The agent has no shell
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
explicitly add.
|
|
42
|
+
- **Safe by default.** The agent has no shell and no direct filesystem
|
|
43
|
+
access. Out of the box, everything it can touch lives in `.botholomew/`;
|
|
44
|
+
every external capability is a MCP server you explicitly add.
|
|
43
45
|
- **Concurrent.** Many workers can run at once. Each registers itself in
|
|
44
46
|
the DB and heartbeats; crashed workers get reaped and their tasks go
|
|
45
47
|
back into the queue automatically.
|
|
@@ -49,6 +51,15 @@ is granted deliberately, per project, through MCP servers.
|
|
|
49
51
|
|
|
50
52
|
---
|
|
51
53
|
|
|
54
|
+
## Demo
|
|
55
|
+
|
|
56
|
+
A full tour of the chat TUI — every tab, slash-command autocomplete,
|
|
57
|
+
the message queue, tool-call visualization, and the live workers panel:
|
|
58
|
+
|
|
59
|
+

|
|
60
|
+
|
|
61
|
+
---
|
|
62
|
+
|
|
52
63
|
## Install
|
|
53
64
|
|
|
54
65
|
Requires [Bun](https://bun.sh) 1.1+.
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "botholomew",
|
|
3
|
-
"version": "0.8.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "0.8.4",
|
|
4
|
+
"description": "An autonomous AI agent for knowledge work — works your task queue while you sleep.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
7
7
|
"botholomew": "./src/cli.ts"
|
package/src/config/loader.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { getConfigPath } from "../constants.ts";
|
|
2
|
+
import { setLogLevel } from "../utils/logger.ts";
|
|
2
3
|
import { type BotholomewConfig, DEFAULT_CONFIG } from "./schemas.ts";
|
|
3
4
|
|
|
4
5
|
export async function loadConfig(
|
|
@@ -22,6 +23,8 @@ export async function loadConfig(
|
|
|
22
23
|
config.openai_api_key = process.env.OPENAI_API_KEY;
|
|
23
24
|
}
|
|
24
25
|
|
|
26
|
+
setLogLevel(config.log_level);
|
|
27
|
+
|
|
25
28
|
return config;
|
|
26
29
|
}
|
|
27
30
|
|
package/src/config/schemas.ts
CHANGED
|
@@ -15,6 +15,7 @@ export interface BotholomewConfig {
|
|
|
15
15
|
worker_stopped_retention_seconds?: number;
|
|
16
16
|
schedule_min_interval_seconds?: number;
|
|
17
17
|
schedule_claim_stale_seconds?: number;
|
|
18
|
+
log_level?: string;
|
|
18
19
|
}
|
|
19
20
|
|
|
20
21
|
export const DEFAULT_CONFIG: Required<BotholomewConfig> = {
|
|
@@ -34,4 +35,5 @@ export const DEFAULT_CONFIG: Required<BotholomewConfig> = {
|
|
|
34
35
|
worker_stopped_retention_seconds: 3600,
|
|
35
36
|
schedule_min_interval_seconds: 60,
|
|
36
37
|
schedule_claim_stale_seconds: 300,
|
|
38
|
+
log_level: "",
|
|
37
39
|
};
|
package/src/utils/logger.ts
CHANGED
|
@@ -4,34 +4,78 @@ function ts(): string {
|
|
|
4
4
|
return ansis.gray(new Date().toTimeString().slice(0, 8));
|
|
5
5
|
}
|
|
6
6
|
|
|
7
|
+
const LEVELS = {
|
|
8
|
+
silent: 0,
|
|
9
|
+
error: 1,
|
|
10
|
+
warn: 2,
|
|
11
|
+
info: 3,
|
|
12
|
+
debug: 4,
|
|
13
|
+
} as const;
|
|
14
|
+
|
|
15
|
+
type LogLevel = keyof typeof LEVELS;
|
|
16
|
+
|
|
17
|
+
function parseLevel(raw: string | undefined): number | undefined {
|
|
18
|
+
const key = raw?.toLowerCase();
|
|
19
|
+
if (key && key in LEVELS) return LEVELS[key as LogLevel];
|
|
20
|
+
return undefined;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
const envPinned = parseLevel(process.env.BOTHOLOMEW_LOG_LEVEL) !== undefined;
|
|
24
|
+
|
|
25
|
+
function defaultLevel(): number {
|
|
26
|
+
const explicit = parseLevel(process.env.BOTHOLOMEW_LOG_LEVEL);
|
|
27
|
+
if (explicit !== undefined) return explicit;
|
|
28
|
+
if (process.env.NODE_ENV === "test") return LEVELS.error;
|
|
29
|
+
return LEVELS.info;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
let currentLevel = defaultLevel();
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* Apply a log level from config. `BOTHOLOMEW_LOG_LEVEL` always wins, so
|
|
36
|
+
* this is a no-op when that env var is set. Empty/invalid values are
|
|
37
|
+
* ignored — callers can pass `config.log_level` directly without checking.
|
|
38
|
+
*/
|
|
39
|
+
export function setLogLevel(level: string | undefined): void {
|
|
40
|
+
if (envPinned) return;
|
|
41
|
+
const parsed = parseLevel(level);
|
|
42
|
+
if (parsed === undefined) return;
|
|
43
|
+
currentLevel = parsed;
|
|
44
|
+
}
|
|
45
|
+
|
|
7
46
|
export const logger = {
|
|
8
47
|
info(msg: string) {
|
|
48
|
+
if (currentLevel < LEVELS.info) return;
|
|
9
49
|
console.log(ts(), ansis.blue("ℹ"), msg);
|
|
10
50
|
},
|
|
11
51
|
|
|
12
52
|
success(msg: string) {
|
|
53
|
+
if (currentLevel < LEVELS.info) return;
|
|
13
54
|
console.log(ts(), ansis.green("✓"), msg);
|
|
14
55
|
},
|
|
15
56
|
|
|
16
57
|
warn(msg: string) {
|
|
58
|
+
if (currentLevel < LEVELS.warn) return;
|
|
17
59
|
console.log(ts(), ansis.yellow("⚠"), msg);
|
|
18
60
|
},
|
|
19
61
|
|
|
20
62
|
error(msg: string) {
|
|
63
|
+
if (currentLevel < LEVELS.error) return;
|
|
21
64
|
console.error(ts(), ansis.red("✗"), msg);
|
|
22
65
|
},
|
|
23
66
|
|
|
24
67
|
debug(msg: string) {
|
|
25
|
-
if (
|
|
26
|
-
|
|
27
|
-
}
|
|
68
|
+
if (currentLevel < LEVELS.debug) return;
|
|
69
|
+
console.log(ts(), ansis.gray("·"), ansis.gray(msg));
|
|
28
70
|
},
|
|
29
71
|
|
|
30
72
|
dim(msg: string) {
|
|
73
|
+
if (currentLevel < LEVELS.info) return;
|
|
31
74
|
console.log(ts(), ansis.dim(msg));
|
|
32
75
|
},
|
|
33
76
|
|
|
34
77
|
phase(name: string, detail?: string) {
|
|
78
|
+
if (currentLevel < LEVELS.info) return;
|
|
35
79
|
const tag = ansis.magenta.bold(`[[${name}]]`);
|
|
36
80
|
if (detail) {
|
|
37
81
|
console.log(ts(), tag, ansis.dim(detail));
|