keywordgraph-mcp-server 1.6.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 +21 -0
- package/README.md +629 -0
- package/bin/infranodus-mcp-server.js +8 -0
- package/bin/keywordgraph-mcp-server.js +8 -0
- package/bin/mcp-server.js +56 -0
- package/dist/api/client.d.ts +3 -0
- package/dist/api/client.d.ts.map +1 -0
- package/dist/api/client.js +30 -0
- package/dist/api/client.js.map +1 -0
- package/dist/api/config-store.d.ts +4 -0
- package/dist/api/config-store.d.ts.map +1 -0
- package/dist/api/config-store.js +12 -0
- package/dist/api/config-store.js.map +1 -0
- package/dist/auth/oauth-provider.d.ts +56 -0
- package/dist/auth/oauth-provider.d.ts.map +1 -0
- package/dist/auth/oauth-provider.js +295 -0
- package/dist/auth/oauth-provider.js.map +1 -0
- package/dist/auth/types.d.ts +93 -0
- package/dist/auth/types.d.ts.map +1 -0
- package/dist/auth/types.js +5 -0
- package/dist/auth/types.js.map +1 -0
- package/dist/config/brand.d.ts +58 -0
- package/dist/config/brand.d.ts.map +1 -0
- package/dist/config/brand.js +97 -0
- package/dist/config/brand.js.map +1 -0
- package/dist/config/index.d.ts +26 -0
- package/dist/config/index.d.ts.map +1 -0
- package/dist/config/index.js +20 -0
- package/dist/config/index.js.map +1 -0
- package/dist/http-server.d.ts +6 -0
- package/dist/http-server.d.ts.map +1 -0
- package/dist/http-server.js +907 -0
- package/dist/http-server.js.map +1 -0
- package/dist/index.d.ts +29 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +136 -0
- package/dist/index.js.map +1 -0
- package/dist/instructions.d.ts +11 -0
- package/dist/instructions.d.ts.map +1 -0
- package/dist/instructions.js +38 -0
- package/dist/instructions.js.map +1 -0
- package/dist/prompts/index.d.ts +24 -0
- package/dist/prompts/index.d.ts.map +1 -0
- package/dist/prompts/index.js +394 -0
- package/dist/prompts/index.js.map +1 -0
- package/dist/resources/about.d.ts +17 -0
- package/dist/resources/about.d.ts.map +1 -0
- package/dist/resources/about.js +64 -0
- package/dist/resources/about.js.map +1 -0
- package/dist/resources/llms-txt.d.ts +33 -0
- package/dist/resources/llms-txt.d.ts.map +1 -0
- package/dist/resources/llms-txt.js +65 -0
- package/dist/resources/llms-txt.js.map +1 -0
- package/dist/schemas/index.d.ts +1178 -0
- package/dist/schemas/index.d.ts.map +1 -0
- package/dist/schemas/index.js +1121 -0
- package/dist/schemas/index.js.map +1 -0
- package/dist/tools/addMemory.d.ts +36 -0
- package/dist/tools/addMemory.d.ts.map +1 -0
- package/dist/tools/addMemory.js +82 -0
- package/dist/tools/addMemory.js.map +1 -0
- package/dist/tools/analyzeExistingGraph.d.ts +37 -0
- package/dist/tools/analyzeExistingGraph.d.ts.map +1 -0
- package/dist/tools/analyzeExistingGraph.js +85 -0
- package/dist/tools/analyzeExistingGraph.js.map +1 -0
- package/dist/tools/analyzeLlmResults.d.ts +37 -0
- package/dist/tools/analyzeLlmResults.d.ts.map +1 -0
- package/dist/tools/analyzeLlmResults.js +165 -0
- package/dist/tools/analyzeLlmResults.js.map +1 -0
- package/dist/tools/analyzeText.d.ts +36 -0
- package/dist/tools/analyzeText.d.ts.map +1 -0
- package/dist/tools/analyzeText.js +97 -0
- package/dist/tools/analyzeText.js.map +1 -0
- package/dist/tools/createKnowledgeGraph.d.ts +36 -0
- package/dist/tools/createKnowledgeGraph.d.ts.map +1 -0
- package/dist/tools/createKnowledgeGraph.js +105 -0
- package/dist/tools/createKnowledgeGraph.js.map +1 -0
- package/dist/tools/developConceptualBridges.d.ts +34 -0
- package/dist/tools/developConceptualBridges.d.ts.map +1 -0
- package/dist/tools/developConceptualBridges.js +107 -0
- package/dist/tools/developConceptualBridges.js.map +1 -0
- package/dist/tools/developLatentConcepts copy.d.ts +27 -0
- package/dist/tools/developLatentConcepts copy.d.ts.map +1 -0
- package/dist/tools/developLatentConcepts copy.js +68 -0
- package/dist/tools/developLatentConcepts copy.js.map +1 -0
- package/dist/tools/developLatentConcepts.d.ts +27 -0
- package/dist/tools/developLatentConcepts.d.ts.map +1 -0
- package/dist/tools/developLatentConcepts.js +68 -0
- package/dist/tools/developLatentConcepts.js.map +1 -0
- package/dist/tools/developLatentTopics.d.ts +34 -0
- package/dist/tools/developLatentTopics.d.ts.map +1 -0
- package/dist/tools/developLatentTopics.js +107 -0
- package/dist/tools/developLatentTopics.js.map +1 -0
- package/dist/tools/developTextTool.d.ts +39 -0
- package/dist/tools/developTextTool.d.ts.map +1 -0
- package/dist/tools/developTextTool.js +210 -0
- package/dist/tools/developTextTool.js.map +1 -0
- package/dist/tools/generateContentGaps.d.ts +32 -0
- package/dist/tools/generateContentGaps.d.ts.map +1 -0
- package/dist/tools/generateContentGaps.js +96 -0
- package/dist/tools/generateContentGaps.js.map +1 -0
- package/dist/tools/generateContextualHint.d.ts +33 -0
- package/dist/tools/generateContextualHint.d.ts.map +1 -0
- package/dist/tools/generateContextualHint.js +99 -0
- package/dist/tools/generateContextualHint.js.map +1 -0
- package/dist/tools/generateDifferenceGraphFromTexts.d.ts +52 -0
- package/dist/tools/generateDifferenceGraphFromTexts.d.ts.map +1 -0
- package/dist/tools/generateDifferenceGraphFromTexts.js +160 -0
- package/dist/tools/generateDifferenceGraphFromTexts.js.map +1 -0
- package/dist/tools/generateGoogleResultsVsQueriesGraph.d.ts +37 -0
- package/dist/tools/generateGoogleResultsVsQueriesGraph.d.ts.map +1 -0
- package/dist/tools/generateGoogleResultsVsQueriesGraph.js +84 -0
- package/dist/tools/generateGoogleResultsVsQueriesGraph.js.map +1 -0
- package/dist/tools/generateGoogleSearchQueriesGraph.d.ts +39 -0
- package/dist/tools/generateGoogleSearchQueriesGraph.d.ts.map +1 -0
- package/dist/tools/generateGoogleSearchQueriesGraph.js +88 -0
- package/dist/tools/generateGoogleSearchQueriesGraph.js.map +1 -0
- package/dist/tools/generateGoogleSearchResultsGraph.d.ts +38 -0
- package/dist/tools/generateGoogleSearchResultsGraph.d.ts.map +1 -0
- package/dist/tools/generateGoogleSearchResultsGraph.js +88 -0
- package/dist/tools/generateGoogleSearchResultsGraph.js.map +1 -0
- package/dist/tools/generateKnowledgeGraph.d.ts +35 -0
- package/dist/tools/generateKnowledgeGraph.d.ts.map +1 -0
- package/dist/tools/generateKnowledgeGraph.js +105 -0
- package/dist/tools/generateKnowledgeGraph.js.map +1 -0
- package/dist/tools/generateMergedGraphFromTexts.d.ts +52 -0
- package/dist/tools/generateMergedGraphFromTexts.d.ts.map +1 -0
- package/dist/tools/generateMergedGraphFromTexts.js +160 -0
- package/dist/tools/generateMergedGraphFromTexts.js.map +1 -0
- package/dist/tools/generateOntologyGraph.d.ts +36 -0
- package/dist/tools/generateOntologyGraph.d.ts.map +1 -0
- package/dist/tools/generateOntologyGraph.js +171 -0
- package/dist/tools/generateOntologyGraph.js.map +1 -0
- package/dist/tools/generateOverlapGraphFromTexts.d.ts +52 -0
- package/dist/tools/generateOverlapGraphFromTexts.d.ts.map +1 -0
- package/dist/tools/generateOverlapGraphFromTexts.js +159 -0
- package/dist/tools/generateOverlapGraphFromTexts.js.map +1 -0
- package/dist/tools/generateResearchIdeas.d.ts +39 -0
- package/dist/tools/generateResearchIdeas.d.ts.map +1 -0
- package/dist/tools/generateResearchIdeas.js +117 -0
- package/dist/tools/generateResearchIdeas.js.map +1 -0
- package/dist/tools/generateResearchQuestions.d.ts +37 -0
- package/dist/tools/generateResearchQuestions.d.ts.map +1 -0
- package/dist/tools/generateResearchQuestions.js +111 -0
- package/dist/tools/generateResearchQuestions.js.map +1 -0
- package/dist/tools/generateResearchQuestionsFromGraph.d.ts +34 -0
- package/dist/tools/generateResearchQuestionsFromGraph.d.ts.map +1 -0
- package/dist/tools/generateResearchQuestionsFromGraph.js +75 -0
- package/dist/tools/generateResearchQuestionsFromGraph.js.map +1 -0
- package/dist/tools/generateResponses.d.ts +35 -0
- package/dist/tools/generateResponses.d.ts.map +1 -0
- package/dist/tools/generateResponses.js +112 -0
- package/dist/tools/generateResponses.js.map +1 -0
- package/dist/tools/generateResponsesFromGraph.d.ts +33 -0
- package/dist/tools/generateResponsesFromGraph.d.ts.map +1 -0
- package/dist/tools/generateResponsesFromGraph.js +74 -0
- package/dist/tools/generateResponsesFromGraph.js.map +1 -0
- package/dist/tools/generateSEOGraphTool.d.ts +39 -0
- package/dist/tools/generateSEOGraphTool.d.ts.map +1 -0
- package/dist/tools/generateSEOGraphTool.js +235 -0
- package/dist/tools/generateSEOGraphTool.js.map +1 -0
- package/dist/tools/generateTextOverview.d.ts +31 -0
- package/dist/tools/generateTextOverview.d.ts.map +1 -0
- package/dist/tools/generateTextOverview.js +68 -0
- package/dist/tools/generateTextOverview.js.map +1 -0
- package/dist/tools/generateTopicalClusters.d.ts +34 -0
- package/dist/tools/generateTopicalClusters.d.ts.map +1 -0
- package/dist/tools/generateTopicalClusters.js +134 -0
- package/dist/tools/generateTopicalClusters.js.map +1 -0
- package/dist/tools/getMemory.d.ts +32 -0
- package/dist/tools/getMemory.d.ts.map +1 -0
- package/dist/tools/getMemory.js +121 -0
- package/dist/tools/getMemory.js.map +1 -0
- package/dist/tools/index.d.ts +30 -0
- package/dist/tools/index.d.ts.map +1 -0
- package/dist/tools/index.js +30 -0
- package/dist/tools/index.js.map +1 -0
- package/dist/tools/listGraphs.d.ts +37 -0
- package/dist/tools/listGraphs.d.ts.map +1 -0
- package/dist/tools/listGraphs.js +127 -0
- package/dist/tools/listGraphs.js.map +1 -0
- package/dist/tools/optimizeTextStructure.d.ts +34 -0
- package/dist/tools/optimizeTextStructure.d.ts.map +1 -0
- package/dist/tools/optimizeTextStructure.js +108 -0
- package/dist/tools/optimizeTextStructure.js.map +1 -0
- package/dist/tools/retrieveContextForPromptFromGraph.d.ts +37 -0
- package/dist/tools/retrieveContextForPromptFromGraph.d.ts.map +1 -0
- package/dist/tools/retrieveContextForPromptFromGraph.js +80 -0
- package/dist/tools/retrieveContextForPromptFromGraph.js.map +1 -0
- package/dist/tools/searchGraph.d.ts +27 -0
- package/dist/tools/searchGraph.d.ts.map +1 -0
- package/dist/tools/searchGraph.js +57 -0
- package/dist/tools/searchGraph.js.map +1 -0
- package/dist/tools/searchGraphs.d.ts +33 -0
- package/dist/tools/searchGraphs.d.ts.map +1 -0
- package/dist/tools/searchGraphs.js +67 -0
- package/dist/tools/searchGraphs.js.map +1 -0
- package/dist/tools/searchGraphsFetch.d.ts +31 -0
- package/dist/tools/searchGraphsFetch.d.ts.map +1 -0
- package/dist/tools/searchGraphsFetch.js +78 -0
- package/dist/tools/searchGraphsFetch.js.map +1 -0
- package/dist/tools/sequentialThinking.d.ts +71 -0
- package/dist/tools/sequentialThinking.d.ts.map +1 -0
- package/dist/tools/sequentialThinking.js +218 -0
- package/dist/tools/sequentialThinking.js.map +1 -0
- package/dist/types/index.d.ts +378 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +2 -0
- package/dist/types/index.js.map +1 -0
- package/dist/utils/progress.d.ts +21 -0
- package/dist/utils/progress.d.ts.map +1 -0
- package/dist/utils/progress.js +50 -0
- package/dist/utils/progress.js.map +1 -0
- package/dist/utils/transformers.d.ts +31 -0
- package/dist/utils/transformers.d.ts.map +1 -0
- package/dist/utils/transformers.js +484 -0
- package/dist/utils/transformers.js.map +1 -0
- package/dist/utils/urlContent.d.ts +35 -0
- package/dist/utils/urlContent.d.ts.map +1 -0
- package/dist/utils/urlContent.js +87 -0
- package/dist/utils/urlContent.js.map +1 -0
- package/llms-full.infranodus.txt +469 -0
- package/llms-full.keywordgraph.txt +469 -0
- package/llms-full.txt +469 -0
- package/llms.infranodus.txt +64 -0
- package/llms.keywordgraph.txt +64 -0
- package/llms.txt +64 -0
- package/package.json +78 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025 InfraNodus
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,629 @@
|
|
|
1
|
+
# KeywordGraph MCP Server
|
|
2
|
+
|
|
3
|
+
A Model Context Protocol (MCP) server that integrates KeywordGraph knowledge graph and text network analysis capabilities into LLM workflows and AI assistants like Claude Desktop.
|
|
4
|
+
|
|
5
|
+
## Overview
|
|
6
|
+
|
|
7
|
+
KeywordGraph MCP Server enables LLM workflows and AI assistants to analyze text using advanced network science algorithms, generate knowledge graphs, detect content gaps, and identify key topics and concepts. It transforms unstructured text into structured insights using graph theory and network analysis.
|
|
8
|
+
|
|
9
|
+

