|
1 | | -<p align="center"> |
2 | | - <img src="docs/images/cover.png" alt="Lovcode Cover" width="100%"> |
3 | | -</p> |
4 | | - |
5 | 1 | <h1 align="center"> |
6 | | - <img src="assets/logo.svg" width="32" height="32" alt="Logo" align="top"> |
7 | | - Lovcode |
| 2 | + <img src="assets/logo.svg" width="32" height="32" alt="Ataru" align="top"> |
| 3 | + Ataru |
8 | 4 | </h1> |
9 | 5 |
|
10 | 6 | <p align="center"> |
11 | | - <strong>I came, I saw, I conquered. / 我来,我见,我征服。</strong><br> |
12 | | - <sub>Desktop command table for Claude Code, Codex, terminal sessions, and local AI coding history</sub><br> |
| 7 | + <strong>Search the memory of your AI work.</strong><br> |
| 8 | + <sub>用关键词或自然语言,快速、准确地找回过去的 AI 对话。</sub><br> |
13 | 9 | <sub>macOS • Windows • Linux</sub> |
14 | 10 | </p> |
15 | 11 |
|
|
20 | 16 | <img src="https://img.shields.io/badge/License-Apache_2.0-green" alt="License"> |
21 | 17 | </p> |
22 | 18 |
|
23 | | ---- |
24 | | - |
25 | | -<p align="center"> |
26 | | - <a href="https://code.lovstudio.ai/">Website</a> • |
27 | | - <a href="#overview">Overview</a> • |
28 | | - <a href="#features">Features</a> • |
29 | | - <a href="#documentation">Docs</a> • |
30 | | - <a href="#installation">Installation</a> • |
31 | | - <a href="#usage">Usage</a> • |
32 | | - <a href="#development">Development</a> • |
33 | | - <a href="#tech-stack">Tech Stack</a> • |
34 | | - <a href="#release-notes">Release Notes</a> |
35 | | -</p> |
| 19 | +## Ataru 是什么 |
36 | 20 |
|
37 | | ---- |
| 21 | +Ataru 是一个 local-first 的 AI 对话记忆搜索器。它把 Claude Code、Codex 等工具散落在本机的聊天记录建立为统一索引,并按三个真正有用的层级召回: |
38 | 22 |
|
39 | | -## Overview |
| 23 | +- **Turn**:直接找回包含答案的一轮问答。 |
| 24 | +- **Session**:把多个命中归并到一段完整会话。 |
| 25 | +- **Project**:跨会话回看一个项目讨论过什么、如何演进。 |
40 | 26 |
|
41 | | -Lovcode is an open-source desktop app for developers who work with multiple AI coding tools. It brings Claude Code, Codex, terminal sessions, local chat history, linked files, runtime configuration, commands, MCP servers, skills, hooks, and MaaS providers into one local command table. |
| 27 | +Ataru 的北极星指标是 **TTCR(Time to Correct Recall)**:从开始输入,到用户确认“就是这条”的时间。关键词检索保持离线可用;自然语言检索在语义索引可用时采用混合召回,失败时降级到关键词结果。 |
42 | 28 |
|
43 | | -The goal is simple: arrive at the right project, see the full context, and resume or hand off work without digging through scattered terminals and exports. |
| 29 | +## 与 Yoda 的关系 |
44 | 30 |
|
45 | | - |
| 31 | +| 产品 | 负责的问题 | |
| 32 | +|---|---| |
| 33 | +| **Ataru** | 过去聊过什么,答案和上下文在哪里? | |
| 34 | +| **Yoda Agent Workspace** | 现在由哪个 Agent 继续做,如何执行与交付? | |
46 | 35 |
|
47 | | -## Workflow |
| 36 | +每条 Ataru 结果都保留原始 project、session、turn 和 message 定位信息。确认上下文后,可以直接在 Yoda 中继续,而不是把 Ataru 重新做成一套 Agent 工作台。 |
48 | 37 |
|
49 | | -| Step | Lovcode keeps close | |
50 | | -|------|---------------------| |
51 | | -| **I came** | Project paths, agent runtimes, setup scripts, and session launch controls | |
52 | | -| **I saw** | Searchable histories, tool calls, linked files, usage details, and structured traces | |
53 | | -| **I conquered** | Resume actions, cross-agent handoff prompts, archived context, and release-ready records | |
54 | | -| **我来** | 项目目录、运行时、启动脚本和 Agent 入口 | |
55 | | -| **我见** | 可搜索历史、工具调用、关联文件和结构化上下文 | |
56 | | -| **我征服** | 可续接会话、跨 Agent 交接、归档记录和交付线索 | |
| 38 | +## 产品能力 |
57 | 39 |
|
58 | | -## Features |
| 40 | +- 中文友好的 Tantivy + Jieba 全文索引,支持技术名词、域名和字段查询。 |
| 41 | +- 自然语言查询、可选语义向量索引,以及关键词/语义的可解释混合排序。 |
| 42 | +- Turn、Session、Project 后端聚合,避免前端只对截断结果做二次猜测。 |
| 43 | +- 命中片段、原始会话上下文预览、message/line/turn 精确定位。 |
| 44 | +- 本地索引状态、增量刷新和清晰的语义降级提示。 |
| 45 | +- 一键将代表会话交给 Yoda 继续处理。 |
59 | 46 |
|
60 | | -### Workbench |
| 47 | +## 架构 |
61 | 48 |
|
62 | | -- Launch Claude Code, Codex, terminal, or general chat sessions from a selected project. |
63 | | -- Keep project/session setup, cleanup, and custom runtime scripts available in the embedded terminal dock. |
64 | | -- Track pinned, archived, unread, review, runtime, and display-mode state across sessions. |
65 | | -- Duplicate windows, resume sessions, and copy project path actions from the workbench. |
| 49 | +Ataru 目前采用模块化单体,先稳定边界和检索质量,再决定哪些模块需要独立发布: |
66 | 50 |
|
67 | | -### History and Search |
| 51 | +| 模块 | 职责 | |
| 52 | +|---|---| |
| 53 | +| `sdk` | `SearchRequest/Response/Hit`、稳定实体 ID、层级聚合与排名信号 | |
| 54 | +| `api` | 版本化 Tauri/CLI 入口、模式编排、时限、降级与兼容适配 | |
| 55 | +| `ai` | 查询意图、模式决策与 RRF 融合;现有语义存储暂由兼容适配器承接 | |
| 56 | +| `desktop` | 搜索输入、结果验证、只读上下文与 Yoda handoff | |
68 | 57 |
|
69 | | -- Browse Claude Code, Codex, app-code, app-web, and app-cowork histories from one viewer. |
70 | | -- Search full text, session IDs, metadata, and details with Chinese-aware indexing. |
71 | | -- Index active and archived Codex session files, including dotted tokens such as domains, package names, and asset names. |
72 | | -- Inspect tool calls, thinking blocks, grouped results, generated images, and token/cost context. |
| 58 | +详细设计见: |
73 | 59 |
|
74 | | -### Files and Context |
| 60 | +- [ADR-0001:采用模块化单体重构 Ataru](docs/adr/0001-ataru-search-modular-monolith.md) |
| 61 | +- [Ataru 搜索架构](docs/architecture/ataru-search-architecture.md) |
| 62 | +- [Warm Academic 设计规范](docs/design-guide.md) |
75 | 63 |
|
76 | | -- Open local paths from prompts, markdown links, and agent output directly inside Lovcode. |
77 | | -- Preview UTF-8 text, Markdown, images, directories, ZIP archives, and unsupported binary fallbacks. |
78 | | -- Jump to line/column references and route unresolved agent paths through candidate prefixes. |
79 | | -- Copy session information, related files, trace context, and handoff prompts for Claude Code or Codex. |
| 64 | +## 兼容策略 |
80 | 65 |
|
81 | | -### Configuration |
| 66 | +Ataru 从 Lovcode 演进而来。第一阶段只切换用户可见品牌与主路径,继续保留以下存量契约: |
82 | 67 |
|
83 | | -- Manage commands, MCP servers, skills, hooks, sub-agents, output styles, runtime environments, and MaaS providers. |
84 | | -- Configure Claude Code and Codex runtimes, inspect install/version status, and keep runtime preferences local. |
85 | | -- Activate MaaS providers separately for Claude Code and Codex with vendor/model metadata and token verification. |
86 | | -- Browse marketplace templates and installed skills with sorting, filtering, previews, and token estimates. |
| 68 | +- `lovcode` npm/Rust package、CLI 命令与 GitHub release 资产。 |
| 69 | +- `app.lovpen.code` bundle identifier 和现有 updater endpoint。 |
| 70 | +- `lovcode:*` 本地存储键、`LOVCODE_*` 环境变量及旧数据/索引目录。 |
| 71 | +- 已有 Tauri commands、JSON 字段及 Yoda stable mapping ID。 |
87 | 72 |
|
88 | | -### App Surface |
| 73 | +这些兼容项会通过别名或双读迁移逐步收口,避免一次改名让旧历史、升级通道或 Yoda 映射失效。 |
89 | 74 |
|
90 | | -- Localized interface for English, Chinese, and system language. |
91 | | -- In-app update checks, release history, auto-update controls, and direct release links. |
92 | | -- Authenticated Lovstudio feedback tickets with tags, ticket IDs, and admin review tooling. |
| 75 | +## 使用 |
93 | 76 |
|
94 | | -## Documentation |
| 77 | +1. 启动 Ataru,首页会读取本地会话快照并检查搜索索引。 |
| 78 | +2. 输入关键词,或描述你记得的问题、决策与上下文。 |
| 79 | +3. 在 Turn、Session、Project 之间切换,选择最合适的召回粒度。 |
| 80 | +4. 在右侧核对原始上下文;需要继续工作时选择 **在 Yoda 中继续**。 |
95 | 81 |
|
96 | | -Project documentation that does not need to live in the repository root is kept under `docs/`. |
97 | | - |
98 | | -- [Proxy configuration](docs/proxy-configuration.md) |
99 | | -- [Product requirements](docs/prd-parallel-vibe-coding.md) |
100 | | -- [Warm Academic design guide](docs/design-guide.md) |
101 | | -- [OpenCode research index](docs/research/RESEARCH_INDEX.md) |
102 | | - |
103 | | -## oh-my-lovcode |
104 | | - |
105 | | -Community configuration framework for Lovcode, inspired by oh-my-zsh. |
| 82 | +既有兼容 CLI 仍可使用: |
106 | 83 |
|
107 | 84 | ```bash |
108 | | -curl -fsSL https://raw.githubusercontent.com/lovstudio/oh-my-lovcode/main/install.sh | bash |
109 | | -``` |
110 | | - |
111 | | -Share and discover statusbar themes, keybindings, and more at [oh-my-lovcode](https://github.com/lovstudio/oh-my-lovcode). |
| 85 | +lovcode search "search ranking" --json --limit 20 |
112 | 86 |
|
113 | | -## Installation |
114 | | - |
115 | | -Download the latest release for your platform from [Releases](https://github.com/lovstudio/lovcode/releases). |
116 | | - |
117 | | -Lovcode publishes desktop builds for macOS, Windows, and Linux when release workflows complete. |
118 | | - |
119 | | -## Usage |
120 | | - |
121 | | -1. Launch Lovcode. |
122 | | -2. Open **Workbench** and choose a project, runtime, setup script, and agent channel. |
123 | | -3. Start Claude Code, Codex, terminal, or general chat work from the selected context. |
124 | | -4. Use **History** and global search to find previous sessions across Claude Code, Codex, and app sources. |
125 | | -5. Open a session to inspect tool calls, thinking, linked files, generated images, and usage details. |
126 | | -6. Continue from the session footer, resume in a new agent, or copy handoff context. |
127 | | -7. Manage commands, MCP servers, skills, hooks, output styles, runtime settings, and MaaS providers under **Configuration**. |
| 87 | +# v1 Ataru 聚合契约;旧命令输出保持不变 |
| 88 | +lovcode search "search ranking" --json --level turn --limit 20 |
| 89 | +``` |
128 | 90 |
|
129 | | -## Development |
| 91 | +## 开发 |
130 | 92 |
|
131 | 93 | ```bash |
132 | | -# Clone the repository (with submodules) |
133 | | -git clone --recursive https://github.com/lovstudio/lovcode.git |
134 | | -cd lovcode |
135 | | - |
136 | | -# Install dependencies |
| 94 | +git clone --recursive https://github.com/lovstudio/Ataru.git |
| 95 | +cd Ataru |
137 | 96 | pnpm install |
138 | 97 |
|
139 | | -# Run full Tauri development with Rust watcher |
| 98 | +# Tauri + Vite 开发 |
140 | 99 | pnpm dev:app |
141 | 100 |
|
142 | | -# Frontend-focused development: Vite HMR stays on, Rust changes do not restart the app |
| 101 | +# 仅前端 HMR,Rust 进程不自动重启 |
143 | 102 | pnpm dev:app:no-watch |
144 | 103 |
|
145 | | -# Build for distribution |
| 104 | +# 发布构建 |
146 | 105 | pnpm tauri build |
147 | 106 | ``` |
148 | 107 |
|
149 | | -## Tech Stack |
150 | | - |
151 | | -| Layer | Technology | |
152 | | -|-------|------------| |
153 | | -| Frontend | React 19, TypeScript, Tailwind CSS, Vite | |
154 | | -| Backend | Rust, Tauri 2 | |
155 | | -| UI Components | shadcn/ui | |
156 | | -| State | Jotai | |
157 | | -| Search | Tantivy + jieba (full-text, Chinese-aware) | |
158 | | - |
159 | | -## Release Notes |
| 108 | +| 层 | 技术 | |
| 109 | +|---|---| |
| 110 | +| Desktop | Tauri 2 | |
| 111 | +| Frontend | React 19, TypeScript, Tailwind CSS, shadcn/ui | |
| 112 | +| Keyword Search | Tantivy, Jieba | |
| 113 | +| Semantic Search | OpenAI-compatible embeddings, LanceDB / SQLite fallback | |
| 114 | +| State | React Query, Jotai | |
160 | 115 |
|
161 | | -The README stays focused on the current product surface. Version-by-version details live in: |
| 116 | +## Release notes |
162 | 117 |
|
163 | 118 | - [CHANGELOG.md](CHANGELOG.md) |
164 | | -- [GitHub Releases](https://github.com/lovstudio/lovcode/releases) |
165 | | - |
166 | | -## Star History |
167 | | - |
168 | | -[](https://star-history.com/#lovstudio/lovcode&Date) |
| 119 | +- [GitHub Releases](https://github.com/lovstudio/Ataru/releases) |
169 | 120 |
|
170 | 121 | ## License |
171 | 122 |
|
|
0 commit comments