bl-log 0.2.10
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/LICENSE +21 -0
- package/README.md +113 -0
- package/dist/index.bun.d.ts +6 -0
- package/dist/index.bun.d.ts.map +1 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +42098 -0
- package/dist/l-log +0 -0
- package/dist/src/index.d.ts +9 -0
- package/dist/src/index.d.ts.map +1 -0
- package/dist/utils/cli.d.ts +6 -0
- package/dist/utils/cli.d.ts.map +1 -0
- package/dist/utils/const.d.ts +7 -0
- package/dist/utils/const.d.ts.map +1 -0
- package/dist/utils/files.d.ts +3 -0
- package/dist/utils/files.d.ts.map +1 -0
- package/dist/utils/git.d.ts +13 -0
- package/dist/utils/git.d.ts.map +1 -0
- package/dist/utils/visualizer.d.ts +31 -0
- package/dist/utils/visualizer.d.ts.map +1 -0
- package/package.json +53 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 llm-lean-log contributors
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
# bl-log (Bun CLI)
|
|
2
|
+
|
|
3
|
+
> Bun-only CLI tool for llm-lean-log - Logging for LLMs, but we cut the fat.
|
|
4
|
+
|
|
5
|
+
`llm-lean-log` is a format for logging that is optimized for LLM token usage, using a simple CSV-based structure.
|
|
6
|
+
|
|
7
|
+
For more information, see the [main repository](https://github.com/loclv/llm-lean-log).
|
|
8
|
+
|
|
9
|
+
## Requirements
|
|
10
|
+
|
|
11
|
+
- [Bun](https://bun.com) runtime (v1.3.5 or later)
|
|
12
|
+
|
|
13
|
+
## 🚀 Installation
|
|
14
|
+
|
|
15
|
+
```bash
|
|
16
|
+
bun add -g bl-log
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
## 💻 Usage
|
|
20
|
+
|
|
21
|
+
For LLMs viewing logs (default output is structured CSV):
|
|
22
|
+
|
|
23
|
+
```bash
|
|
24
|
+
# List all log entries (returns CSV, omits empty columns)
|
|
25
|
+
l-log list ./logs/example.csv
|
|
26
|
+
|
|
27
|
+
# Show statistics
|
|
28
|
+
l-log stats ./logs/example.csv
|
|
29
|
+
|
|
30
|
+
# View detailed entry at index (returns minimal CSV)
|
|
31
|
+
l-log view ./logs/example.csv 0
|
|
32
|
+
|
|
33
|
+
# View the last log entry
|
|
34
|
+
l-log view ./logs/example.csv --last
|
|
35
|
+
|
|
36
|
+
# Search logs (returns CSV)
|
|
37
|
+
l-log search ./logs/example.csv "query"
|
|
38
|
+
|
|
39
|
+
# Filter by tags (returns CSV)
|
|
40
|
+
l-log tags ./logs/example.csv tag1 tag2
|
|
41
|
+
|
|
42
|
+
# Add a new log entry
|
|
43
|
+
l-log add ./logs/example.csv "Fix bug" --tags=bug,fix --problem="Problem description"
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
For human users viewing logs:
|
|
47
|
+
|
|
48
|
+
```bash
|
|
49
|
+
# List all log entries
|
|
50
|
+
l-log list ./logs/example.csv --human
|
|
51
|
+
|
|
52
|
+
# Show statistics
|
|
53
|
+
l-log stats ./logs/example.csv --human
|
|
54
|
+
|
|
55
|
+
# View detailed entry at index
|
|
56
|
+
l-log view ./logs/example.csv 0 --human
|
|
57
|
+
|
|
58
|
+
# Search logs
|
|
59
|
+
l-log search ./logs/example.csv "query" --human
|
|
60
|
+
|
|
61
|
+
# Filter by tags
|
|
62
|
+
l-log tags ./logs/example.csv tag1 tag2 --human
|
|
63
|
+
|
|
64
|
+
# Add a new log entry
|
|
65
|
+
l-log add ./logs/example.csv "Fix bug" --tags=bug,fix --problem="Problem description"
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
## 🤖 Ask AI agent (LLMs) to write a log
|
|
69
|
+
|
|
70
|
+
> use l-log CLI to save chat log above
|
|
71
|
+
|
|
72
|
+
## Ask AI agent (LLMs) to read a log
|
|
73
|
+
|
|
74
|
+
> read last chat logs from "./logs/example.csv" and tell me what should I do next
|
|
75
|
+
|
|
76
|
+
Example LLMs's response:
|
|
77
|
+
|
|
78
|
+
```text
|
|
79
|
+
Based on the last entry in ./logs/example.csv and the current state of your repository, here is what you should do next:
|
|
80
|
+
|
|
81
|
+
### Current Status
|
|
82
|
+
|
|
83
|
+
The last task completed was "Make llm-lean-log packages public". This involved:
|
|
84
|
+
|
|
85
|
+
- Updating package.json for both llm-lean-log-core and l-log with repository info, files, and publishConfig.
|
|
86
|
+
- Adding LICENSE and README.md files.
|
|
87
|
+
- Configuring the CLI as an executable.
|
|
88
|
+
- Creating the guide at docs/public.md.
|
|
89
|
+
|
|
90
|
+
### Recommended Next Steps
|
|
91
|
+
|
|
92
|
+
1. Perform a Dry Run
|
|
93
|
+
Before pushing to NPM, ensure that the files being packaged are correct. Run this from the root:
|
|
94
|
+
|
|
95
|
+
...
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
## 📖 Additional information
|
|
99
|
+
|
|
100
|
+
This project was created using `bun init` in bun v1.3.5. [Bun](https://bun.com) is a fast all-in-one JavaScript runtime.
|
|
101
|
+
|
|
102
|
+
### 💻 Use with VS Code base editor
|
|
103
|
+
|
|
104
|
+
- Install recommended extensions from `.vscode/extensions.json`, which includes:
|
|
105
|
+
- `DavidAnson.vscode-markdownlint` - Markdown linting
|
|
106
|
+
- `biomejs.biome` - Code formatting and linting
|
|
107
|
+
- `oven-sh.bun` - Bun runtime support
|
|
108
|
+
- `jeff-hykin.better-csv-syntax` - CSV syntax highlighting (with color coding)
|
|
109
|
+
- `YoavBls.pretty-ts-errors` - Pretty TypeScript errors
|
|
110
|
+
|
|
111
|
+
## 📄 License
|
|
112
|
+
|
|
113
|
+
MIT
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.bun.d.ts","sourceRoot":"","sources":["../src/index.bun.ts"],"names":[],"mappings":";AAEA;;GAEG"}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAEA;;GAEG"}
|