|
|
10
|
+
|
|
11
|
+
## Features
|
|
12
|
+
|
|
13
|
+
### You Can Use It To
|
|
14
|
+
|
|
15
|
+
- Connect your existing KeywordGraph knowledge graphs to your LLM workflows and AI chats
|
|
16
|
+
- Identify the main topical clusters in discourse without missing the important nuances (works better than standard LLM workflows)
|
|
17
|
+
- Identify the content gaps in any discourse (helpful for content creation and research)
|
|
18
|
+
- Generate new knowledge graphs from any text and use them to augment your LLM responses
|
|
19
|
+
- Save and retrieve entities and relations from memory using the knowledge graphs
|
|
20
|
+
|
|
21
|
+
### Available Tools
|
|
22
|
+
|
|
23
|
+
1. **generate_knowledge_graph**
|
|
24
|
+
- Convert any text into a visual knowledge graph
|
|
25
|
+
- Extract topics, concepts, and their relationships
|
|
26
|
+
- Identify structural patterns and clusters
|
|
27
|
+
- Apply AI-powered topic naming
|
|
28
|
+
- Perform entity detection for cleaner graphs
|
|
29
|
+
|
|
30
|
+
2. **analyze_existing_graph_by_name**
|
|
31
|
+
- Retrieve and analyze existing graphs from your KeywordGraph account
|
|
32
|
+
- Access previously saved analyses
|
|
33
|
+
- Export graph data with full statistics
|
|
34
|
+
|
|
35
|
+
3. **analyze_text**
|
|
36
|
+
- Analyze a text, URL, or YouTube transcript
|
|
37
|
+
- Extract and analyze a graph from text or URL; provide either text or url
|
|
38
|
+
- Get topics, clusters, statements, graph structure, and AI summary as requested
|
|
39
|
+
|
|
40
|
+
4. **generate_content_gaps**
|
|
41
|
+
- Detect missing connections in discourse
|
|
42
|
+
- Identify underexplored topics
|
|
43
|
+
- Generate research questions
|
|
44
|
+
- Suggest content development opportunities
|
|
45
|
+
|
|
46
|
+
5. **generate_topical_clusters**
|
|
47
|
+
- Generate topics and clusters of keywords from text using knowledge graph analysis
|
|
48
|
+
- Make sure to beyond genetic insights and detect smaller topics
|
|
49
|
+
- Use the topical clusters to establish topical authority for SEO
|
|
50
|
+
- Returns AI-generated overviews of the topical clusters (`topicalClusterSummaries`), summarizing the discourse each cluster represents — useful for SEO-optimized content creation. Enabled by default; set `generateTopicalSummaries: false` to increase processing speed or if the summary request fails
|
|
51
|
+
|
|
52
|
+
6. **generate_contextual_hint**
|
|
53
|
+
- Generate a topical overview of a text and provide insights for LLMs to generate better responses
|
|
54
|
+
- Use it to get a high-level understanding of a text
|
|
55
|
+
- Use it to augment prompts in your LLM workflows and AI assistants
|
|
56
|
+
|
|
57
|
+
7. **generate_research_questions**
|
|
58
|
+
- Generate research questions that bridge content gaps from text, URL, or an existing KeywordGraph graph
|
|
59
|
+
- Use them as prompts in your LLM models and AI workflows
|
|
60
|
+
- Use any AI model (included in KeywordGraph API)
|
|
61
|
+
- Content gaps are identified based on topical clustering
|
|
62
|
+
|
|
63
|
+
8. **generate_research_ideas**
|
|
64
|
+
- Generate innovative research ideas based on content gaps identified in the text
|
|
65
|
+
- Get actionable ideas to improve the text and develop the discourse
|
|
66
|
+
- Use any AI model (included in KeywordGraph API)
|
|
67
|
+
- Ideas are generated from gaps between topical clusters
|
|
68
|
+
|
|
69
|
+
9. **optimize_text_structure**
|
|
70
|
+
- Analyze the level of bias and coherence in text using knowledge graph analysis
|
|
71
|
+
- If the text is too biased, develop the represented topics to balance the discourse
|
|
72
|
+
- If the text is focused or diversified, develop the content gaps to deepen the analysis
|
|
73
|
+
- If the text is dispersed, focus the most common gap topics to improve coherence
|
|
74
|
+
- Choose response type: response, idea, question, or transcend
|
|
75
|
+
|
|
76
|
+
10. **generate_responses_from_graph**
|
|
77
|
+
- Generate responses based on an existing KeywordGraph graph
|
|
78
|
+
- Integrate them into your LLM workflows and AI assistants
|
|
79
|
+
- Use any AI model (included in KeywordGraph API)
|
|
80
|
+
- Use any prompt
|
|
81
|
+
|
|
82
|
+
11. **develop_conceptual_bridges**
|
|
83
|
+
- Analyze text and develop latent ideas based on concepts that connect this text to a broader discourse
|
|
84
|
+
- Discover hidden themes and patterns that link your text to wider contexts
|
|
85
|
+
- Use any AI model (included in KeywordGraph API)
|
|
86
|
+
- Generate insights that help develop the discourse
|
|
87
|
+
|
|
88
|
+
12. **develop_latent_topics**
|
|
89
|
+
- Analyze text and extract underdeveloped topics with ideas on how to develop them
|
|
90
|
+
- Identify topics that need more attention and elaboration
|
|
91
|
+
- Use any AI model (included in KeywordGraph API)
|
|
92
|
+
- Get actionable suggestions for content expansion
|
|
93
|
+
|
|
94
|
+
13. **develop_text_tool**
|
|
95
|
+
- Comprehensive text analysis combining content gap ideas, latent topics, and conceptual bridges
|
|
96
|
+
- Executes multiple analyses in sequence with progress tracking
|
|
97
|
+
- Generates research ideas based on content gaps
|
|
98
|
+
- Identifies latent topics and conceptual bridges to develop
|
|
99
|
+
- Finds content gaps for deeper exploration
|
|
100
|
+
|
|
101
|
+
14. **create_knowledge_graph**
|
|
102
|
+
- Create a knowledge graph in KeywordGraph from text and provide a link to it
|
|
103
|
+
- Use it to create a knowledge graph in KeywordGraph from text
|
|
104
|
+
|
|
105
|
+
15. **generate_ontology_graph**
|
|
106
|
+
- Use AI to generate a reasoning ontology graph (entities and the relations between them) from a topic, prompt, or text — e.g. "build an ontology on AI attention mechanisms"
|
|
107
|
+
- Saved as a persistent KeywordGraph graph by default and a link is returned; set `saveGraph: false` if the user asks not to save, or when you only need a one-off AI ontology overview of a topic for the current context that won't be reused later (the generated statements are returned directly without persisting)
|
|
108
|
+
- `modelToUse` defaults to `claude-opus-4.6` for richer ontologies; pick `-mini`/`-lite` variants (or `gpt-4o-mini`) for faster, cheaper generation
|
|
109
|
+
- Returns the compact graph structure (`knowledgeGraph`) and analytics (main topical clusters, content gaps, top influential nodes, top relations, statistics) by default. Set `includeGraph: false` to save context space when only the ontology statements or insights are needed. Set `includeAnalytics: false` if you just need the raw ontology without graph-derived insights — keep it on whenever you want to understand the structure, gaps, or key concepts
|
|
110
|
+
|
|
111
|
+
16. **analyze_llm_results**
|
|
112
|
+
- Ask an LLM to describe a topic and turn its response into a knowledge graph that reveals how the model frames it — main concepts, clusters, content gaps, and the relations between them
|
|
113
|
+
- Use it to probe model bias, surface the implicit structure of an LLM's view on a subject, or compare how different models describe the same topic
|
|
114
|
+
- `modelToUse` defaults to `claude-opus-4.6`; pick the model you actually want to study
|
|
115
|
+
- `modifyAnalyzedText` controls how the LLM output is parsed: `'detectEntities'` (default — mixed entities + words), `'extractEntitiesOnly'` (entity-only graph), or `'none'` (plain co-occurrence)
|
|
116
|
+
- Saves the graph by default; set `saveGraph: false` for a one-off probe. Returns analytics by default and omits the raw graph (`includeGraph: false`) to keep responses compact — enable `includeGraph` when you also need nodes/edges
|
|
117
|
+
|
|
118
|
+
17. **overlap_between_texts**
|
|
119
|
+
- Create knowledge graphs from two or more texts and find the overlap (similarities) between them
|
|
120
|
+
- Use it to find similar topics and keywords across different texts
|
|
121
|
+
|
|
122
|
+
18. **merged_graph_from_texts**
|
|
123
|
+
- Build a graph of all the texts and URLs provided, providing topical clusters and gaps present in the merged graph generated from all the texts
|
|
124
|
+
- Use it to combine multiple sources into one graph and see clusters and content gaps across the merged content
|
|
125
|
+
|
|
126
|
+
19. **difference_between_texts**
|
|
127
|
+
- Compare knowledge graphs from two or more texts and find what's not present in the first graph that's present in the others
|
|
128
|
+
- Use it to find how one text can be enriched with the others
|
|
129
|
+
|
|
130
|
+
20. **analyze_google_search_results**
|
|
131
|
+
- Generate a graph with keywords and topics for Google search results for a certain query
|
|
132
|
+
- Use it to understand the current informational supply (what people find)
|
|
133
|
+
|
|
134
|
+
21. **analyze_related_search_queries**
|
|
135
|
+
- Generate a graph from the search queries suggested by Google for a certain query
|
|
136
|
+
- Use it to understand the current informational demand (what people are looking for)
|
|
137
|
+
|
|
138
|
+
22. **search_queries_vs_search_results**
|
|
139
|
+
- Generate a graph of keyword combinations and topics people tend to search for that do not readily appear in the search results for the same queries
|
|
140
|
+
- Use it to understand what people search for but don't yet find
|
|
141
|
+
|
|
142
|
+
23. **generate_seo_report**
|
|
143
|
+
- Analyze content for SEO optimization by comparing it with Google search results and search queries
|
|
144
|
+
- Identify content gaps and opportunities for better search visibility
|
|
145
|
+
- Get comprehensive analysis of what's in search results but not in your text
|
|
146
|
+
- Discover what people search for but don't find in current results
|
|
147
|
+
|
|
148
|
+
24. **memory_add_relations**
|
|
149
|
+
- Add relations to the KeywordGraph memory from text
|
|
150
|
+
- Automatically detect entities or use [[wikilinks]] syntax to mark them
|
|
151
|
+
- Save memory to a specified graph name for future retrieval
|
|
152
|
+
- Support automatic entity extraction or manual entity marking
|
|
153
|
+
- Provide links to created memory graphs for easy access
|
|
154
|
+
|
|
155
|
+
25. **memory_get_relations**
|
|
156
|
+
- Retrieve relations from KeywordGraph memory for specific entities
|
|
157
|
+
- Search for entity relations using [[wikilinks]] syntax
|
|
158
|
+
- Query specific memory contexts or search across all memory graphs
|
|
159
|
+
- Extract statements and relationships from stored knowledge graphs
|
|
160
|
+
- Support both entity-specific searches and full context retrieval
|
|
161
|
+
|
|
162
|
+
26. **retrieve_from_knowledge_base**
|
|
163
|
+
- Retrieve context from an existing KeywordGraph knowledge graph using GraphRAG
|
|
164
|
+
- Query your knowledge base with a natural language prompt to get relevant statements
|
|
165
|
+
- Include graph summaries for quick overviews of the knowledge structure
|
|
166
|
+
- Optionally retrieve the full graph, statements, or extended analysis
|
|
167
|
+
- Ideal for augmenting LLM responses with domain-specific knowledge
|
|
168
|
+
|
|
169
|
+
27. **search**
|
|
170
|
+
- Search through existing KeywordGraph graphs
|
|
171
|
+
- Also use it to search through the public graphs of a specific user
|
|
172
|
+
- Compatible with ChatGPT Deep Research mode via Developer Mode > Connectors
|
|
173
|
+
|
|
174
|
+
28. **fetch**
|
|
175
|
+
- Fetch a specific search result for a graph
|
|
176
|
+
- Can be used in ChatGPT Deep Research mode via Developer Mode > Connectors
|
|
177
|
+
|
|
178
|
+
_More capabilites coming soon!_
|
|
179
|
+
|
|
180
|
+
### Key Capabilities
|
|
181
|
+
|
|
182
|
+
- **Topic Modeling**: Automatic clustering and categorization of concepts
|
|
183
|
+
- **Content Gap Detection**: Find missing links between concept clusters
|
|
184
|
+
- **Entity Recognition**: Clean extraction of names, places, and organizations
|
|
185
|
+
- **AI Enhancement**: Optional AI-powered topic naming and analysis
|
|
186
|
+
- **Structural Analysis**: Identify influential nodes and community structures
|
|
187
|
+
- **Network Structure Statistics**: Modularity, centrality, betweenness, and other graph metrics
|
|
188
|
+
- **Knowledge Graph Memory**: Save and retrieve knowledge graph memories and analyze them to retrieve key nodes, clusters, and connectors
|
|
189
|
+
|
|
190
|
+
## Knowledge Graph Memory Use Advice
|
|
191
|
+
|
|
192
|
+
KeywordGraph represents any text as a network graph in order to identify the main clusters of ideas and gaps between them. This helps generate advanced insights based on the text's structure. The network is effectively a knowledge graph that can also be used to retrieve complex ontological relations between different entities and concepts. This process is automated in KeywordGraph using the `search` and `fetch` tools along with the other tools that analyze the underlying network.
|
|
193
|
+
|
|
194
|
+
However, you can also easily use KeywordGraph as a more traditional memory server to save and retrieve relations. We use [[wikilinks]] to highlight entities in your text to make your content and graphs compatible with markup syntax and PKM tools such as Obsidian. By default, KeywordGraph will generate the name of the memory graph for you based on the context of the conversation. However, you can modify this default behavior by adding a **system prompt** or **project instruction** into your LLM client.
|
|
195
|
+
|
|
196
|
+
Specifically you can specify to always use a speciic knowlege graph for memories to store everything in one place:
|
|
197
|
+
|
|
198
|
+
```
|
|
199
|
+
Save all memories in the `my-memories` graph in KeywordGraph.
|
|
200
|
+
```
|
|
201
|
+
|
|
202
|
+
Or you can ask KeywordGraph to only save certain entities, e.g. for building social networks:
|
|
203
|
+
|
|
204
|
+
```
|
|
205
|
+
When generating entities, only extract people, companies, and organizations. Ignore everything else.
|
|
206
|
+
```
|
|
207
|
+
|
|
208
|
+
## Installation
|
|
209
|
+
|
|
210
|
+
The easiest and the fastest way to launch the KeywordGraph MCP server is to either use our server URL `https://mcp.keywordgraph.com` for the remote / web applications or to add a manual configuration to your LLM apps if you're running them locally.
|
|
211
|
+
|
|
212
|
+
You can also install the server locally, so you have more control over it. In this case, you can also edit the source files and even create your tools based on the [KeywordGraph API](https://keywordgraph.com/api).
|
|
213
|
+
|
|
214
|
+
Below we describe the two different ways to set up your KeywordGraph MCP server.
|
|
215
|
+
|
|
216
|
+
### 1. Easiest Setup: KeywordGraph MCP Server (via HTTP/SSE)
|
|
217
|
+
|
|
218
|
+
0. **Prerequisites**
|
|
219
|
+
|
|
220
|
+
- Create an account on [KeywordGraph](https://keywordgraph.com) if you don't have it already and get your [KeywordGraph API Key](https://keywordgraph.com/api-access). We offer 14-day free trials.
|
|
221
|
+
|
|
222
|
+
1. **Get the URL**
|
|
223
|
+
|
|
224
|
+
- We currently use the following URL for our MCP server deployed in our infrastructure:
|
|
225
|
+
|
|
226
|
+
```bash
|
|
227
|
+
https://mcp.keywordgraph.com
|
|
228
|
+
```
|
|
229
|
+
|
|
230
|
+
2. **Add the MCP server URL to the Client Tool Where You Want to Use KeywordGraph**
|
|
231
|
+
|
|
232
|
+
- Once you add the URL above to your tool, it will automatically prompt you to authenticate using OAuth in order to be able to access the KeywordGraph MCP hosted on it.
|
|
233
|
+
|
|
234
|
+
4. **Using KeywordGraph Tools in Your Calls**
|
|
235
|
+
|
|
236
|
+
- To use KeywordGraph, see the tools available and simply call them through the chat interface (e.g. "show me the graphs where I talk about this topic" or "get the content gaps from the document I uploaded")
|
|
237
|
+
|
|
238
|
+
- If your client is not using KeywordGraph for some actions, add the instruction to use KeywordGraph explicitly.
|
|
239
|
+
|
|
240
|
+
### 2. Manual Setup: via NPX
|
|
241
|
+
|
|
242
|
+
You can deploy the KeywordGraph server manually via `npx` — a package that allows to execute local and remote Node.Js packages on your computer.
|
|
243
|
+
|
|
244
|
+
The KeywordGraph MCP server is available as an npm package at [https://www.npmjs.com/package/keywordgraph-mcp-server](https://www.npmjs.com/package/keywordgraph-mcp-server) from where you can launch it remotely on your local computer with npx. It will expose its tools to the MCP client that will be using this command to launch the server
|
|
245
|
+
|
|
246
|
+
#### For Claude Desktop / Cursor IDE:
|
|
247
|
+
|
|
248
|
+
Just add this in your Claude's configuration file (Settings > Developer > Edit Config), inside the `"mcpServers"` object where the different servers are listed:
|
|
249
|
+
|
|
250
|
+
```json
|
|
251
|
+
{
|
|
252
|
+
"mcpServers": {
|
|
253
|
+
"keywordgraph": {
|
|
254
|
+
"command": "npx",
|
|
255
|
+
"args": ["-y", "keywordgraph-mcp-server"],
|
|
256
|
+
"env": {
|
|
257
|
+
"KEYWORDGRAPH_API_KEY": "YOUR_KEYWORDGRAPH_API_KEY"
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
```
|
|
263
|
+
|
|
264
|
+
#### For Claude Code
|
|
265
|
+
|
|
266
|
+
To connect the KeywordGraph MCP server to your Claude code, you can use this command. Make sure to provide the correct KeywordGraph API key for your account:
|
|
267
|
+
|
|
268
|
+
```bash
|
|
269
|
+
claude mcp add keywordgraph -s user \
|
|
270
|
+
-- env KEYWORDGRAPH_API_KEY=YOUR_INRANODUS_KEY \
|
|
271
|
+
npx -y keywordgraph-mcp-server
|
|
272
|
+
```
|
|
273
|
+
|
|
274
|
+
### 3. Manual Setup: Launching MCP as a Local Server (for inspection & development)
|
|
275
|
+
|
|
276
|
+
0. **Prerequisites**
|
|
277
|
+
|
|
278
|
+
- Node.js 18+ installed
|
|
279
|
+
- KeywordGraph API key (get yours at [https://keywordgraph.com/api-access](https://keywordgraph.com/api-access))
|
|
280
|
+
|
|
281
|
+
1. **Clone and build the server:**
|
|
282
|
+
|
|
283
|
+
```bash
|
|
284
|
+
git clone https://github.com/yourusername/mcp-server-keywordgraph.git
|
|
285
|
+
cd mcp-server-keywordgraph
|
|
286
|
+
npm install
|
|
287
|
+
npm run build:inspect
|
|
288
|
+
npm run inspect
|
|
289
|
+
```
|
|
290
|
+
|
|
291
|
+
Note that `build:inspect` will generate the `dist/index.js` file which you will then use in your server setup. The standard `npm run build` command will only build a Smithery file.
|
|
292
|
+
|
|
293
|
+
2. **Set up your API key:**
|
|
294
|
+
|
|
295
|
+
Create a `.env` file in the project root:
|
|
296
|
+
|
|
297
|
+
```
|
|
298
|
+
KEYWORDGRAPH_API_KEY=your-api-key-here
|
|
299
|
+
```
|
|
300
|
+
|
|
301
|
+
3. **Inspect the MCP:**
|
|
302
|
+
|
|
303
|
+
```bash
|
|
304
|
+
npm run inspect
|
|
305
|
+
```
|
|
306
|
+
|
|
307
|
+
### Claude Desktop Configuration (macOS)
|
|
308
|
+
|
|
309
|
+
1. Open your Claude Desktop configuration file:
|
|
310
|
+
|
|
311
|
+
```bash
|
|
312
|
+
open ~/Library/Application\ Support/Claude/claude_desktop_config.json
|
|
313
|
+
```
|
|
314
|
+
|
|
315
|
+
2. Add the KeywordGraph server configuration:
|
|
316
|
+
|
|
317
|
+
a. remote launch via `npx`:
|
|
318
|
+
|
|
319
|
+
```json
|
|
320
|
+
{
|
|
321
|
+
"mcpServers": {
|
|
322
|
+
"keywordgraph": {
|
|
323
|
+
"command": "npx",
|
|
324
|
+
"args": ["-y", "keywordgraph-mcp-server"],
|
|
325
|
+
"env": {
|
|
326
|
+
"KEYWORDGRAPH_API_KEY": "YOUR_KEYWORDGRAPH_API_KEY"
|
|
327
|
+
}
|
|
328
|
+
}
|
|
329
|
+
}
|
|
330
|
+
}
|
|
331
|
+
```
|
|
332
|
+
|
|
333
|
+
b. launch this repo with `node`, specify the absolute path to the repo + `/dist/index.js`:
|
|
334
|
+
|
|
335
|
+
```json
|
|
336
|
+
{
|
|
337
|
+
"mcpServers": {
|
|
338
|
+
"keywordgraph": {
|
|
339
|
+
"command": "node",
|
|
340
|
+
"args": ["/absolute/path/to/mcp-server-keywordgraph/dist/index.js"],
|
|
341
|
+
"env": {
|
|
342
|
+
"KEYWORDGRAPH_API_KEY": "your-api-key-here"
|
|
343
|
+
}
|
|
344
|
+
}
|
|
345
|
+
}
|
|
346
|
+
}
|
|
347
|
+
```
|
|
348
|
+
|
|
349
|
+
**Note:** you can leave the `KEYWORDGRAPH_API_KEY` empty in which case you can make 70 free requests after which you will hit quota and will need to add your API key.
|
|
350
|
+
|
|
351
|
+
3. Restart Claude Desktop to load the new server.
|
|
352
|
+
|
|
353
|
+
### Claude Desktop Configuration (Windows)
|
|
354
|
+
|
|
355
|
+
1. Open your Claude Desktop configuration file:
|
|
356
|
+
|
|
357
|
+
```
|
|
358
|
+
%APPDATA%\Claude\claude_desktop_config.json
|
|
359
|
+
```
|
|
360
|
+
|
|
361
|
+
2. Add the KeywordGraph server configuration:
|
|
362
|
+
|
|
363
|
+
a. remote launch via `npx`:
|
|
364
|
+
|
|
365
|
+
```json
|
|
366
|
+
{
|
|
367
|
+
"mcpServers": {
|
|
368
|
+
"keywordgraph": {
|
|
369
|
+
"command": "npx",
|
|
370
|
+
"args": ["-y", "keywordgraph-mcp-server"],
|
|
371
|
+
"env": {
|
|
372
|
+
"KEYWORDGRAPH_API_KEY": "YOUR_KEYWORDGRAPH_API_KEY"
|
|
373
|
+
}
|
|
374
|
+
}
|
|
375
|
+
}
|
|
376
|
+
}
|
|
377
|
+
```
|
|
378
|
+
|
|
379
|
+
b. launch this repo with `node`:
|
|
380
|
+
|
|
381
|
+
```json
|
|
382
|
+
{
|
|
383
|
+
"mcpServers": {
|
|
384
|
+
"keywordgraph": {
|
|
385
|
+
"command": "node",
|
|
386
|
+
"args": ["C:\\path\\to\\mcp-server-keywordgraph\\dist\\index.js"],
|
|
387
|
+
"env": {
|
|
388
|
+
"KEYWORDGRAPH_API_KEY": "your-api-key-here"
|
|
389
|
+
}
|
|
390
|
+
}
|
|
391
|
+
}
|
|
392
|
+
}
|
|
393
|
+
```
|
|
394
|
+
|
|
395
|
+
3. Restart Claude Desktop.
|
|
396
|
+
|
|
397
|
+
### Cursor Configuration
|
|
398
|
+
|
|
399
|
+
### Other MCP-Compatible Applications
|
|
400
|
+
|
|
401
|
+
For other applications supporting MCP, use the following command to start the server via npx:
|
|
402
|
+
|
|
403
|
+
```bash
|
|
404
|
+
KEYWORDGRAPH_API_KEY=your-api-key npx -y keywordgraph-mcp-server
|
|
405
|
+
```
|
|
406
|
+
|
|
407
|
+
or locally
|
|
408
|
+
|
|
409
|
+
```bash
|
|
410
|
+
KEYWORDGRAPH_API_KEY=your-api-key node /path/to/mcp-server-keywordgraph/dist/index.js
|
|
411
|
+
```
|
|
412
|
+
|
|
413
|
+
The server communicates via stdio, so configure your application to run this command and communicate through standard input/output.
|
|
414
|
+
|
|
415
|
+
### Legacy Setup via Smithery
|
|
416
|
+
|
|
417
|
+
KeywordGraph server is also available through Smithery: a repository of MCP servers that has an easy-to-follow installation process for most LLM clients. You will need a separate accout at Smithery though.
|
|
418
|
+
|
|
419
|
+
- Create an account on [Smithery.Ai](https://smithery.ai/) (it's free and you can use your Google or GitHub login)
|
|
420
|
+
|
|
421
|
+
- Then go to the [Smithery KeywordGraph Server](https://smithery.ai/server/@keywordgraph/mcp-server-keywordgraph), click "Configure" at the top right, and add your KeywordGraph API key there.
|
|
422
|
+
|
|
423
|
+
- Go to [Smithery KeywordGraph Server](https://smithery.ai/server/@keywordgraph/mcp-server-keywordgraph) and get the URL link from Smithery [https://server.smithery.ai/@keywordgraph/mcp-server-keywordgraph/mcp](https://server.smithery.ai/@keywordgraph/mcp-server-keywordgraph/mcp) for the server or use one of their automatic setup tools for Claude or Cursor.
|
|
424
|
+
|
|
425
|
+
- You may need to get your separate Smithery API key and Smithery proile link to make this work.
|
|
426
|
+
|
|
427
|
+
##### For Cursor:
|
|
428
|
+
|
|
429
|
+
```json
|
|
430
|
+
// e.g. Cursor will access directly the server via Smithery
|
|
431
|
+
"mcpServers": {
|
|
432
|
+
"mcp-server-keywordgraph": {
|
|
433
|
+
"type": "http",
|
|
434
|
+
"url": "https://server.smithery.ai/@keywordgraph/mcp-server-keywordgraph/mcp?api_key=YOUR_SMITHERY_KEY&profile=YOUR_SMITHERY_PROFILE",
|
|
435
|
+
"headers": {}
|
|
436
|
+
}
|
|
437
|
+
}
|
|
438
|
+
```
|
|
439
|
+
|
|
440
|
+
#### For Claude:
|
|
441
|
+
|
|
442
|
+
```json
|
|
443
|
+
// Claude uses a slightly different implementation
|
|
444
|
+
// Fot this, it launches the MCP server on your local machine
|
|
445
|
+
"mcpServers": {
|
|
446
|
+
"mcp-server-keywordgraph": {
|
|
447
|
+
"command": "npx",
|
|
448
|
+
"args": [
|
|
449
|
+
"-y",
|
|
450
|
+
"@smithery/cli@latest",
|
|
451
|
+
"run",
|
|
452
|
+
"@keywordgraph/mcp-server-keywordgraph",
|
|
453
|
+
"--key",
|
|
454
|
+
"YOUR_SMITHERY_KEY",
|
|
455
|
+
"--profile",
|
|
456
|
+
"YOUR_SMITHERY_PROFILE"
|
|
457
|
+
]
|
|
458
|
+
}
|
|
459
|
+
}
|
|
460
|
+
```
|
|
461
|
+
|
|
462
|
+
**Note**, in both cases, you'll automatically get the `YOUR_SMITHERY_KEY` and `YOUR_SMITHERY_PROFILE` values from Smithery when you copy the URL with credentials. These are not your KeywordGraph API keys. You can use the KeywordGraph API server without the API for the first 70 calls. Then you can add it to your Smithery profile and it will automatically connect to your account using the link above.
|
|
463
|
+
|
|
464
|
+
## Usage Examples
|
|
465
|
+
|
|
466
|
+
Once installed, you can ask Claude to:
|
|
467
|
+
|
|
468
|
+
- "Use KeywordGraph to analyze this text and show me the main topics"
|
|
469
|
+
- "Generate a knowledge graph from this document"
|
|
470
|
+
- "Find content gaps in this article"
|
|
471
|
+
- "Retrieve my existing graph called 'Research Notes' from KeywordGraph"
|
|
472
|
+
- "What are the structural gaps in this text?"
|
|
473
|
+
- "Identify the most influential concepts in this content"
|
|
474
|
+
|
|
475
|
+
## Development
|
|
476
|
+
|
|
477
|
+
### Running in Development Mode
|
|
478
|
+
|
|
479
|
+
```bash
|
|
480
|
+
npm run dev
|
|
481
|
+
```
|
|
482
|
+
|
|
483
|
+
### Using the MCP Inspector
|
|
484
|
+
|
|
485
|
+
Test the server with the MCP Inspector:
|
|
486
|
+
|
|
487
|
+
```bash
|
|
488
|
+
|
|
489
|
+
npm run build:inspect
|
|
490
|
+
npm run inspect
|
|
491
|
+
```
|
|
492
|
+
|
|
493
|
+
### Building from Source
|
|
494
|
+
|
|
495
|
+
```bash
|
|
496
|
+
npm run build
|
|
497
|
+
```
|
|
498
|
+
|
|
499
|
+
### Watching for Changes
|
|
500
|
+
|
|
501
|
+
```bash
|
|
502
|
+
npm run watch
|
|
503
|
+
```
|
|
504
|
+
|
|
505
|
+
## API Documentation
|
|
506
|
+
|
|
507
|
+
### generate_knowledge_graph
|
|
508
|
+
|
|
509
|
+
Analyzes text and generates a knowledge graph.
|
|
510
|
+
|
|
511
|
+
**Parameters:**
|
|
512
|
+
|
|
513
|
+
- `text` (string, required): The text to analyze
|
|
514
|
+
- `includeStatements` (boolean): Include original statements in response
|
|
515
|
+
- `modifyAnalyzedText` (string): Text modification options ("none", "entities", "lemmatize")
|
|
516
|
+
|
|
517
|
+
### analyze_existing_graph_by_name
|
|
518
|
+
|
|
519
|
+
Retrieves and analyzes an existing graph from your KeywordGraph account.
|
|
520
|
+
|
|
521
|
+
**Parameters:**
|
|
522
|
+
|
|
523
|
+
- `graphName` (string, required): Name of the existing graph
|
|
524
|
+
- `includeStatements` (boolean): Include statements in response
|
|
525
|
+
- `includeGraphSummary` (boolean): Include graph summary
|
|
526
|
+
|
|
527
|
+
### analyze_text
|
|
528
|
+
|
|
529
|
+
Analyze a text, URL, or YouTube transcript. Extract and analyze a graph from text or URL; provide either text or url.
|
|
530
|
+
|
|
531
|
+
**Parameters:**
|
|
532
|
+
|
|
533
|
+
- `text` (string, optional): Text to analyze. Provide either this or url.
|
|
534
|
+
- `url` (string, optional): URL to fetch content from (e.g. webpage or YouTube transcript). Provide either this or text.
|
|
535
|
+
- `includeStatements` (boolean): Include processed statements in response
|
|
536
|
+
- `includeGraph` (boolean): Include full graph structure in response
|
|
537
|
+
- `addNodesAndEdges` (boolean): Include nodes and edges in response
|
|
538
|
+
- `includeGraphSummary` (boolean): Include AI-generated graph summary for RAG prompt augmentation
|
|
539
|
+
- `modifyAnalyzedText` (string): Entity detection — "none", "detectEntities", or "extractEntitiesOnly"
|
|
540
|
+
|
|
541
|
+
### generate_content_gaps
|
|
542
|
+
|
|
543
|
+
Identifies content gaps and missing connections in text.
|
|
544
|
+
|
|
545
|
+
**Parameters:**
|
|
546
|
+
|
|
547
|
+
- `text` (string, required): The text to analyze for gaps
|
|
548
|
+
|
|
549
|
+
## Progress Notifications
|
|
550
|
+
|
|
551
|
+
For long-running operations (like SEO analysis), the MCP server supports **real-time progress notifications** that provide intermediary feedback to AI agents. This allows agents to:
|
|
552
|
+
|
|
553
|
+
- Track the progress of multi-step operations
|
|
554
|
+
- Display status messages to users
|
|
555
|
+
- Understand what's happening during lengthy analyses
|
|
556
|
+
|
|
557
|
+
### Implementation
|
|
558
|
+
|
|
559
|
+
The server implements MCP progress notifications using:
|
|
560
|
+
|
|
561
|
+
1. **ToolHandlerContext**: All tool handlers can receive an optional context parameter containing the server instance and progress token
|
|
562
|
+
2. **ProgressReporter**: A utility class that simplifies sending progress updates with percentages and messages
|
|
563
|
+
3. **Wrapped Handlers**: Tool registration automatically injects the server context into handlers
|
|
564
|
+
|
|
565
|
+
### Example Usage in Tools
|
|
566
|
+
|
|
567
|
+
```typescript
|
|
568
|
+
import { ProgressReporter } from "../utils/progress.js";
|
|
569
|
+
import { ToolHandlerContext } from "../types/index.js";
|
|
570
|
+
|
|
571
|
+
handler: async (params: ParamType, context: ToolHandlerContext = {}) => {
|
|
572
|
+
const progress = new ProgressReporter(context);
|
|
573
|
+
|
|
574
|
+
await progress.report(25, "Fetching data from API...");
|
|
575
|
+
// Do work
|
|
576
|
+
|
|
577
|
+
await progress.report(75, "Analyzing results...");
|
|
578
|
+
// More work
|
|
579
|
+
|
|
580
|
+
await progress.report(100, "Complete!");
|
|
581
|
+
return results;
|
|
582
|
+
};
|
|
583
|
+
```
|
|
584
|
+
|
|
585
|
+
The `generate_seo_report` tool demonstrates this pattern with 6 major progress checkpoints that provide detailed status updates throughout the multi-step analysis process.
|
|
586
|
+
|
|
587
|
+
## Troubleshooting
|
|
588
|
+
|
|
589
|
+
### Server doesn't appear in Claude
|
|
590
|
+
|
|
591
|
+
1. Verify the configuration file path is correct
|
|
592
|
+
2. Check that the API key is valid
|
|
593
|
+
3. Ensure Node.js is in your system PATH
|
|
594
|
+
4. Restart Claude Desktop completely
|
|
595
|
+
|
|
596
|
+
### API Key Issues
|
|
597
|
+
|
|
598
|
+
- Get your API key at: [https://keywordgraph.com/api-access](https://keywordgraph.com/api-access)
|
|
599
|
+
- Ensure the key is correctly set in the configuration
|
|
600
|
+
- Check that the key has not expired
|
|
601
|
+
|
|
602
|
+
### Build Errors
|
|
603
|
+
|
|
604
|
+
```bash
|
|
605
|
+
# Clean install
|
|
606
|
+
rm -rf node_modules package-lock.json
|
|
607
|
+
npm install
|
|
608
|
+
npm run build
|
|
609
|
+
```
|
|
610
|
+
|
|
611
|
+
## Resources
|
|
612
|
+
|
|
613
|
+
- [KeywordGraph Website](https://keywordgraph.com)
|
|
614
|
+
- [KeywordGraph MCP](https://keywordgraph.com/mcp)
|
|
615
|
+
- [KeywordGraph API Documentation](https://keywordgraph.com/api-access)
|
|
616
|
+
- [MCP Protocol Documentation](https://modelcontextprotocol.io)
|
|
617
|
+
- [Graph Theory Concepts](https://noduslabs.com/research/)
|
|
618
|
+
|
|
619
|
+
## License
|
|
620
|
+
|
|
621
|
+
MIT
|
|
622
|
+
|
|
623
|
+
## Support
|
|
624
|
+
|
|
625
|
+
For issues related to:
|
|
626
|
+
|
|
627
|
+
- This MCP server: Open an issue in this repository
|
|
628
|
+
- KeywordGraph API: Contact support@keywordgraph.com
|
|
629
|
+
- MCP Protocol: Visit the [MCP community](https://modelcontextprotocol.io)
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
// Brand-specific entry for the published `infranodus-mcp-server` package.
|
|
3
|
+
// Bakes in BRAND so `npx infranodus-mcp-server` runs as InfraNodus without
|
|
4
|
+
// the caller needing to set any env var. An explicit BRAND still wins.
|
|
5
|
+
// NOTE: must use dynamic import — a static import would be hoisted and run
|
|
6
|
+
// before this assignment, so brand.js would read BRAND too early.
|
|
7
|
+
process.env.BRAND ||= "infranodus";
|
|
8
|
+
await import("./mcp-server.js");
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
// Brand-specific entry for the published `keywordgraph-mcp-server` package.
|
|
3
|
+
// Bakes in BRAND so `npx keywordgraph-mcp-server` runs as KeywordGraph without
|
|
4
|
+
// the caller needing to set any env var. An explicit BRAND still wins.
|
|
5
|
+
// NOTE: must use dynamic import — a static import would be hoisted and run
|
|
6
|
+
// before this assignment, so brand.js would read BRAND too early.
|
|
7
|
+
process.env.BRAND ||= "keywordgraph";
|
|
8
|
+
await import("./mcp-server.js");
|