You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
84 lines
3.1 KiB
Markdown
84 lines
3.1 KiB
Markdown
# OpenClaw EGP Plugin
|
|
|
|
RAG over Vietnamese government procurement documents (TBMT, KHLCNT, KQLCNT). Connects an OpenClaw agent to a running [`openclaw-egp-server`](https://git.pkhtech.com/vietnd11/openclaw-egp-server) instance via remote MCP.
|
|
|
|
## Install
|
|
|
|
```bash
|
|
openclaw plugins install git:git.pkhtech.com/vietnd11/openclaw-egp-plugin@v0.3.0
|
|
```
|
|
|
|
## Configure
|
|
|
|
Point the plugin at your `openclaw-egp-server` instance:
|
|
|
|
```bash
|
|
openclaw plugins config openclaw-egp set serverUrl=http://100.123.9.15:8000
|
|
openclaw plugins restart
|
|
```
|
|
|
|
The plugin reads `serverUrl` from its config; the agent connects to `{serverUrl}/mcp` for the 5 MCP tools below.
|
|
|
|
> **Note on MCP wiring.** OpenClaw's manifest schema does not currently declare a dedicated field for remote MCP server URLs. If `openclaw plugins inspect openclaw-egp --runtime` does not list the 5 tools after install, you may need to add an entry to the OpenClaw global config pointing the MCP runtime at `{serverUrl}/mcp`. See the [server repo's `/mcp` endpoint](https://git.pkhtech.com/vietnd11/openclaw-egp-server#mcp-endpoint) for the canonical URL.
|
|
|
|
## Capabilities
|
|
|
|
| Tool | Purpose |
|
|
|------|---------|
|
|
| `search_procurement_docs(query, limit?, entity_type?, entity_code?, mode?)` | Semantic search over the corpus |
|
|
| `list_entities(entity_type?, status?, limit?)` | Enumerate TBMT/KHLCNT/KQLCNT records |
|
|
| `describe_entity(entity_code)` | Metadata + file list for one entity |
|
|
| `fetch_raw_file_url(file_id)` | Public download URL for the original file |
|
|
| `entity_types_glossary()` | Static domain reference |
|
|
|
|
Each tool has an accompanying `SKILL.md` in `skills/` telling the agent **when** to use it. Skills are loaded automatically when the plugin is installed.
|
|
|
|
## Server requirements
|
|
|
|
The plugin depends on an `openclaw-egp-server` instance with:
|
|
|
|
- `/mcp` endpoint mounted (FastMCP Streamable HTTP transport).
|
|
- `/files/{id}/raw` endpoint for raw file download.
|
|
- `PUBLIC_BASE_URL` env var set to the externally-reachable URL (required for `fetch_raw_file_url`).
|
|
|
|
See the [server README](https://git.pkhtech.com/vietnd11/openclaw-egp-server#mcp-endpoint) for setup.
|
|
|
|
## Verify install
|
|
|
|
```bash
|
|
openclaw plugins inspect openclaw-egp --runtime
|
|
```
|
|
|
|
Expected: `openclaw-egp` enabled, 5 skills loaded, `serverUrl` shown as configured.
|
|
|
|
Then in chat, try:
|
|
|
|
> "Liệt kê các TBMT đã indexed"
|
|
|
|
The agent should call `list_entities(entity_type="tbmt", status="indexed")` and return a markdown table.
|
|
|
|
> **`entity_type` is case-sensitive and lowercase** (`tbmt` / `khlcnt` / `kqlcnt`). The server stores
|
|
> lowercase types and filters by exact match, so `entity_type="TBMT"` returns zero rows. Entity codes
|
|
> follow the eGP format `IB<digits>-<version>` (e.g. `IB2600250575-00`), not `TBMT-2026-001`.
|
|
|
|
## Update
|
|
|
|
```bash
|
|
openclaw plugins install git:git.pkhtech.com/vietnd11/openclaw-egp-plugin@v0.3.0
|
|
openclaw plugins restart
|
|
```
|
|
|
|
## Uninstall
|
|
|
|
```bash
|
|
openclaw plugins uninstall openclaw-egp
|
|
```
|
|
|
|
## Server repository
|
|
|
|
[openclaw-egp-server](https://git.pkhtech.com/vietnd11/openclaw-egp-server) — FastAPI app exposing `/mcp` (5 tools), `/files/{id}/raw`, plus the admin dashboard and ingestion pipeline.
|
|
|
|
## License
|
|
|
|
MIT — see [LICENSE](LICENSE).
|