refactor: remove IO route mapping, add HTTP API tests, system prompt update

This commit is contained in:
JianFeeeee
2026-07-02 15:47:16 +08:00
parent 885f3e3bc1
commit 8e051f5f63
25 changed files with 3427 additions and 110 deletions

View File

@ -216,6 +216,18 @@ func (s *Store) RecentDocs(n int) []*Doc {
return list
}
// Remove 从文档存储中删除指定 ID 的文档
func (s *Store) Remove(id string) {
s.mu.Lock()
defer s.mu.Unlock()
if _, ok := s.docs[id]; ok {
delete(s.docs, id)
s.vec.Remove(id)
s.dirty = true
}
}
// ——— internal ———
func (s *Store) loadAll() error {