agentic-knowledge-mcp 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +674 -0
- package/README.md +530 -0
- package/package.json +94 -0
- package/packages/cli/dist/cli.d.ts +5 -0
- package/packages/cli/dist/cli.js +21 -0
- package/packages/cli/dist/commands/create.d.ts +5 -0
- package/packages/cli/dist/commands/create.js +90 -0
- package/packages/cli/dist/commands/init.d.ts +5 -0
- package/packages/cli/dist/commands/init.js +182 -0
- package/packages/cli/dist/commands/refresh.d.ts +5 -0
- package/packages/cli/dist/commands/refresh.js +322 -0
- package/packages/cli/dist/commands/status.d.ts +5 -0
- package/packages/cli/dist/commands/status.js +268 -0
- package/packages/cli/dist/index.d.ts +6 -0
- package/packages/cli/dist/index.js +6 -0
- package/packages/cli/package.json +57 -0
- package/packages/content-loader/dist/__tests__/debug-filtering.d.ts +1 -0
- package/packages/content-loader/dist/__tests__/debug-filtering.js +17 -0
- package/packages/content-loader/dist/__tests__/test-filtering.d.ts +1 -0
- package/packages/content-loader/dist/__tests__/test-filtering.js +19 -0
- package/packages/content-loader/dist/content/api-documentation-loader.d.ts +26 -0
- package/packages/content-loader/dist/content/api-documentation-loader.js +45 -0
- package/packages/content-loader/dist/content/content-processor.d.ts +44 -0
- package/packages/content-loader/dist/content/content-processor.js +86 -0
- package/packages/content-loader/dist/content/documentation-site-loader.d.ts +26 -0
- package/packages/content-loader/dist/content/documentation-site-loader.js +45 -0
- package/packages/content-loader/dist/content/git-repo-loader.d.ts +79 -0
- package/packages/content-loader/dist/content/git-repo-loader.js +368 -0
- package/packages/content-loader/dist/content/index.d.ts +9 -0
- package/packages/content-loader/dist/content/index.js +9 -0
- package/packages/content-loader/dist/content/loader.d.ts +47 -0
- package/packages/content-loader/dist/content/loader.js +8 -0
- package/packages/content-loader/dist/content/metadata-manager.d.ts +65 -0
- package/packages/content-loader/dist/content/metadata-manager.js +160 -0
- package/packages/content-loader/dist/index.d.ts +5 -0
- package/packages/content-loader/dist/index.js +5 -0
- package/packages/content-loader/dist/types.d.ts +127 -0
- package/packages/content-loader/dist/types.js +48 -0
- package/packages/content-loader/package.json +50 -0
- package/packages/core/dist/config/discovery.d.ts +15 -0
- package/packages/core/dist/config/discovery.js +65 -0
- package/packages/core/dist/config/loader.d.ts +22 -0
- package/packages/core/dist/config/loader.js +236 -0
- package/packages/core/dist/config/manager.d.ts +55 -0
- package/packages/core/dist/config/manager.js +180 -0
- package/packages/core/dist/content/api-documentation-loader.d.ts +26 -0
- package/packages/core/dist/content/api-documentation-loader.js +45 -0
- package/packages/core/dist/content/content-processor.d.ts +44 -0
- package/packages/core/dist/content/content-processor.js +81 -0
- package/packages/core/dist/content/documentation-site-loader.d.ts +26 -0
- package/packages/core/dist/content/documentation-site-loader.js +45 -0
- package/packages/core/dist/content/git-repo-loader.d.ts +54 -0
- package/packages/core/dist/content/git-repo-loader.js +264 -0
- package/packages/core/dist/content/index.d.ts +9 -0
- package/packages/core/dist/content/index.js +9 -0
- package/packages/core/dist/content/loader.d.ts +50 -0
- package/packages/core/dist/content/loader.js +7 -0
- package/packages/core/dist/content/metadata-manager.d.ts +65 -0
- package/packages/core/dist/content/metadata-manager.js +160 -0
- package/packages/core/dist/index.d.ts +12 -0
- package/packages/core/dist/index.js +30 -0
- package/packages/core/dist/paths/calculator.d.ts +46 -0
- package/packages/core/dist/paths/calculator.js +166 -0
- package/packages/core/dist/templates/processor.d.ts +40 -0
- package/packages/core/dist/templates/processor.js +111 -0
- package/packages/core/dist/types.d.ts +129 -0
- package/packages/core/dist/types.js +79 -0
- package/packages/core/package.json +50 -0
- package/packages/mcp-server/dist/bin.d.ts +5 -0
- package/packages/mcp-server/dist/bin.js +10 -0
- package/packages/mcp-server/dist/cli.d.ts +7 -0
- package/packages/mcp-server/dist/cli.js +17 -0
- package/packages/mcp-server/dist/index.d.ts +8 -0
- package/packages/mcp-server/dist/index.js +9 -0
- package/packages/mcp-server/dist/server.d.ts +35 -0
- package/packages/mcp-server/dist/server.js +244 -0
- package/packages/mcp-server/package.json +54 -0
package/README.md
ADDED
|
@@ -0,0 +1,530 @@
|
|
|
1
|
+
# 🧠 Agentic Knowledge
|
|
2
|
+
|
|
3
|
+
> **⚠️ WORK IN PROGRESS ⚠️**
|
|
4
|
+
> This project is under active development and not yet ready for production use. APIs may change without notice.
|
|
5
|
+
|
|
6
|
+
<div align="center">
|
|
7
|
+
<h3>The End of RAG. The Dawn of Agentic Search.</h3>
|
|
8
|
+
<p><em>Intelligent navigation instructions that guide AI assistants through documentation using filesystem-like exploration instead of traditional retrieval</em></p>
|
|
9
|
+
|
|
10
|
+
<a href="https://github.com/yourusername/agentic-knowledge/blob/main/LICENSE">
|
|
11
|
+
<img src="https://img.shields.io/github/license/yourusername/agentic-knowledge.svg?style=for-the-badge" alt="License" />
|
|
12
|
+
</a>
|
|
13
|
+
<a href="https://linkedin.com/in/yourusername">
|
|
14
|
+
<img src="https://img.shields.io/badge/-LinkedIn-black.svg?style=for-the-badge&logo=linkedin&colorB=555" alt="LinkedIn" />
|
|
15
|
+
</a>
|
|
16
|
+
</div>
|
|
17
|
+
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
## 🎯 What Is This?
|
|
21
|
+
|
|
22
|
+
**Agentic Knowledge** represents a fundamental paradigm shift away from traditional Retrieval-Augmented Generation (RAG) toward **agentic search patterns**. Instead of chunking documents, computing embeddings, and retrieving fragments, this system provides **intelligent navigation instructions** that leverage the AI agent's existing tools (grep, ripgrep, file reading) and the explosion of context windows.
|
|
23
|
+
|
|
24
|
+
### The Core Insight
|
|
25
|
+
|
|
26
|
+
Modern AI assistants are **context-rich** (200K+ tokens) and equipped with powerful filesystem tools. Rather than building complex search infrastructure, we can guide them to navigate documentation intelligently—just like Claude Code revolutionized code analysis by ditching RAG for direct filesystem exploration.
|
|
27
|
+
|
|
28
|
+
## 🪦 Why RAG is Dead
|
|
29
|
+
|
|
30
|
+
_Inspired by [The RAG Obituary](https://www.nicolasbustamante.com/p/the-rag-obituary-killed-by-agents) by Nicolas Bustamante_
|
|
31
|
+
|
|
32
|
+
Traditional RAG was a brilliant workaround for the **context-poor era** (GPT-4's 8K tokens). But it came with fundamental limitations:
|
|
33
|
+
|
|
34
|
+
### The RAG Problem Stack
|
|
35
|
+
|
|
36
|
+
```
|
|
37
|
+
❌ Chunking destroys document relationships
|
|
38
|
+
❌ Embeddings fail on precise terminology
|
|
39
|
+
❌ Similarity search misses exact matches
|
|
40
|
+
❌ Reranking adds latency and complexity
|
|
41
|
+
❌ Context fragmentation loses coherence
|
|
42
|
+
❌ Infrastructure burden is massive
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
### The Agentic Solution
|
|
46
|
+
|
|
47
|
+
```
|
|
48
|
+
✅ Direct filesystem navigation
|
|
49
|
+
✅ Intelligent reference following
|
|
50
|
+
✅ Complete document context
|
|
51
|
+
✅ Zero infrastructure overhead
|
|
52
|
+
✅ Sub-10ms response times
|
|
53
|
+
✅ Deterministic, precise results
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
## 🔄 From Retrieval to Navigation
|
|
57
|
+
|
|
58
|
+
Traditional RAG says: _"Here are 50 fragments that mention your keywords"_
|
|
59
|
+
|
|
60
|
+
Agentic Knowledge says: _"Search for 'useState' in `./docs/react-18.2/hooks/`. If that doesn't help, try 'state management' in `./docs/patterns/`. Follow any 'See also' references you find."_
|
|
61
|
+
|
|
62
|
+
The difference? **Guidance over fragments. Investigation over retrieval.**
|
|
63
|
+
|
|
64
|
+
## 🏗 How It Works
|
|
65
|
+
|
|
66
|
+
### MCP Server Integration
|
|
67
|
+
|
|
68
|
+
Implements the [Model Context Protocol](https://modelcontextprotocol.io/) with two core tools:
|
|
69
|
+
|
|
70
|
+
```typescript
|
|
71
|
+
// Get navigation guidance for specific queries
|
|
72
|
+
search_docs({
|
|
73
|
+
docset: "react-docs",
|
|
74
|
+
keywords: ["useEffect", "cleanup"],
|
|
75
|
+
generalized_keywords: ["lifecycle", "memory"],
|
|
76
|
+
});
|
|
77
|
+
|
|
78
|
+
// Discover available documentation sets
|
|
79
|
+
list_docsets();
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
### Configuration-Driven Intelligence
|
|
83
|
+
|
|
84
|
+
Simple `.knowledge/config.yaml` pattern:
|
|
85
|
+
|
|
86
|
+
```yaml
|
|
87
|
+
version: "1.0"
|
|
88
|
+
docsets:
|
|
89
|
+
- id: react-docs
|
|
90
|
+
name: React Documentation
|
|
91
|
+
description: "React framework documentation"
|
|
92
|
+
sources:
|
|
93
|
+
- type: local_folder
|
|
94
|
+
paths: ["./docs/react-18.2"]
|
|
95
|
+
template: |
|
|
96
|
+
Search for '{{keywords}}' in {{local_path}}/hooks/.
|
|
97
|
+
If not found, try '{{generalized_keywords}}' in {{local_path}}/patterns/.
|
|
98
|
+
Follow any cross-references you discover.
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
### The Navigation Response
|
|
102
|
+
|
|
103
|
+
Instead of document fragments, you get **actionable instructions**:
|
|
104
|
+
|
|
105
|
+
```
|
|
106
|
+
Based on your React useEffect cleanup query:
|
|
107
|
+
|
|
108
|
+
1. Start with `./docs/react-18.2/hooks/effect.md` - contains useEffect fundamentals
|
|
109
|
+
2. Search for "cleanup function" patterns in `./docs/react-18.2/patterns/`
|
|
110
|
+
3. Check `./examples/lifecycle/` for practical cleanup implementations
|
|
111
|
+
4. Review `./docs/react-18.2/performance/memory.md` for memory leak prevention
|
|
112
|
+
|
|
113
|
+
Focus on the cleanup function return pattern and dependency array management.
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
## 🚀 Why This Matters
|
|
117
|
+
|
|
118
|
+
### The Context Revolution
|
|
119
|
+
|
|
120
|
+
- **2022**: GPT-4 had 8K tokens (~12 pages)
|
|
121
|
+
- **2025**: Claude Sonnet has 200K tokens (~700 pages)
|
|
122
|
+
- **Future**: Heading toward 2M+ tokens (~6,000 pages)
|
|
123
|
+
|
|
124
|
+
### The Tool Evolution
|
|
125
|
+
|
|
126
|
+
AI assistants now have sophisticated filesystem tools:
|
|
127
|
+
|
|
128
|
+
- **Grep/Ripgrep**: Lightning-fast regex search through files
|
|
129
|
+
- **Glob**: Direct file discovery by patterns
|
|
130
|
+
- **Direct File Access**: Read complete documents in context
|
|
131
|
+
- **Reference Following**: Navigate cross-references naturally
|
|
132
|
+
|
|
133
|
+
### The Infrastructure Shift
|
|
134
|
+
|
|
135
|
+
- **RAG**: Elasticsearch clusters, embedding models, rerankers, vector databases
|
|
136
|
+
- **Agentic**: Simple YAML config, zero infrastructure, filesystem tools
|
|
137
|
+
|
|
138
|
+
## 🎯 Core Principles
|
|
139
|
+
|
|
140
|
+
### 1. **Guidance Over Search**
|
|
141
|
+
|
|
142
|
+
Provide intelligent navigation instructions instead of search results
|
|
143
|
+
|
|
144
|
+
### 2. **Context Abundance**
|
|
145
|
+
|
|
146
|
+
Leverage massive context windows instead of working around limitations
|
|
147
|
+
|
|
148
|
+
### 3. **Tool Evolution Compatibility**
|
|
149
|
+
|
|
150
|
+
Instructions remain stable as agent capabilities evolve (grep → AST parsing → future tools)
|
|
151
|
+
|
|
152
|
+
### 4. **Zero AI Dependency**
|
|
153
|
+
|
|
154
|
+
Pure logic-based guidance for reliability and speed
|
|
155
|
+
|
|
156
|
+
### 5. **Investigation Over Retrieval**
|
|
157
|
+
|
|
158
|
+
Agents follow references and build understanding incrementally
|
|
159
|
+
|
|
160
|
+
## 🚀 Quick Start
|
|
161
|
+
|
|
162
|
+
### Installation
|
|
163
|
+
|
|
164
|
+
```bash
|
|
165
|
+
npm install -g agentic-knowledge
|
|
166
|
+
# or
|
|
167
|
+
npx agentic-knowledge
|
|
168
|
+
```
|
|
169
|
+
|
|
170
|
+
### Basic Setup
|
|
171
|
+
|
|
172
|
+
1. **Create configuration directory**:
|
|
173
|
+
|
|
174
|
+
```bash
|
|
175
|
+
mkdir .knowledge
|
|
176
|
+
```
|
|
177
|
+
|
|
178
|
+
2. **Add configuration** (`.knowledge/config.yaml`):
|
|
179
|
+
|
|
180
|
+
```yaml
|
|
181
|
+
version: "1.0"
|
|
182
|
+
docsets:
|
|
183
|
+
- id: my-docs
|
|
184
|
+
name: My Project Documentation
|
|
185
|
+
description: "Local project documentation"
|
|
186
|
+
sources:
|
|
187
|
+
- type: local_folder
|
|
188
|
+
paths: ["./docs"]
|
|
189
|
+
|
|
190
|
+
- id: react-docs
|
|
191
|
+
name: React Documentation
|
|
192
|
+
description: "Official React documentation from GitHub"
|
|
193
|
+
sources:
|
|
194
|
+
- type: git_repo
|
|
195
|
+
url: "https://github.com/facebook/react.git"
|
|
196
|
+
branch: "main"
|
|
197
|
+
paths: ["docs/"]
|
|
198
|
+
```
|
|
199
|
+
|
|
200
|
+
3. **Start the MCP server**:
|
|
201
|
+
|
|
202
|
+
```bash
|
|
203
|
+
agentic-knowledge
|
|
204
|
+
```
|
|
205
|
+
|
|
206
|
+
4. **Connect your AI assistant** using MCP protocol
|
|
207
|
+
|
|
208
|
+
## 📋 Configuration Guide
|
|
209
|
+
|
|
210
|
+
### Local Folder Sources
|
|
211
|
+
|
|
212
|
+
For documentation stored locally in your project:
|
|
213
|
+
|
|
214
|
+
```yaml
|
|
215
|
+
docsets:
|
|
216
|
+
- id: my-project
|
|
217
|
+
name: My Project Docs
|
|
218
|
+
sources:
|
|
219
|
+
- type: local_folder
|
|
220
|
+
paths:
|
|
221
|
+
- "./docs" # Single directory
|
|
222
|
+
- "./guides" # Multiple directories
|
|
223
|
+
- "./api/README.md" # Specific files
|
|
224
|
+
```
|
|
225
|
+
|
|
226
|
+
**Benefits:**
|
|
227
|
+
- ✅ **No file duplication** - creates symlinks to original locations
|
|
228
|
+
- ✅ **Real-time updates** - changes immediately visible
|
|
229
|
+
- ✅ **Relative paths** - returns clean relative paths for LLM navigation
|
|
230
|
+
|
|
231
|
+
### Git Repository Sources
|
|
232
|
+
|
|
233
|
+
For documentation from remote repositories:
|
|
234
|
+
|
|
235
|
+
```yaml
|
|
236
|
+
docsets:
|
|
237
|
+
- id: external-docs
|
|
238
|
+
name: External Documentation
|
|
239
|
+
sources:
|
|
240
|
+
- type: git_repo
|
|
241
|
+
url: "https://github.com/owner/repo.git"
|
|
242
|
+
branch: "main" # Optional, defaults to main
|
|
243
|
+
paths: ["docs/", "README.md"] # Optional, extracts specific paths
|
|
244
|
+
```
|
|
245
|
+
|
|
246
|
+
**Benefits:**
|
|
247
|
+
- ✅ **Automatic downloads** - fetches latest documentation
|
|
248
|
+
- ✅ **Selective extraction** - only downloads specified paths
|
|
249
|
+
- ✅ **Branch selection** - target specific branches or tags
|
|
250
|
+
|
|
251
|
+
### Mixed Configuration
|
|
252
|
+
|
|
253
|
+
Combine local and remote sources in one configuration:
|
|
254
|
+
|
|
255
|
+
```yaml
|
|
256
|
+
version: "1.0"
|
|
257
|
+
docsets:
|
|
258
|
+
- id: local-guides
|
|
259
|
+
name: Local User Guides
|
|
260
|
+
sources:
|
|
261
|
+
- type: local_folder
|
|
262
|
+
paths: ["./docs/guides"]
|
|
263
|
+
|
|
264
|
+
- id: api-reference
|
|
265
|
+
name: API Reference
|
|
266
|
+
sources:
|
|
267
|
+
- type: git_repo
|
|
268
|
+
url: "https://github.com/company/api-docs.git"
|
|
269
|
+
paths: ["reference/"]
|
|
270
|
+
|
|
271
|
+
- id: mixed-sources
|
|
272
|
+
name: Combined Documentation
|
|
273
|
+
sources:
|
|
274
|
+
- type: local_folder
|
|
275
|
+
paths: ["./internal-docs"]
|
|
276
|
+
- type: git_repo
|
|
277
|
+
url: "https://github.com/external/docs.git"
|
|
278
|
+
```
|
|
279
|
+
|
|
280
|
+
## 🎯 How to Use
|
|
281
|
+
|
|
282
|
+
### Step 1: Set Up Your Documentation
|
|
283
|
+
|
|
284
|
+
Create a `.knowledge/config.yaml` file in your project root:
|
|
285
|
+
|
|
286
|
+
```yaml
|
|
287
|
+
version: "1.0"
|
|
288
|
+
docsets:
|
|
289
|
+
- id: my-project
|
|
290
|
+
name: My Project Documentation
|
|
291
|
+
description: "Main project documentation"
|
|
292
|
+
sources:
|
|
293
|
+
- type: local_folder
|
|
294
|
+
paths: ["./docs", "./README.md"]
|
|
295
|
+
```
|
|
296
|
+
|
|
297
|
+
### Step 2: Start the MCP Server
|
|
298
|
+
|
|
299
|
+
```bash
|
|
300
|
+
# Install globally
|
|
301
|
+
npm install -g agentic-knowledge
|
|
302
|
+
|
|
303
|
+
# Start the server
|
|
304
|
+
agentic-knowledge
|
|
305
|
+
```
|
|
306
|
+
|
|
307
|
+
The server will:
|
|
308
|
+
- ✅ Create symlinks for local folders in `.knowledge/docsets/`
|
|
309
|
+
- ✅ Validate your configuration
|
|
310
|
+
- ✅ Start listening for MCP requests
|
|
311
|
+
|
|
312
|
+
### Step 3: Connect Your AI Assistant
|
|
313
|
+
|
|
314
|
+
Configure your AI assistant (Claude Desktop, etc.) to use the MCP server:
|
|
315
|
+
|
|
316
|
+
```json
|
|
317
|
+
{
|
|
318
|
+
"mcpServers": {
|
|
319
|
+
"agentic-knowledge": {
|
|
320
|
+
"command": "agentic-knowledge"
|
|
321
|
+
}
|
|
322
|
+
}
|
|
323
|
+
}
|
|
324
|
+
```
|
|
325
|
+
|
|
326
|
+
### Step 4: Search Your Documentation
|
|
327
|
+
|
|
328
|
+
Use the `search_docs` tool in your AI assistant:
|
|
329
|
+
|
|
330
|
+
```
|
|
331
|
+
search_docs({
|
|
332
|
+
docset_id: "my-project",
|
|
333
|
+
keywords: "authentication setup",
|
|
334
|
+
generalized_keywords: "login, auth, security"
|
|
335
|
+
})
|
|
336
|
+
```
|
|
337
|
+
|
|
338
|
+
**Response:**
|
|
339
|
+
```
|
|
340
|
+
# 📚 Search My Project Documentation
|
|
341
|
+
|
|
342
|
+
**Primary terms:** authentication setup
|
|
343
|
+
**Related terms:** login, auth, security
|
|
344
|
+
**Location:** docs
|
|
345
|
+
|
|
346
|
+
## 🔍 Search Strategy
|
|
347
|
+
|
|
348
|
+
1. **Start with Specific Terms**
|
|
349
|
+
Use your text search tools (grep, rg, ripgrep) to search for: `authentication setup`
|
|
350
|
+
|
|
351
|
+
2. **Expand to Related Terms**
|
|
352
|
+
If initial search doesn't yield results, try: `login, auth, security`
|
|
353
|
+
|
|
354
|
+
3. **What to Avoid**
|
|
355
|
+
Skip these directories: `node_modules/`, `.git/`, `.knowledge/`
|
|
356
|
+
```
|
|
357
|
+
|
|
358
|
+
### Step 5: Follow the Guidance
|
|
359
|
+
|
|
360
|
+
Your AI assistant will use the provided search strategy to:
|
|
361
|
+
1. 🔍 Search your documentation with the suggested terms
|
|
362
|
+
2. 📂 Navigate to the right files and directories
|
|
363
|
+
3. 🎯 Find exactly what you're looking for
|
|
364
|
+
4. 🔗 Follow cross-references and related content
|
|
365
|
+
|
|
366
|
+
## 💡 Pro Tips
|
|
367
|
+
|
|
368
|
+
### Local Development Workflow
|
|
369
|
+
|
|
370
|
+
```yaml
|
|
371
|
+
# Perfect for active development
|
|
372
|
+
docsets:
|
|
373
|
+
- id: current-project
|
|
374
|
+
name: Current Project
|
|
375
|
+
sources:
|
|
376
|
+
- type: local_folder
|
|
377
|
+
paths: ["./docs", "./README.md", "./CHANGELOG.md"]
|
|
378
|
+
```
|
|
379
|
+
|
|
380
|
+
**Benefits:**
|
|
381
|
+
- Changes in your docs are immediately available
|
|
382
|
+
- No copying or syncing needed
|
|
383
|
+
- Works with any file type
|
|
384
|
+
|
|
385
|
+
### Multi-Repository Setup
|
|
386
|
+
|
|
387
|
+
```yaml
|
|
388
|
+
# Combine multiple sources
|
|
389
|
+
docsets:
|
|
390
|
+
- id: frontend-docs
|
|
391
|
+
name: Frontend Documentation
|
|
392
|
+
sources:
|
|
393
|
+
- type: local_folder
|
|
394
|
+
paths: ["./frontend/docs"]
|
|
395
|
+
- type: git_repo
|
|
396
|
+
url: "https://github.com/company/design-system.git"
|
|
397
|
+
paths: ["docs/"]
|
|
398
|
+
|
|
399
|
+
- id: backend-docs
|
|
400
|
+
name: Backend Documentation
|
|
401
|
+
sources:
|
|
402
|
+
- type: git_repo
|
|
403
|
+
url: "https://github.com/company/api-docs.git"
|
|
404
|
+
branch: "main"
|
|
405
|
+
```
|
|
406
|
+
|
|
407
|
+
### Advanced Search Strategies
|
|
408
|
+
|
|
409
|
+
Use specific and generalized keywords for better results:
|
|
410
|
+
|
|
411
|
+
```javascript
|
|
412
|
+
// ✅ Good: Specific + General
|
|
413
|
+
search_docs({
|
|
414
|
+
docset_id: "react-docs",
|
|
415
|
+
keywords: "useEffect cleanup function",
|
|
416
|
+
generalized_keywords: "hooks, lifecycle, memory management"
|
|
417
|
+
})
|
|
418
|
+
|
|
419
|
+
// ❌ Too vague
|
|
420
|
+
search_docs({
|
|
421
|
+
docset_id: "react-docs",
|
|
422
|
+
keywords: "react",
|
|
423
|
+
generalized_keywords: "javascript"
|
|
424
|
+
})
|
|
425
|
+
```
|
|
426
|
+
|
|
427
|
+
## 📊 Performance vs RAG
|
|
428
|
+
|
|
429
|
+
| Metric | Traditional RAG | Agentic Knowledge |
|
|
430
|
+
| ------------------ | ------------------------- | ----------------- |
|
|
431
|
+
| **Setup Time** | Hours (indexing) | Seconds (config) |
|
|
432
|
+
| **Response Time** | 300-2000ms | <10ms |
|
|
433
|
+
| **Infrastructure** | Elasticsearch + Vector DB | Zero |
|
|
434
|
+
| **Maintenance** | High (reindexing) | None |
|
|
435
|
+
| **Accuracy** | Fragment-based | Complete context |
|
|
436
|
+
| **Cost** | High (compute) | Minimal |
|
|
437
|
+
|
|
438
|
+
## 🔬 The Future of Knowledge Systems
|
|
439
|
+
|
|
440
|
+
We're entering the **post-retrieval age**. The winners won't be those with the biggest vector databases, but those who design the smartest navigation systems for abundant context.
|
|
441
|
+
|
|
442
|
+
**RAG was training wheels**—useful, necessary, but temporary. The future belongs to systems that read, navigate, and reason end-to-end.
|
|
443
|
+
|
|
444
|
+
## 🚀 Local Development & Installation
|
|
445
|
+
|
|
446
|
+
### Installing from Source (Before NPM Publication)
|
|
447
|
+
|
|
448
|
+
Since the packages aren't published to npm yet, you can install them locally:
|
|
449
|
+
|
|
450
|
+
1. **Build all packages:**
|
|
451
|
+
|
|
452
|
+
```bash
|
|
453
|
+
pnpm install
|
|
454
|
+
pnpm build
|
|
455
|
+
```
|
|
456
|
+
|
|
457
|
+
2. **Create local installation packages:**
|
|
458
|
+
|
|
459
|
+
```bash
|
|
460
|
+
pnpm run pack:local
|
|
461
|
+
```
|
|
462
|
+
|
|
463
|
+
This creates `dist-local/` directory with packages that have workspace dependencies converted to relative file paths.
|
|
464
|
+
|
|
465
|
+
3. **Install the MCP server locally:**
|
|
466
|
+
|
|
467
|
+
```bash
|
|
468
|
+
# Option 1: Install from tarball
|
|
469
|
+
cd dist-local/mcp-server && npm pack
|
|
470
|
+
npm install -g codemcp-knowledge-mcp-server-0.1.0.tgz
|
|
471
|
+
|
|
472
|
+
# Option 2: Install directly from directory
|
|
473
|
+
npm install -g ./dist-local/mcp-server/
|
|
474
|
+
```
|
|
475
|
+
|
|
476
|
+
4. **Verify installation:**
|
|
477
|
+
```bash
|
|
478
|
+
agentic-knowledge --help
|
|
479
|
+
```
|
|
480
|
+
|
|
481
|
+
### Development
|
|
482
|
+
|
|
483
|
+
```bash
|
|
484
|
+
# Install dependencies
|
|
485
|
+
pnpm install
|
|
486
|
+
|
|
487
|
+
# Start development mode
|
|
488
|
+
pnpm dev
|
|
489
|
+
|
|
490
|
+
# Run tests
|
|
491
|
+
pnpm test
|
|
492
|
+
|
|
493
|
+
# Build all packages
|
|
494
|
+
pnpm build
|
|
495
|
+
|
|
496
|
+
# Format and lint
|
|
497
|
+
pnpm format
|
|
498
|
+
pnpm lint
|
|
499
|
+
```
|
|
500
|
+
|
|
501
|
+
## 🧪 Development Status
|
|
502
|
+
|
|
503
|
+
**Current Phase**: Finalization ✅
|
|
504
|
+
|
|
505
|
+
- ✅ Core implementation complete (107 tests passing)
|
|
506
|
+
- ✅ MCP protocol compliance verified
|
|
507
|
+
- ✅ Performance validated (0.47ms response time)
|
|
508
|
+
- ✅ Full documentation and examples
|
|
509
|
+
- ⚠️ Ready for community feedback and real-world testing
|
|
510
|
+
|
|
511
|
+
## 📚 Examples & Documentation
|
|
512
|
+
|
|
513
|
+
- [`examples/`](./examples/) - Configuration examples and integration guides
|
|
514
|
+
- [`TESTING.md`](./TESTING.md) - Comprehensive testing documentation
|
|
515
|
+
- [Architecture docs](./.vibe/docs/) - Detailed technical specifications
|
|
516
|
+
|
|
517
|
+
## 🤝 Contributing
|
|
518
|
+
|
|
519
|
+
This project follows a structured development workflow. See our development documentation for contribution guidelines.
|
|
520
|
+
|
|
521
|
+
## 📄 License
|
|
522
|
+
|
|
523
|
+
Distributed under the MIT License. See [`LICENSE`](./LICENSE) file for details.
|
|
524
|
+
|
|
525
|
+
---
|
|
526
|
+
|
|
527
|
+
<div align="center">
|
|
528
|
+
<p><strong>🎯 Moving beyond RAG into the agentic era of knowledge systems</strong></p>
|
|
529
|
+
<p><em>Inspired by <a href="https://www.nicolasbustamante.com/p/the-rag-obituary-killed-by-agents">The RAG Obituary</a> by Nicolas Bustamante</em></p>
|
|
530
|
+
</div>
|
package/package.json
ADDED
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "agentic-knowledge-mcp",
|
|
3
|
+
"version": "0.0.1",
|
|
4
|
+
"description": "A Model Context Protocol server for agentic knowledge guidance with web-based documentation loading and intelligent search instructions",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "packages/mcp-server/dist/index.js",
|
|
7
|
+
"bin": {
|
|
8
|
+
"agentic-knowledge": "packages/cli/dist/cli.js"
|
|
9
|
+
},
|
|
10
|
+
"engines": {
|
|
11
|
+
"node": ">=18.0.0",
|
|
12
|
+
"pnpm": ">=9.0.0"
|
|
13
|
+
},
|
|
14
|
+
"files": [
|
|
15
|
+
"packages/*/dist/**/*",
|
|
16
|
+
"packages/*/package.json",
|
|
17
|
+
"README.md",
|
|
18
|
+
"LICENSE",
|
|
19
|
+
"package.json"
|
|
20
|
+
],
|
|
21
|
+
"repository": {
|
|
22
|
+
"type": "git",
|
|
23
|
+
"url": "git+https://github.com/mrsimpson/agentic-knowledge-mcp.git"
|
|
24
|
+
},
|
|
25
|
+
"dependencies": {
|
|
26
|
+
"@modelcontextprotocol/sdk": "^1.19.1",
|
|
27
|
+
"@types/js-yaml": "4.0.9",
|
|
28
|
+
"js-yaml": "4.1.0",
|
|
29
|
+
"@codemcp/knowledge-mcp-server": "0.0.1",
|
|
30
|
+
"@codemcp/knowledge-content-loader": "0.0.1",
|
|
31
|
+
"@codemcp/knowledge-core": "0.0.1"
|
|
32
|
+
},
|
|
33
|
+
"devDependencies": {
|
|
34
|
+
"@modelcontextprotocol/inspector": "0.16.8",
|
|
35
|
+
"@tsconfig/node22": "22.0.2",
|
|
36
|
+
"@tsconfig/strictest": "2.0.5",
|
|
37
|
+
"@types/node": "^24.3.0",
|
|
38
|
+
"@typescript-eslint/eslint-plugin": "^8.42.0",
|
|
39
|
+
"@typescript-eslint/parser": "^8.42.0",
|
|
40
|
+
"@vitest/coverage-v8": "^3.2.4",
|
|
41
|
+
"eslint": "^9.34.0",
|
|
42
|
+
"eslint-config-prettier": "^10.1.8",
|
|
43
|
+
"husky": "^9.1.7",
|
|
44
|
+
"lint-staged": "^16.1.6",
|
|
45
|
+
"oxlint": "1.14.0",
|
|
46
|
+
"prettier": "^3.6.2",
|
|
47
|
+
"rimraf": "^6.0.1",
|
|
48
|
+
"turbo": "^2.5.6",
|
|
49
|
+
"typescript": "^5.9.2",
|
|
50
|
+
"vitest": "^3.2.4"
|
|
51
|
+
},
|
|
52
|
+
"lint-staged": {
|
|
53
|
+
"*.{ts,js,mts,cts,tsx,jsx}": [
|
|
54
|
+
"prettier --write",
|
|
55
|
+
"oxlint --fix"
|
|
56
|
+
],
|
|
57
|
+
"*.{json,md,yml,yaml}": [
|
|
58
|
+
"prettier --write"
|
|
59
|
+
]
|
|
60
|
+
},
|
|
61
|
+
"keywords": [
|
|
62
|
+
"mcp",
|
|
63
|
+
"model-context-protocol",
|
|
64
|
+
"agentic",
|
|
65
|
+
"knowledge",
|
|
66
|
+
"guidance",
|
|
67
|
+
"search",
|
|
68
|
+
"documentation",
|
|
69
|
+
"ai",
|
|
70
|
+
"assistant",
|
|
71
|
+
"web-loading"
|
|
72
|
+
],
|
|
73
|
+
"author": "Oliver Jägle <github@beimir.net>",
|
|
74
|
+
"license": "MIT",
|
|
75
|
+
"scripts": {
|
|
76
|
+
"build": "turbo run build",
|
|
77
|
+
"pack:local": "node scripts/prepare-local.cjs",
|
|
78
|
+
"inspector": "npx @modelcontextprotocol/inspector",
|
|
79
|
+
"dev": "turbo run dev --filter=@codemcp/knowledge-core --filter=@codemcp/knowledge-mcp-server",
|
|
80
|
+
"clean": "turbo run clean:build",
|
|
81
|
+
"lint-staged": "npx lint-staged",
|
|
82
|
+
"test": "node scripts/test-summary.js",
|
|
83
|
+
"test:run": "node scripts/test-summary.js",
|
|
84
|
+
"test:manual": "npm run build && npm run inspector",
|
|
85
|
+
"test:e2e": "vitest run test/e2e/",
|
|
86
|
+
"test:watch": "turbo run test",
|
|
87
|
+
"lint:all": "turbo run --parallel lint",
|
|
88
|
+
"lint:fix:all": "turbo run --parallel lint:fix",
|
|
89
|
+
"format:check:all": "turbo run --parallel format:check",
|
|
90
|
+
"format:all": "turbo run --parallel format:fix",
|
|
91
|
+
"typecheck:all": "turbo run --parallel typecheck",
|
|
92
|
+
"clean:build": "turbo run clean:build"
|
|
93
|
+
}
|
|
94
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
/**
|
|
3
|
+
* CLI entry point for agentic-knowledge web content management
|
|
4
|
+
*/
|
|
5
|
+
import { Command } from "commander";
|
|
6
|
+
import { initCommand } from "./commands/init.js";
|
|
7
|
+
import { refreshCommand } from "./commands/refresh.js";
|
|
8
|
+
import { statusCommand } from "./commands/status.js";
|
|
9
|
+
import { createCommand } from "./commands/create.js";
|
|
10
|
+
const program = new Command();
|
|
11
|
+
program
|
|
12
|
+
.name("agentic-knowledge")
|
|
13
|
+
.description("Manage web content sources for agentic knowledge system")
|
|
14
|
+
.version("0.1.0");
|
|
15
|
+
// Add commands
|
|
16
|
+
program.addCommand(createCommand);
|
|
17
|
+
program.addCommand(initCommand);
|
|
18
|
+
program.addCommand(refreshCommand);
|
|
19
|
+
program.addCommand(statusCommand);
|
|
20
|
+
// Parse command line arguments
|
|
21
|
+
program.parse();
|