Skip to content

Commit af29782

Browse files
committed
Improve TUI demo: grep contrast, section headers, neovim opener
- Start with grep failing to find "handle errors", then vecgrep succeeding — shows semantic search value immediately - Show indexing as the first visible step (--clear-cache -l) - Add echo section headers between demo beats - Keep neovim opener step to showcase --open-cmd - End with CLI -l one-liner
1 parent f49ba84 commit af29782

3 files changed

Lines changed: 42 additions & 19 deletions

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@
33
.vecgrep/
44
!.vecgrep/config.toml
55
*.onnx
6+
.DS_Store

doc/demo.gif

1.37 MB
Loading

doc/demo.tape

Lines changed: 41 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -10,41 +10,59 @@ Set Shell zsh
1010
Set Theme "Catppuccin Mocha"
1111
Set TypingSpeed 50ms
1212

13-
# Beat 1: Clear cache and launch TUI with nvim opener
14-
Type "vecgrep --clear-cache && vecgrep -i 'streaming results'"
13+
Type "vecgrep --clear-cache -l 'creates index, first time only'"
14+
Enter
15+
Sleep 6s
16+
17+
# --- grep can't find it, vecgrep can ---
18+
Type "echo '--- normal grep matches exact text, not meaning (thus finds nothing in this example) ---'"
19+
Enter
20+
Sleep 1s
21+
Type "grep -rn 'handle errors' src/"
22+
Enter
23+
Sleep 1500ms
24+
25+
Type "echo '--- vecgrep searches by meaning (finds relevant parts of files) ---'"
26+
Enter
1527
Sleep 500ms
28+
Type "vecgrep 'handle errors' src/"
1629
Enter
30+
Sleep 3s
1731

18-
# Wait for model load + indexing
19-
Sleep 6s
32+
# --- Interactive TUI with live search ---
33+
Type "echo '--- interactive mode: search, browse, open in editor ---'"
34+
Enter
35+
Sleep 500ms
36+
Type "vecgrep -i 'cache invalidation'"
37+
Enter
38+
Sleep 2s
2039

21-
# Beat 2: Navigate results
40+
# Navigate results — preview follows selection
2241
Down
23-
Sleep 1s
42+
Sleep 800ms
2443
Down
25-
Sleep 1s
44+
Sleep 800ms
2645
Down
2746
Sleep 1500ms
2847

29-
# Beat 3: Change query
30-
Backspace 17
31-
Sleep 500ms
32-
Type "embedding"
48+
# Live re-search with a different query
49+
Backspace 20
50+
Type "how files are discovered"
3351
Sleep 3s
3452

35-
# Beat 4: Navigate new results
53+
# Browse new results
3654
Down
37-
Sleep 1s
55+
Sleep 800ms
3856
Down
3957
Sleep 1500ms
4058

41-
# Beat 5: Toggle preview
59+
# Toggle preview off and back
4260
Tab
43-
Sleep 1500ms
61+
Sleep 1200ms
4462
Tab
4563
Sleep 1500ms
4664

47-
# Beat 6: Open in nvim
65+
# --- Open result in neovim ---
4866
Enter
4967
Sleep 2s
5068
Up
@@ -54,11 +72,15 @@ Sleep 100ms
5472
Down
5573
Sleep 1s
5674

57-
# Beat 7: Exit nvim
75+
# Exit neovim
5876
Type ":q"
5977
Enter
6078
Sleep 1s
6179

62-
Type "vecgrep -q -l 'using config from files' ./src"
80+
# --- CLI one-liner: list matching files ---
81+
Type "echo '--- also works as a CLI tool, showing matching hunks or files ---'"
6382
Enter
64-
Sleep 2s
83+
Sleep 500ms
84+
Type "vecgrep -ql 'database schema' src/"
85+
Enter
86+
Sleep 3s

0 commit comments

Comments
 (0)