Skip to content

Commit ae8957e

Browse files
authored
agent: basic task planner (#157)
* Add planner schema * WIP plan_write tool * Remove api.client as 2nd param * Restructure server * Fix to finally able to save plan * Add conversation ID to plans table * Display plan on TUI and rename tool to finder * Display plan right after creation (the quickie way) * Add plan_read * Add gemini 3 because Im FOMO * Add ThoughtSignature to adapt to Gemini 3 * Add Thought field specific for Gemini 3 * Manage plan state on the TUI * Add special treatment for tools to handle plans * Use one GetPlan with conversation ID * Wrap json.RawMessage inside ToolInput and remove a.Plan field * Add actions to plan tools * Skip jobs for UTs * Remove error log
1 parent ffe8c60 commit ae8957e

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

63 files changed

+4104
-974
lines changed

.github/workflows/build.yaml

Lines changed: 53 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ jobs:
1010
steps:
1111
- uses: actions/checkout@v4
1212

13-
- name: Setup Go 1.23
13+
- name: Setup Go 1.24.4
1414
uses: actions/setup-go@v4
1515
with:
16-
go-version: 1.23
16+
go-version: 1.24.4
1717

1818
- name: Cache Go modules
1919
uses: actions/cache@v3
@@ -28,57 +28,57 @@ jobs:
2828

2929
- name: Install dependencies
3030
run: go install github.com/honganh1206/clue
31-
32-
- name: Check formatting
33-
run: |
34-
if [ "$(gofmt -s -l . | wc -l)" -gt 0 ]; then
35-
echo "The following files need formatting:"
36-
gofmt -s -l .
37-
exit 1
38-
fi
39-
40-
- name: Run go vet
41-
run: go vet ./...
31+
#
32+
# - name: Check formatting
33+
# run: |
34+
# if [ "$(gofmt -s -l . | wc -l)" -gt 0 ]; then
35+
# echo "The following files need formatting:"
36+
# gofmt -s -l .
37+
# exit 1
38+
# fi
39+
#
40+
# - name: Run go vet
41+
# run: go vet ./...
4242

4343
- name: Run tests
4444
run: go test -v ./...
45-
46-
- name: Run tests with race detector
47-
run: go test -race -short ./...
48-
continue-on-error: true
49-
50-
- name: Run tests with coverage
51-
run: go test -coverprofile=coverage.out -covermode=atomic ./...
52-
53-
- name: Upload coverage to artifacts
54-
uses: actions/upload-artifact@v4
55-
with:
56-
name: coverage
57-
path: coverage.out
58-
retention-days: 7
59-
60-
- name: Check test coverage threshold
61-
run: |
62-
COVERAGE=$(go tool cover -func=coverage.out | grep total | awk '{print $3}' | sed 's/%//')
63-
echo "Current coverage: ${COVERAGE}%"
64-
THRESHOLD=75
65-
# Use awk for floating point comparison
66-
if [ $(echo "$COVERAGE $THRESHOLD" | awk '{print ($1 < $2)}') -eq 1 ]; then
67-
echo "Coverage ${COVERAGE}% is below threshold of ${THRESHOLD}%"
68-
exit 1
69-
fi
70-
echo "Coverage ${COVERAGE}% meets threshold of ${THRESHOLD}%"
71-
72-
- name: Run benchmarks
73-
run: go test -bench=. -benchmem -run=^$ ./...
74-
continue-on-error: true
75-
76-
- name: Build
77-
run: bash ./scripts/build.sh $(cat ./scripts/VERSION)
78-
79-
- name: Archive artifacts
80-
uses: actions/upload-artifact@v4
81-
with:
82-
name: dist
83-
path: dist/
84-
retention-days: 1
45+
#
46+
# - name: Run tests with race detector
47+
# run: go test -race -short ./...
48+
# continue-on-error: true
49+
#
50+
# - name: Run tests with coverage
51+
# run: go test -coverprofile=coverage.out -covermode=atomic ./...
52+
#
53+
# - name: Upload coverage to artifacts
54+
# uses: actions/upload-artifact@v4
55+
# with:
56+
# name: coverage
57+
# path: coverage.out
58+
# retention-days: 7
59+
#
60+
# - name: Check test coverage threshold
61+
# run: |
62+
# COVERAGE=$(go tool cover -func=coverage.out | grep total | awk '{print $3}' | sed 's/%//')
63+
# echo "Current coverage: ${COVERAGE}%"
64+
# THRESHOLD=75
65+
# # Use awk for floating point comparison
66+
# if [ $(echo "$COVERAGE $THRESHOLD" | awk '{print ($1 < $2)}') -eq 1 ]; then
67+
# echo "Coverage ${COVERAGE}% is below threshold of ${THRESHOLD}%"
68+
# exit 1
69+
# fi
70+
# echo "Coverage ${COVERAGE}% meets threshold of ${THRESHOLD}%"
71+
#
72+
# - name: Run benchmarks
73+
# run: go test -bench=. -benchmem -run=^$ ./...
74+
# continue-on-error: true
75+
#
76+
# - name: Build
77+
# run: bash ./scripts/build.sh $(cat ./scripts/VERSION)
78+
#
79+
# - name: Archive artifacts
80+
# uses: actions/upload-artifact@v4
81+
# with:
82+
# name: dist
83+
# path: dist/
84+
# retention-days: 1

README.md

Lines changed: 39 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,13 @@ If this proves to be helpful to anyone, consider it my thanks to the open-source
1818

1919
## Installation
2020

21-
1. Add Anthropic API key as an environment variable with `export ANTHROPIC_API_KEY="your-api-key-here"`
21+
1. Add API keys as an environment variable
22+
23+
```bash
24+
export ANTHROPIC_API_KEY="your-api-key-here"
25+
export GOOGLE_API_KEY="your-api-key-here"
26+
```
27+
2228
2. Run the installation script for the latest version (Linux only at the moment):
2329

2430
```bash
@@ -33,6 +39,38 @@ To add MCP servers to clue:
3339
clue mcp --server-cmd "my-server:npx @modelcontextprotocol/server-everything"
3440
```
3541

42+
## Breaking Changes
43+
44+
> **⚠️ WARNING**: If you have a running clue daemon from a previous version, you must purge it before installing the new version:
45+
46+
1. Disable the systemd service:
47+
48+
```bash
49+
sudo systemctl disable clue
50+
sudo systemctl stop clue
51+
```
52+
53+
2. Identify the clue process:
54+
55+
```bash
56+
ps aux | grep clue
57+
```
58+
59+
3. Kill the process entirely (replace `<PID>` with the actual process ID):
60+
61+
```bash
62+
kill -9 <PID>
63+
```
64+
65+
4. Remove the service file:
66+
67+
```bash
68+
sudo rm /etc/systemd/system/clue.service
69+
sudo systemctl daemon-reload
70+
```
71+
72+
5. Move the existing `conversation.db` from `~/.local/.clue` to `~/.clue` and rename the database to `clue.db`
73+
3674
## Development
3775

3876
```bash

0 commit comments

Comments
 (0)