mirror of
https://github.com/czl9707/build-your-own-openclaw.git
synced 2026-08-14 00:47:59 +00:00
docs(03-persistence): mention SQLite as an alternative backend (#26)
* docs(03-persistence): mention SQLite as an alternative backend * Update README with persistence options and SQLite note Clarify persistence options and mention SQLite as a potential upgrade for handling concurrent writers and richer queries. * Revise persistence options in README.zh.md Updated the section on persistence options to clarify the transition from file-based storage to database solutions like SQLite and Postgres. * Fix typos and enhance clarity in README.md Corrected spelling of 'Postgre' to 'Postgres' and improved clarity of the note about persistence. --------- Co-authored-by: Zane Chen <99708452+czl9707@users.noreply.github.com>
This commit is contained in:
co-authored by
Zane Chen
parent
169eb7e8cd
commit
37ae5dd255
@@ -46,6 +46,9 @@ class HistoryStore:
|
||||
"""Get all messages for a session."""
|
||||
```
|
||||
|
||||
## Note
|
||||
|
||||
The file-based store is deliberately simple, and it's still many agents handle persistence today. The persistence would naturally grow into a database solution as the project scale up. Sqlite, Postgres, you name them. This project already have the `HistoryStore` abstraction, building a more sophisticated persistence class should not be affect other pieces in this project.
|
||||
|
||||
## Try it out
|
||||
|
||||
|
||||
@@ -47,6 +47,10 @@ class HistoryStore:
|
||||
```
|
||||
|
||||
|
||||
## 持久化实现方式
|
||||
|
||||
基于文件的存储刻意保持简单,许多智能体仍然这样处理持久化。如果之后你需要扩展项目,数据库是一个自然的进阶选择。Sqlite,Postgres 等等。由于一切都通过 `HistoryStore` 接口进行,实现一个更加复杂的持久化方案不会影响项目的其他部分。
|
||||
|
||||
## 试一试
|
||||
|
||||
```bash
|
||||
|
||||
Reference in New Issue
Block a user