|
1 | 1 | --- |
2 | 2 | name: docshark |
3 | | -description: Use when answering framework, library, SDK, or API documentation questions with DocShark MCP tools. Use for indexed-doc lookup, full-page retrieval, and library lifecycle operations. |
| 3 | +description: Use when answering framework, library, SDK, or API documentation questions with DocShark MCP tools, especially for indexed-doc search, full-page retrieval, and library lifecycle tasks. |
4 | 4 | --- |
5 | 5 |
|
6 | 6 | # DocShark MCP Usage |
7 | 7 |
|
8 | | -## Overview |
| 8 | +Use DocShark in this exact order: |
9 | 9 |
|
10 | | -Use DocShark as a tool-first docs workflow. Keep answers grounded in tool output, not model memory. |
| 10 | +1. `list_libraries` if coverage is unknown. |
| 11 | +2. `search_docs` for primary lookup (natural language queries). |
| 12 | +3. `get_doc_page` only when snippet context is not enough. |
| 13 | +4. `manage_library` for lifecycle operations. |
11 | 14 |
|
12 | | -## Use These Tools |
| 15 | +## Current Tool Contract |
13 | 16 |
|
14 | | -- `list_libraries` - discover what is indexed. |
15 | | -- `search_docs` - primary natural-language search. |
16 | | -- `search_docs_batch` - multiple related queries in one call. |
17 | | -- `get_doc_page` - fetch full markdown for one page. |
18 | | -- `manage_library` - lifecycle actions: `add`, `rename`, `refresh`, `remove`, `info`. |
| 17 | +- Read/search: |
| 18 | + - `list_libraries` |
| 19 | + - `search_docs` |
| 20 | + - `search_docs_batch` |
| 21 | + - `get_doc_page` |
| 22 | +- Lifecycle: |
| 23 | + - `manage_library` with `action` in `add | rename | refresh | remove | info` |
19 | 24 |
|
20 | | -Important: do not call `add_library`, `refresh_library`, or `remove_library`; those are not current tool names. |
| 25 | +Do not call deprecated/nonexistent tool names such as `add_library`, `refresh_library`, or `remove_library`. |
21 | 26 |
|
22 | | -## Default Flow |
| 27 | +## manage_library Required Inputs |
23 | 28 |
|
24 | | -1. Call `list_libraries` if library coverage is unknown. |
25 | | -2. Call `search_docs` with a natural-language query. |
26 | | -3. Call `get_doc_page` only when snippet context is insufficient. |
27 | | -4. If docs are missing or stale, call `manage_library` with the correct `action`. |
| 29 | +- `add`: `url` (optional `name`, `version`, `max_depth`) |
| 30 | +- `refresh`: `library` |
| 31 | +- `remove`: `library` |
| 32 | +- `info`: `library` |
| 33 | +- `rename`: `current_name`, `new_name` |
28 | 34 |
|
29 | | -## manage_library Quick Guide |
| 35 | +## Query Style |
30 | 36 |
|
31 | | -- Add docs: |
32 | | - - `action: "add"` |
33 | | - - required: `url` |
34 | | - - optional: `name`, `version`, `max_depth` |
35 | | -- Refresh docs: |
36 | | - - `action: "refresh"` |
37 | | - - required: `library` |
38 | | -- Remove docs: |
39 | | - - `action: "remove"` |
40 | | - - required: `library` |
41 | | -- Inspect one library: |
42 | | - - `action: "info"` |
43 | | - - required: `library` |
44 | | -- Rename library: |
45 | | - - `action: "rename"` |
46 | | - - required: `current_name`, `new_name` |
| 37 | +- Use natural language: `SvelteKit form actions redirect after submit` |
| 38 | +- Avoid keyword fragments: `sveltekit form redirect` |
47 | 39 |
|
48 | | -## Query Patterns |
| 40 | +## Output Rules |
49 | 41 |
|
50 | | -Use natural language, not keyword fragments. |
51 | | - |
52 | | -- Good: `SvelteKit form actions redirect after submit` |
53 | | -- Good: `TanStack Query cache invalidation guidance` |
54 | | -- Weak: `sveltekit form redirect` |
55 | | - |
56 | | -## Response Rules |
57 | | - |
58 | | -- Cite what DocShark returned. |
59 | | -- If no results, say so and refine query or library scope. |
60 | | -- If library is missing, state that and use `manage_library` `action: "add"`. |
| 42 | +- Ground answers in tool output. |
| 43 | +- If nothing is found, say so and refine query/filter. |
| 44 | +- If a library is missing, use `manage_library` with `action: "add"`. |
0 commit comments