@letta-ai/letta-code 0.1.8 → 0.1.9
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 +28 -2
- package/letta.js +2934 -1364
- package/package.json +5 -3
package/README.md
CHANGED
|
@@ -10,6 +10,8 @@ https://github.com/user-attachments/assets/5561a3ff-afd9-42a9-8601-55d245946394
|
|
|
10
10
|
|
|
11
11
|
Letta Code is a command-line harness around the stateful Letta [Agents API](https://docs.letta.com/api-reference/overview). You can use Letta Code to create and connect with any Letta agent (even non-coding agents!) - Letta Code simply gives your agents the ability to interact with your local dev environment, directly in your terminal.
|
|
12
12
|
|
|
13
|
+
Letta Code is model agnostic, and supports Sonnet 4.5, GPT-5, Gemini 2.5, GLM-4.6, and more.
|
|
14
|
+
|
|
13
15
|
> [!IMPORTANT]
|
|
14
16
|
> Letta Code is a **research preview** in active development, and may have bugs or unexpected issues. To learn more about the roadmap and chat with the dev team, visit our [Discord](https:/discord.gg/letta). Contributions welcome, join the fun.
|
|
15
17
|
|
|
@@ -90,6 +92,30 @@ letta -p "run tests" --tools "Bash,Read" # Only load specific tools
|
|
|
90
92
|
letta -p "analyze code" --tools "" # No tools (analysis only)
|
|
91
93
|
```
|
|
92
94
|
|
|
95
|
+
Use `--output-format json` to get additional information, including the agent ID ("session_id"):
|
|
96
|
+
```bash
|
|
97
|
+
# regular text output
|
|
98
|
+
$ letta -p "hi there"
|
|
99
|
+
Hi! How can I help you today?
|
|
100
|
+
|
|
101
|
+
# structured output
|
|
102
|
+
$ letta -p "hi there" --output-format json
|
|
103
|
+
{
|
|
104
|
+
"type": "result",
|
|
105
|
+
"subtype": "success",
|
|
106
|
+
"is_error": false,
|
|
107
|
+
"duration_ms": 5454,
|
|
108
|
+
"duration_api_ms": 2098,
|
|
109
|
+
"num_turns": 1,
|
|
110
|
+
"result": "Hi! How can I help you today?",
|
|
111
|
+
"session_id": "agent-8ab431ca-63e0-4ca1-ba83-b64d66d95a0f",
|
|
112
|
+
"usage": {
|
|
113
|
+
"input_tokens": 294,
|
|
114
|
+
"output_tokens": 97
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
```
|
|
118
|
+
|
|
93
119
|
### Permissions
|
|
94
120
|
|
|
95
121
|
**Tool selection** (controls which tools are loaded):
|
|
@@ -135,8 +161,8 @@ First, install Bun if you don't have it yet: [https://bun.com/docs/installation]
|
|
|
135
161
|
bun install
|
|
136
162
|
|
|
137
163
|
# run the CLI from TypeScript sources (pick up changes immediately)
|
|
138
|
-
bun run dev
|
|
139
|
-
bun run dev
|
|
164
|
+
bun run dev
|
|
165
|
+
bun run dev -- -p "Hello world" # example with args
|
|
140
166
|
```
|
|
141
167
|
|
|
142
168
|
### Build + link the standalone binary
|