docs: push Terms DB detail to terms-search skill; AGENTS.md keeps brief pointer
This commit is contained in:
@@ -16,9 +16,9 @@ Available: `translation`, `terms-search`, `translation-review`, `chinese-text-no
|
|||||||
|
|
||||||
## Terms Database
|
## Terms Database
|
||||||
|
|
||||||
- DB: `terms-search/termlib.duckdb`
|
See `terms-search` skill. Quick reference:
|
||||||
- CLI: `terms-search/search.py <query> [limit]` (preferred over HTTP)
|
- CLI: `terms-search/search.py <query> [limit]`
|
||||||
- Module: `from search import search; search("空性", limit=5, loc="...", src="...")` → list of `{zh, en, loc, source}` dicts
|
- Module: `from search import search; search("空性", limit=5, src="DoT定稿")`
|
||||||
- Priority: DoT定稿 > 内部特色词 > 佛教术语 > 经论名
|
- Priority: DoT定稿 > 内部特色词 > 佛教术语 > 经论名
|
||||||
|
|
||||||
## Directory Structure
|
## Directory Structure
|
||||||
|
|||||||
@@ -18,6 +18,18 @@ Server: `/home/user/documents/mpi/terms-search/server.py`
|
|||||||
|
|
||||||
Multi-word queries are ANDed. Searches both `zh` and `en` columns.
|
Multi-word queries are ANDed. Searches both `zh` and `en` columns.
|
||||||
|
|
||||||
|
## Python module
|
||||||
|
|
||||||
|
```python
|
||||||
|
import sys
|
||||||
|
sys.path.insert(0, '/home/user/documents/mpi/terms-search')
|
||||||
|
from search import search
|
||||||
|
results = search("空性", limit=5, src="DoT定稿")
|
||||||
|
# → list of {zh, en, loc, source} dicts
|
||||||
|
```
|
||||||
|
|
||||||
|
Use this inside `execute_code` scripts for batch lookups — no subprocess needed.
|
||||||
|
|
||||||
## HTTP API (use only when CLI is insufficient)
|
## HTTP API (use only when CLI is insufficient)
|
||||||
|
|
||||||
Start: `python3 /home/user/documents/mpi/terms-search/server.py` (port 8910)
|
Start: `python3 /home/user/documents/mpi/terms-search/server.py` (port 8910)
|
||||||
|
|||||||
Reference in New Issue
Block a user