evipedia-mcp-dev 0.1.22 → 0.1.23

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.
Files changed (2) hide show
  1. package/dist/index.js +5 -6
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -82,11 +82,11 @@ async function searchReviews(query, limit = 20) {
82
82
  const bySlug = new Map(reviewsIndex.map((r) => [toSlug(r.permalink).toLowerCase(), r]));
83
83
  const byUrl = new Map(searchIndex.map((e) => [e.url, e]));
84
84
  const idx = buildLunrIndex(searchIndex);
85
- const results = runLunrQuery(idx, query);
86
- return results.slice(0, limit).map((res) => {
85
+ const hits = runLunrQuery(idx, query).slice(0, limit);
86
+ return hits.map((res) => {
87
87
  const review = bySlug.get(toSlug(res.ref).toLowerCase());
88
88
  if (review) {
89
- return { name: review.canonical_name, url: review.permalink, conclusion: review.er_conclusion, category: review.category };
89
+ return { name: review.canonical_name, url: review.permalink, category: review.category };
90
90
  }
91
91
  const e = byUrl.get(res.ref);
92
92
  return { name: e?.short_topic ?? res.ref, url: e?.url ?? res.ref, category: e?.ep_category };
@@ -99,15 +99,14 @@ function createServer() {
99
99
  );
100
100
  server2.tool(
101
101
  "search_reviews",
102
- "Search evipedia.ai evidence reviews by name, synonym, keyword, or category. Returns matching reviews with their URLs and conclusions.",
102
+ "Search evipedia.ai evidence reviews by name, synonym, keyword, or category. A discovery tool: returns the matching reviews (name + URL) ranked by relevance so you can tell whether a review exists. To read one, pass its slug to get_conclusion (quick bottom line) or get_review (full Markdown).",
103
103
  { query: z.string().describe("Search query \u2014 intervention name, synonym, drug class, or category") },
104
104
  async ({ query }) => {
105
105
  const matches = await searchReviews(query);
106
106
  if (matches.length === 0) {
107
107
  return { content: [{ type: "text", text: "No reviews found." }] };
108
108
  }
109
- const text = matches.map((m) => m.conclusion ? `**${m.name}** \u2014 ${m.url}
110
- ${m.conclusion}` : `**${m.name}** \u2014 ${m.url}`).join("\n\n---\n\n");
109
+ const text = matches.map((m) => `**${m.name}** \u2014 ${m.url}`).join("\n");
111
110
  return { content: [{ type: "text", text }] };
112
111
  }
113
112
  );
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "evipedia-mcp-dev",
3
- "version": "0.1.22",
3
+ "version": "0.1.23",
4
4
  "description": "Internal development build of evipedia-mcp. Not for public use.",
5
5
  "type": "module",
6
6
  "bin": {