@mistereman22/osrs-wiki-mcp-server 1.0.3 → 1.0.4

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.
@@ -1 +1 @@
1
- {"version":3,"file":"resources.d.ts","sourceRoot":"","sources":["../src/resources.ts"],"names":[],"mappings":"AA8CA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAE9D,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,SAAS,GAAG,IAAI,CAmBzD"}
1
+ {"version":3,"file":"resources.d.ts","sourceRoot":"","sources":["../src/resources.ts"],"names":[],"mappings":"AAyEA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAG9D,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,SAAS,GAAG,IAAI,CAyBzD"}
package/dist/resources.js CHANGED
@@ -6,42 +6,74 @@ import { readFile } from 'node:fs/promises';
6
6
  import { fileURLToPath } from 'node:url';
7
7
  const RESOURCES = [
8
8
  {
9
- name: 'bucket-index',
10
- uri: 'context://bucket-index',
11
- file: fileURLToPath(new URL('../../resources/bucket-index.md', import.meta.url)),
12
- title: 'Bucket Index',
13
- description: 'Curated hint list of known Bucket buckets on the OSRS wiki (names, query forms, purposes). Not authoritative - if nothing matches, fall back to discovery via search-page-by-prefix in the Bucket: namespace.',
9
+ name: 'tool-selection',
10
+ uri: 'context://tool-selection',
11
+ file: fileURLToPath(new URL('../../resources/tool-selection.md', import.meta.url)),
12
+ title: 'Tool Selection Guide',
13
+ description: 'Top-level routing: which tool to use for each question type. Decision tree mapping queries to tools + required resources. Read this FIRST.',
14
14
  mimeType: 'text/markdown',
15
15
  },
16
16
  {
17
- name: 'wiki-navigation',
18
- uri: 'context://wiki-navigation',
19
- file: fileURLToPath(new URL('../../resources/wiki-navigation.md', import.meta.url)),
20
- title: 'Wiki Navigation Guide',
21
- description: 'How to find pages on the OSRS Wiki: namespaces, category structure, redirect handling, disambiguation patterns, and page structure by type.',
17
+ name: 'bucket-catalog',
18
+ uri: 'context://bucket-catalog',
19
+ file: fileURLToPath(new URL('../../resources/bucket-catalog.md', import.meta.url)),
20
+ title: 'Bucket Catalog',
21
+ description: 'Complete reference list of all known Bucket buckets on the OSRS Wiki with query names, page titles, and contents. For usage patterns, see bucket-query-guide.',
22
22
  mimeType: 'text/markdown',
23
23
  },
24
24
  {
25
- name: 'search-strategies',
26
- uri: 'context://search-strategies',
27
- file: fileURLToPath(new URL('../../resources/search-strategies.md', import.meta.url)),
28
- title: 'Search Strategies',
29
- description: 'When and how to use search-page, search-page-by-prefix, and get-page metadata for efficient wiki queries. Includes decision tree and common patterns.',
25
+ name: 'bucket-query-guide',
26
+ uri: 'context://bucket-query-guide',
27
+ file: fileURLToPath(new URL('../../resources/bucket-query-guide.md', import.meta.url)),
28
+ title: 'Bucket Query Guide',
29
+ description: 'How to use bucket-query effectively: when to use it, mandatory best practices, exact-match rules, common patterns, limitations, and troubleshooting.',
30
+ mimeType: 'text/markdown',
31
+ },
32
+ {
33
+ name: 'namespace-category-guide',
34
+ uri: 'context://namespace-category-guide',
35
+ file: fileURLToPath(new URL('../../resources/namespace-category-guide.md', import.meta.url)),
36
+ title: 'Namespace & Category Guide',
37
+ description: 'Category structure, namespace IDs, DPL/template discovery workflow for get-category-members, get-site-info, get-links-here. When to use category vs search.',
38
+ mimeType: 'text/markdown',
39
+ },
40
+ {
41
+ name: 'search-guide',
42
+ uri: 'context://search-guide',
43
+ file: fileURLToPath(new URL('../../resources/search-guide.md', import.meta.url)),
44
+ title: 'Search Guide',
45
+ description: 'Tool selection, broad-first search strategy, canonical page heuristic, section discovery for search-page, search-page-by-prefix, get-page. Includes decision tree and fallback chain.',
46
+ mimeType: 'text/markdown',
47
+ },
48
+ {
49
+ name: 'page-structure',
50
+ uri: 'context://page-structure',
51
+ file: fileURLToPath(new URL('../../resources/page-structure.md', import.meta.url)),
52
+ title: 'Page Structure Guide',
53
+ description: 'Page types, key sections, infobox-to-bucket mapping for get-page. Redirects, disambiguation, large page strategy, common prefixes.',
30
54
  mimeType: 'text/markdown',
31
55
  },
32
56
  ];
57
+ import { logger } from '@professional-wiki/mediawiki-mcp-server/dist/runtime/logger.js';
33
58
  export function registerResources(server) {
34
59
  for (const resource of RESOURCES) {
60
+ logger.debug(`Registering resource: ${resource.name} -> ${resource.file}`);
35
61
  server.registerResource(resource.name, resource.uri, {
36
62
  title: resource.title,
37
63
  description: resource.description,
38
64
  mimeType: resource.mimeType,
39
65
  }, async (uri) => {
40
- const text = await readFile(resource.file, 'utf8');
41
- const href = typeof uri === 'string' ? uri : uri.href;
42
- return {
43
- contents: [{ uri: href, mimeType: resource.mimeType, text }],
44
- };
66
+ try {
67
+ const text = await readFile(resource.file, 'utf8');
68
+ const href = typeof uri === 'string' ? uri : uri.href;
69
+ return {
70
+ contents: [{ uri: href, mimeType: resource.mimeType, text }],
71
+ };
72
+ }
73
+ catch (error) {
74
+ logger.error(`Failed to read resource ${resource.name} from ${resource.file}: ${error instanceof Error ? error.message : String(error)}`);
75
+ throw error;
76
+ }
45
77
  });
46
78
  }
47
79
  }
@@ -1 +1 @@
1
- {"version":3,"file":"resources.js","sourceRoot":"","sources":["../src/resources.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAWzC,MAAM,SAAS,GAAqB;IACnC;QACC,IAAI,EAAE,cAAc;QACpB,GAAG,EAAE,wBAAwB;QAC7B,IAAI,EAAE,aAAa,CAAC,IAAI,GAAG,CAAC,iCAAiC,EAAE,OAAO,IAAI,CAAC,GAAG,CAAC,CAAC;QAChF,KAAK,EAAE,cAAc;QACrB,WAAW,EACV,+MAA+M;QAChN,QAAQ,EAAE,eAAe;KACzB;IACD;QACC,IAAI,EAAE,iBAAiB;QACvB,GAAG,EAAE,2BAA2B;QAChC,IAAI,EAAE,aAAa,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AAC,2BAA2B,QAAQ,CAAC,IAAI,SAAS,QAAQ,CAAC,IAAI,KAAK,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;gBAC1I,MAAM,KAAK,CAAC;YACb,CAAC;QACF,CAAC,CACD,CAAC;IACH,CAAC;AACF,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../src/server.ts"],"names":[],"mappings":"AA2BA,qBAAa,cAAe,SAAQ,KAAK;CAAG;AAM5C,cAAM,oBAAoB;;IACzB,OAAO,CAAC,QAAQ,CAAC,WAAW,CAAS;IACrC,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAS;IAClC,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAS;IACnC,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAS;IAC/B,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAgB;IAEvC,YAAY,WAAW,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAKlF;IAQK,OAAO,IAAI,OAAO,CAAC,IAAI,CAAC,CAkB7B;CACD;AASD,eAAO,MAAM,eAAe,sBAK3B,CAAC;AAyDF,eAAO,MAAM,WAAW,yBAAyB,CAAC;AAClD,eAAO,MAAM,cAAc,UAAU,CAAC;AA4DtC;;GAEG;AACH,OAAO,UAAU,CAAC;AAElB,OAAO,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAWzD,wBAAsB,WAAW,IAAI,OAAO,CAAC,SAAS,CAAC,CAgDtD"}
1
+ {"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../src/server.ts"],"names":[],"mappings":"AA2BA,qBAAa,cAAe,SAAQ,KAAK;CAAG;AAM5C,cAAM,oBAAoB;;IACzB,OAAO,CAAC,QAAQ,CAAC,WAAW,CAAS;IACrC,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAS;IAClC,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAS;IACnC,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAS;IAC/B,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAgB;IAEvC,YAAY,WAAW,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAKlF;IAQK,OAAO,IAAI,OAAO,CAAC,IAAI,CAAC,CAkB7B;CACD;AASD,eAAO,MAAM,eAAe,sBAK3B,CAAC;AAyDF,eAAO,MAAM,WAAW,yBAAyB,CAAC;AAClD,eAAO,MAAM,cAAc,UAAU,CAAC;AAwFtC;;GAEG;AACH,OAAO,UAAU,CAAC;AAElB,OAAO,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAWzD,wBAAsB,WAAW,IAAI,OAAO,CAAC,SAAS,CAAC,CAgDtD"}
package/dist/server.js CHANGED
@@ -118,8 +118,36 @@ const SERVER_INSTRUCTIONS = [
118
118
  'The wiki target is fixed by the package: no tool can add, remove, or switch wikis.',
119
119
  'Deployment is read-only and anonymous. Outbound calls use User-Agent `' + BASE_USER_AGENT + ' <MCP_CONTACT>\`.',
120
120
  'MediaWiki tools follow upstream behavior from @professional-wiki/mediawiki-mcp-server.',
121
- 'For structured data (item/monster stats, prices, drops, quest info, gear recommendations) PREFER \'bucket-query\' over reading wiki pages: buckets return semantic rows directly. BEFORE any bucket-query, read \'context://bucket-index\' to find the correct bucket name and fields - it costs no API traffic. If no match there, fall back to runtime discovery - \'search-page-by-prefix\' in the Bucket: namespace, then \'get-page\' for the schema.',
122
- 'For wiki navigation and search strategy: read \'context://wiki-navigation\' (namespaces, categories, page structure) and \'context://search-strategies\' (tool selection, section discovery) before searching.',
121
+ '',
122
+ 'TOOL SELECTION — DECIDE FIRST, THEN READ THE RELEVANT RESOURCE:',
123
+ '',
124
+ '| If the user asks for... | Use this tool | Read this resource first |',
125
+ '|-------------------------|---------------|--------------------------|',
126
+ '| Structured data: item stats, GE prices, monster stats, drop rates, quest requirements, gear recommendations, varbits, shop info | bucket-query | context://bucket-catalog (find bucket + fields), then context://bucket-query-guide (usage patterns) |',
127
+ '| Canonical lists: all bosses, all quests, all items, all updates, all monsters in category | get-category-members | context://namespace-category-guide (category structure, namespace IDs) |',
128
+ '| Pages in a custom namespace (e.g., Update: game updates) | get-site-info + get-category-members | context://namespace-category-guide (DPL/template discovery workflow) |',
129
+ '| Unstructured content: lore, mechanics, walkthroughs, guides | search-page / get-page | context://search-guide (broad-first, canonical page heuristic) |',
130
+ '| Exact page title known | get-page | context://page-structure (page types, sections) |',
131
+ '| Backlinks / transclusions / file usage | get-links-here | context://namespace-category-guide |',
132
+ '',
133
+ 'START HERE: Read context://tool-selection first for the complete decision tree and quick patterns.',
134
+ '',
135
+ 'MANDATORY: Read the relevant resource BEFORE using each tool:',
136
+ '',
137
+ 'For search-page, search-page-by-prefix:',
138
+ ' 1. context://search-guide — tool selection, broad-first search, canonical page heuristic, rate limits',
139
+ '',
140
+ 'For get-page:',
141
+ ' 1. context://search-guide — section discovery via metadata=true + section=N',
142
+ ' 2. context://page-structure — page structure by type, redirects, disambiguation',
143
+ '',
144
+ 'For get-category-members, get-site-info, get-links-here:',
145
+ ' 1. context://namespace-category-guide — category structure, namespace IDs, DPL/template discovery workflow',
146
+ '',
147
+ 'For bucket-query:',
148
+ ' 1. context://bucket-catalog — find correct bucket name and fields (costs no API traffic)',
149
+ ' 2. context://bucket-query-guide — mandatory best practices, exact-match rules, common patterns, limitations',
150
+ '',
123
151
  'CRITICAL: ALWAYS use .select() and .where() in bucket-query. NEVER run unfiltered queries - they return thousands of rows, bloat context, and strain the wiki. ALWAYS use .select("field1","field2") to limit columns and .where("field","value") to filter rows. Use .limit(N) for pagination.',
124
152
  'bucket-query uses EXACT MATCH ONLY - no wildcards. To find exact values: 1) search-page for the term, 2) use exact result in bucket-query. Example: "Bob\'s Axe Shop" -> search-page "bob axe" -> gets "Bob\'s Brilliant Axes" -> bucket("infobox_shop").where("shop_name","Bob\'s Brilliant Axes")',
125
153
  'If a bucket query returns no results: CHECK THE SCHEMA (get-page Bucket:<name>) - wrong field name or wrong exact value. Fix the query. If the bucket schema does not support your query (e.g., dropsline only queryable by item_name, not source), use the appropriate wiki page directly.',
@@ -129,7 +157,7 @@ const SERVER_INSTRUCTIONS = [
129
157
  ' * Monster stats -> bucket("infobox_monster").select("name","combat_level","hitpoints").where("name","Hydra").run()',
130
158
  ' * Item stats -> bucket("infobox_item").select("item_name","value","high_alch").where("item_name","Abyssal whip").run()',
131
159
  ' * Drop sources for an item -> bucket("dropsline").select("item_name","drop_json").where("item_name","Abyssal whip").run() (drop_json contains "Dropped from" as JSON text)',
132
- ' * What drops from a source (boss/chest/activity) -> bucket CANNOT do this; use get-page on the source page directly (see context://bucket-index for patterns)',
160
+ ' * What drops from a source (boss/chest/activity) -> bucket CANNOT do this; use get-page on the source page directly (see context://bucket-query-guide for patterns)',
133
161
  ' * Quest requirements -> bucket("quest").select("name","requirements").where("name","Dragon Slayer I").run()',
134
162
  ' * Varbits -> bucket("varbit").select("name","value").where("name","hydra_task").run()',
135
163
  ' * Shop lookup -> bucket("infobox_shop").select("shop_name","location","owner").where("shop_name","Bob\'s Brilliant Axes").run()',
@@ -1 +1 @@
1
- {"version":3,"file":"server.js","sourceRoot":"","sources":["../src/server.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,mEAAmE,CAAC;AACnG,OAAO,EACN,QAAQ,EACR,gBAAgB,GAChB,MAAM,6DAA6D,CAAC;AACrE,OAAO,EAAE,cAAc,EAAE,MAAM,wEAAwE,CAAC;AAExG,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAQ3C;;;;;GAKG;AAEH,MAAM,SAAS,GAAG,MAAM,CAAC;AACzB,MAAM,WAAW,GAAG,MAAM,CAAC;AAC3B,MAAM,iBAAiB,GAAG,EA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IAAI;QACJ,OAAO,EAAE,WAAW,CAAC,OAAO,CAAC,GAAG,EAAE,OAAO,CAAC;KAC1C,CAAC,CAAC;IAEH,MAAM,MAAM,GAAG,IAAI,SAAS,CAC3B;QACC,IAAI,EAAE,WAAW;QACjB,KAAK,EAAE,YAAY;QACnB,OAAO,EAAE,cAAc;QACvB,WAAW,EAAE,kBAAkB;KAC/B,EACD;QACC,YAAY,EAAE;YACb,SAAS,EAAE,EAAE,WAAW,EAAE,IAAI,EAAE;YAChC,KAAK,EAAE,EAAE,WAAW,EAAE,IAAI,EAAE;SAC5B;QACD,YAAY,EAAE,mBAAmB;QACjC,UAAU,EAAE;YACX,YAAY,EAAE,UAAU;YACxB,gBAAgB,EAAE,UAAU;YAC5B,0BAA0B,EAAE,UAAU;YACtC,gBAAgB,EAAE,UAAU;YAC5B,iBAAiB,EAAE,UAAU;SAC7B;KACD,CACD,CAAC;IAEF,MAAM,EAAE,UAAU,EAAE,GAAG,kBAAkB,CAAC,MAA2H,EAAE,GAA0E,CAAC,CAAC;IACnP,iBAAiB,CAAC,MAAM,CAAC,CAAC;IAE1B,mEAAmE;IACnE,wBAAwB,CAAC,MAAM,CAAC,CAAC;IAEjC,mFAAmF;IACnF,MAAM,UAAU,EAAE,CAAC;IAEnB,OAAO,MAAM,CAAC;AACf,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mistereman22/osrs-wiki-mcp-server",
3
- "version": "1.0.3",
3
+ "version": "1.0.4",
4
4
  "description": "MCP server for the Old School RuneScape Wiki: the full MediaWiki MCP tool surface against a pinned read-only wiki.",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -0,0 +1,82 @@
1
+ # Bucket Catalog (Reference)
2
+
3
+ > Complete list of known buckets on OSRS Wiki. For usage patterns, see `context://bucket-query-guide`.
4
+
5
+ ## Bucket Index
6
+
7
+ | Query as | Page | Holds |
8
+ | --- | --- | --- |
9
+ | `bucket("bountytaskline")` | Bucket:Bountytaskline | Bounty Hunter task line entries |
10
+ | `bucket("clue_equipment")` | Bucket:Clue equipment | Equipment associated with clue scroll steps |
11
+ | `bucket("clue_info")` | Bucket:Clue info | Clue scroll metadata/step info |
12
+ | `bucket("collection_log_source")` | Bucket:Collection log source | Collection log sources per item: item_id, item_name, sources, rates, kinds. **Only queryable by item_name** |
13
+ | `bucket("combat_achievement")` | Bucket:Combat achievement | Combat achievement tasks, tiers, requirements |
14
+ | `bucket("couriertaskline")` | Bucket:Couriertaskline | Courier activity task line entries |
15
+ | `bucket("demonicpactleaguetask")` | Bucket:Demonicpactleaguetask | Demonic Pact league task entries |
16
+ | `bucket("dependency_list")` | Bucket:Dependency list | Item/object dependency relations |
17
+ | `bucket("drop_table_sources")` | Bucket:Drop table sources | Shared drop tables (rare, gem, herb) and roll/rarity data |
18
+ | `bucket("dropsline")` | Bucket:Dropsline | Drop table line entries: item_name, drop_json (JSON with "Dropped from", rarity, quantity). **Only queryable by item_name** |
19
+ | `bucket("exchange")` | Bucket:Exchange | Grand Exchange prices (name, value, high/low, volumes) |
20
+ | `bucket("feedback")` | Bucket:Feedback | Wiki feedback entries (site-internal) |
21
+ | `bucket("ge_index_header")` | Bucket:Ge index header | GE index header/snapshot metadata |
22
+ | `bucket("infobox_activity")` | Bucket:Infobox activity | Skilling/activity infobox data |
23
+ | `bucket("infobox_bonuses")` | Bucket:Infobox bonuses | Equipment combat stats and bonuses |
24
+ | `bucket("infobox_construction")` | Bucket:Infobox construction | Construction object/buildable data |
25
+ | `bucket("infobox_grid_master_unlock")` | Bucket:Infobox grid master unlock | Grid Master unlock data |
26
+ | `bucket("infobox_item")` | Bucket:Infobox item | Core item data: item_name, item_id, examine, high_alchemy_value, value, weight, buy_limit, is_members_only, tradeable, image, league_region, release_date, removal_date, quest, version_anchor |
27
+ | `bucket("infobox_location")` | Bucket:Infobox location | Location/area data |
28
+ | `bucket("infobox_monster")` | Bucket:Infobox monster | Monster combat stats: name, combat_level, hitpoints, max_hit, slayer_level, slayer_experience, slayer_category, assigned_by, attack/defence bonuses, attack_speed, poisonous, attribute, attack_style, respawn_time, experience_bonus, flat_armour, magic_resistance, size, attack/strength/defence/ranged/magic levels, attack_bonus, strength_bonus, range_strength_bonus, magic_damage_bonus, poison/venom/freeze/burn/cannon/thrall resistance, elemental_weakness, elemental_weakness_percent |
29
+ | `bucket("infobox_npc")` | Bucket:Infobox npc | NPC data: id, combat level, examine |
30
+ | `bucket("infobox_pure")` | Bucket:Infobox pure | Pure-entity infobox data (verify schema) |
31
+ | `bucket("infobox_scenery")` | Bucket:Infobox scenery | Scenery/object entity data |
32
+ | `bucket("infobox_ship_part")` | Bucket:Infobox ship part | Ship part data |
33
+ | `bucket("infobox_shop")` | Bucket:Infobox shop | Shop data: shop_name, location, owner, specialty, shop_version, is_members_only |
34
+ | `bucket("infobox_spell")` | Bucket:Infobox spell | Spell data: requirements, effects, costs |
35
+ | `bucket("interface")` | Bucket:Interface | Game interface definitions |
36
+ | `bucket("item_id")` | Bucket:Item id | Item name to id mappings |
37
+ | `bucket("locline")` | Bucket:Locline | Location line entries |
38
+ | `bucket("logs")` | Bucket:Logs | Woodcutting log/tree data |
39
+ | `bucket("map")` | Bucket:Map | Map marker/region data |
40
+ | `bucket("mine")` | Bucket:Mine | Mining node/rock data |
41
+ | `bucket("mmg_output")` | Bucket:Mmg output | Money making guide output calculations |
42
+ | `bucket("money_making_guide")` | Bucket:Money making guide | Money making methods: profit, requirements |
43
+ | `bucket("music")` | Bucket:Music | Music track unlock data |
44
+ | `bucket("music_file")` | Bucket:Music file | Music file metadata |
45
+ | `bucket("music_map")` | Bucket:Music map | Music tracks by region/map area |
46
+ | `bucket("music_versions")` | Bucket:Music versions | Music version/history entries |
47
+ | `bucket("npc_id")` | Bucket:Npc id | NPC name to id mappings |
48
+ | `bucket("object_id")` | Bucket:Object id | Object/scenery id mappings |
49
+ | `bucket("quest")` | Bucket:Quest | Quest data: requirements, rewards, difficulty |
50
+ | `bucket("recipe")` | Bucket:Recipe | Creation/processing recipes: inputs, outputs, skills |
51
+ | `bucket("recommended_equipment")` | Bucket:Recommended equipment | Recommended gear setups by activity/slot (schema not available on page - use runtime discovery) |
52
+ | `bucket("seachart")` | Bucket:Seachart | Sea chart/naval data |
53
+ | `bucket("sound_effect")` | Bucket:Sound effect | Sound effect metadata |
54
+ | `bucket("soundtrack")` | Bucket:Soundtrack | Soundtrack track data |
55
+ | `bucket("storeline")` | Bucket:Storeline | Store line entries |
56
+ | `bucket("testing_bucket")` | Bucket:Testing bucket | Wiki-internal testing data (not real content) |
57
+ | `bucket("transcript")` | Bucket:Transcript | NPC/dialogue transcripts |
58
+ | `bucket("update")` | Bucket:Update | Game update records: dates, summaries |
59
+ | `bucket("varbit")` | Bucket:Varbit | Varbit id to meaning mappings |
60
+
61
+ ## Quick Reference: Common Tasks → Bucket
62
+
63
+ | Task | Bucket |
64
+ |------|--------|
65
+ | GE prices | `bucket("exchange")` |
66
+ | Item stats (examine, weight, alch, buy limit) | `bucket("infobox_item")` |
67
+ | Monster stats (HP, max hit, combat level, weaknesses) | `bucket("infobox_monster")` |
68
+ | Drop sources for item | `bucket("dropsline")` |
69
+ | Quest requirements/rewards | `bucket("quest")` |
70
+ | Gear for activity | `bucket("recommended_equipment")` |
71
+ | Varbit values | `bucket("varbit")` |
72
+ | Shop info | `bucket("infobox_shop")` |
73
+ | Item/NPC/Object ID lookups | `bucket("item_id")`, `bucket("npc_id")`, `bucket("object_id")` |
74
+ | Combat achievements | `bucket("combat_achievement")` |
75
+ | Equipment bonuses | `bucket("infobox_bonuses")` |
76
+ | Money making methods | `bucket("money_making_guide")` |
77
+
78
+ ## Discovery
79
+
80
+ If a bucket isn't listed here:
81
+ 1. `search-page-by-prefix "Bucket:"` (namespace 9592)
82
+ 2. `get-page "Bucket:<Name>"` for schema + preview
@@ -0,0 +1,140 @@
1
+ # Bucket Query Guide
2
+
3
+ > How to use bucket-query effectively. Read `context://bucket-catalog` first to find the right bucket.
4
+
5
+ ## When to Use bucket-query
6
+
7
+ **Use bucket-query for structured/semantic data. Use search-page/get-page for unstructured content.**
8
+
9
+ | Use bucket-query for... | Use search-page/get-page for... |
10
+ |-------------------------|--------------------------------|
11
+ | Item stats (price, high alch, weight, examine, buy limit) | Lore, mechanics, walkthroughs |
12
+ | Monster stats (HP, max hit, combat level, weaknesses, slayer info) | "How do I..." guides |
13
+ | Grand Exchange prices | General explanations |
14
+ | Drop sources for a specific item | Narrative content |
15
+ | Quest requirements, rewards, difficulty | |
16
+ | Gear recommendations for an activity/boss | |
17
+ | Varbit values/meanings | |
18
+ | Shop info (location, owner, stock) | |
19
+ | Item/NPC/Object ID mappings | |
20
+
21
+ **Key distinction**: Buckets return *structured rows* (semantic data). Pages return *wikitext/HTML* (unstructured content).
22
+
23
+ ## Mandatory Best Practices
24
+
25
+ - **ALWAYS use `.select("field1","field2")`** — only fetch needed columns
26
+ - **ALWAYS use `.where("field","value")`** — filter rows, never fetch all
27
+ - **Use `.limit(N)`** — cap results (max 500)
28
+ - **Chain filters** with `Bucket.And/Or/Not` for complex conditions
29
+ - **NEVER run `.run()` without `.select()` and `.where()`**
30
+
31
+ ```lua
32
+ -- ✅ Good
33
+ bucket("exchange").select("name","value","high_alch").where("name","Abyssal whip").run()
34
+ bucket("infobox_shop").select("shop_name","location").where("location","Lumbridge").limit(100).run()
35
+
36
+ -- ❌ Bad (causes context bloat)
37
+ bucket("infobox_shop").run()
38
+ bucket("exchange").select("*").run()
39
+ ```
40
+
41
+ ## Exact Match Only — No Wildcards
42
+
43
+ bucket-query uses **exact match only**. To find exact values:
44
+
45
+ 1. `search-page` for the term → get exact name
46
+ 2. Use exact name in bucket query with `.where()`
47
+
48
+ ```bash
49
+ # Example: "Bob's Axe Shop"
50
+ search-page "bob axe" → "Bob's Brilliant Axes"
51
+ bucket("infobox_shop").where("shop_name","Bob's Brilliant Axes")
52
+ ```
53
+
54
+ ## Query Syntax
55
+
56
+ ```lua
57
+ -- Equality
58
+ .where("field","value")
59
+
60
+ -- Operators
61
+ .where({"field",">",value})
62
+ .where({"field","<",value})
63
+ .where({"field",">=",value})
64
+ .where({"field","<=",value})
65
+ .where({"field","!=",value})
66
+
67
+ -- Composition
68
+ Bucket.And({where1, where2})
69
+ Bucket.Or({where1, where2})
70
+ Bucket.Not(where1)
71
+
72
+ -- Pagination
73
+ .limit(200).continueFrom("cursor")
74
+ ```
75
+
76
+ Full Lua reference: https://meta.weirdgloop.org/w/Extension:Bucket/Usage
77
+
78
+ ## Common Patterns (Always use .select() and .where())
79
+
80
+ | Task | Query |
81
+ |------|-------|
82
+ | GE prices | `bucket("exchange").select("name","value","high_alch").where("name","Abyssal whip").run()` |
83
+ | Monster stats | `bucket("infobox_monster").select("name","combat_level","hitpoints","max_hit").where("name","Hydra").run()` |
84
+ | Item stats | `bucket("infobox_item").select("item_name","value","high_alch","weight","buy_limit").where("item_name","Abyssal whip").run()` |
85
+ | Drop sources for item | `bucket("dropsline").select("item_name","drop_json").where("item_name","Abyssal whip").run()` |
86
+ | Quest requirements | `bucket("quest").select("name","requirements","rewards").where("name","Dragon Slayer I").run()` |
87
+ | Varbits | `bucket("varbit").select("name","value").where("name","hydra_task").run()` |
88
+ | Shop lookup | `bucket("infobox_shop").select("shop_name","location","owner").where("shop_name","Bob's Brilliant Axes").run()` |
89
+ | Gear recommendations | `bucket("recommended_equipment").select("item","slot").where("activity","hydra").run()` |
90
+ | Equipment bonuses | `bucket("infobox_bonuses").select("name","slot","stab","slash","crush","magic","range").where("name","Bandos chestplate").run()` |
91
+ | Combat achievements | `bucket("combat_achievement").select("name","tier","description").where("name","Perfect Fire Cape").run()` |
92
+
93
+ ## Workflow: Find Exact Values First
94
+
95
+ 1. **search-page** for term → get exact name
96
+ 2. Use exact name in `bucket-query` with `.where()`
97
+
98
+ ```bash
99
+ # "best gear for hydra"
100
+ search-page "hydra gear" → exact activity name "Hydra"
101
+ bucket("recommended_equipment").select("item","slot").where("activity","Hydra").run()
102
+ ```
103
+
104
+ ## What Buckets CANNOT Do
105
+
106
+ | Limitation | Workaround |
107
+ |------------|------------|
108
+ | `dropsline` only queryable by `item_name`, not by source | Use `get-page` on source page (boss/chest/activity) |
109
+ | "What drops from boss X" | `get-page "Boss Name"` → `metadata=true` → `section=N` for drops |
110
+ | Raid/group drops (ToA, CoX, ToB) | Individual boss/chest pages via `get-page` |
111
+
112
+ ## Raid/Group Drop Patterns (use get-page, NOT buckets)
113
+
114
+ | Content | Query |
115
+ |---------|-------|
116
+ | Tombs of Amascut (ToA) | `get-page "Chest (Tombs of Amascut)"` then `get-page "Tumeken's Warden"`, `get-page "Akkha"`, etc. |
117
+ | Chambers of Xeric (CoX) | `get-page "Chambers of Xeric"` then individual boss pages (Olm, Great Olm, etc.) |
118
+ | Theatre of Blood (ToB) | `get-page "Theatre of Blood"` then individual boss pages (Maiden, Bloat, Nylocas, Sotetseg, Xarpus, Verzik) |
119
+ | General boss drops | `get-page "<Boss Name>"` (e.g., "Zulrah", "Vorkath", "Phantom Muspah") |
120
+
121
+ For large pages: `get-page "<Title>" metadata=true` → get section outline → `get-page "<Title>" section=N` for drops section.
122
+
123
+ ## Troubleshooting
124
+
125
+ | Issue | Fix |
126
+ |-------|-----|
127
+ | No results | Check schema: `get-page "Bucket:<Name>"` — wrong field name or wrong exact value |
128
+ | Too many results | Add more `.where()` filters, use `.limit()` |
129
+ | Schema not available | Use `search-page-by-prefix "Bucket:"` → find schema page |
130
+ | Field name unknown | Read bucket schema page for exact field names |
131
+
132
+ ## Pagination Example
133
+
134
+ ```lua
135
+ -- First page
136
+ bucket("infobox_shop").select("shop_name","location").limit(200).run()
137
+
138
+ -- Subsequent pages
139
+ bucket("infobox_shop").select("shop_name","location").limit(200).continueFrom("cursor_from_previous").run()
140
+ ```
@@ -0,0 +1,154 @@
1
+ # Namespace & Category Guide
2
+
3
+ > Category structure, namespace IDs, and DPL/template discovery workflow for `get-category-members`, `get-site-info`, `get-links-here`.
4
+
5
+ ## Namespaces
6
+
7
+ | Namespace ID | Prefix | Purpose |
8
+ |--------------|--------|---------|
9
+ | 0 | (none) | Main content pages (items, monsters, quests, bosses, mechanics) |
10
+ | 1 | Talk: | Discussion pages |
11
+ | 2 | User: | User pages |
12
+ | 6 | File: | Images/media |
13
+ | 10 | Template: | Templates |
14
+ | 14 | Category: | Category listings |
15
+ | 9592 | Bucket: | Bucket extension schemas (use `context://bucket-catalog` first) |
16
+ | 1198 | Update: | Game updates (DPL-driven lists) |
17
+ | 1199 | Update_talk: | Update discussion |
18
+ | 1200 | Calculator: | Calculators |
19
+ | 828 | Module: | Lua modules |
20
+
21
+ > **Tip**: Run `get-site-info` for the full namespace map — custom namespaces vary by wiki.
22
+
23
+ ## Category Structure (Key Categories)
24
+
25
+ ### Items
26
+ - `Category:Items` → subcategories: `Weapons`, `Armour`, `Food`, `Potions`, `Runes`, `Ammunition`, `Tools`, `Quest items`, etc.
27
+ - `Category:Tradeable items` / `Category:Untradeable items`
28
+ - `Category:Grand Exchange items`
29
+
30
+ ### Monsters/NPCs
31
+ - `Category:Monsters` → subcategories: `Bosses`, `Slayer monsters`, `Dungeon monsters`, `Wilderness monsters`
32
+ - `Category:Aggressive monsters`, `Category:Poisonous monsters`
33
+
34
+ ### Content
35
+ - `Category:Quests` → `Free-to-play quests`, `Members quests`, `Novice/Intermediate/Experienced/Master/Grandmaster quests`
36
+ - `Category:Achievement Diaries`, `Category:Combat Achievements`
37
+ - `Category:Minigames`, `Category:Raids`, `Category:Activities`
38
+ - `Category:Locations`, `Category:Dungeons`, `Category:Cities`
39
+
40
+ ### Data
41
+ - `Category:Exchange` (GE price pages)
42
+ - `Category:Drop tables`
43
+
44
+ ## When to Use get-category-members vs search-page
45
+
46
+ | Use `get-category-members` when... | Use `search-page` when... |
47
+ |------------------------------------|---------------------------|
48
+ | You want *all* pages in a category | You want pages *about* a topic |
49
+ | The category is the canonical list | You don't know the category |
50
+ | You need namespace filtering (e.g., Update: pages) | You need full-text matching |
51
+ | Example: "list all bosses" | Example: "hydra gear setup" |
52
+
53
+ ## Tool Routing
54
+
55
+ | Goal | Tool | Parameters |
56
+ |------|------|------------|
57
+ | **All bosses** | `get-category-members` | `category="Bosses"` |
58
+ | **All quests** | `get-category-members` | `category="Quests"` |
59
+ | **All items** | `get-category-members` | `category="Items"` |
60
+ | **All game updates** | `get-category-members` | `category="Updates" namespaces=[1198]` |
61
+ | **All calculators** | `get-category-members` | `category="Calculators" namespaces=[1200]` |
62
+ | **All GE-tracked items** | `get-category-members` | `category="Grand Exchange items"` |
63
+ | **Pages in custom namespace** | `get-site-info` → `get-category-members` | See DPL workflow below |
64
+ | **Backlinks to page** | `get-links-here` | `type="wikilinks"` / `transclusions` / `fileusage` |
65
+ | **Category members (as page list)** | `get-page "Category:Name"` | Returns wikitext list |
66
+
67
+ ## Dynamic Content Patterns
68
+
69
+ ### DPL (`<dpl>` tags) — Presentation, Not Data
70
+
71
+ When `get-page` returns wikitext containing `<dpl>` tags, **the data does not exist in that page**. DPL (DynamicPageList) is a presentation-layer extension that queries categories/namespaces at render time. The API **does not execute DPL**.
72
+
73
+ | Instead of... | Do this |
74
+ |---------------|---------|
75
+ | Reading the DPL page | `get-category-members` with the category + namespace DPL uses |
76
+ | Parsing `<dpl>` params | Check the DPL tag for `category=`, `namespace=`, `notcategory=` |
77
+
78
+ **Example**: `Game updates` page uses `<dpl category="Updates" namespace="1198" order=descending>`.
79
+ - Don't read `Game updates` for the list
80
+ - Do: `get-category-members "Updates" namespaces=[1198]`
81
+
82
+ ### Template Transclusion
83
+
84
+ Main pages often just include templates (e.g., `{{RecentUpdates}}`, `{{Updates}}`). The content lives in the **template page**, not the main page.
85
+
86
+ | Pattern | Action |
87
+ |---------|--------|
88
+ | `{{TemplateName}}` in page source | `get-page "Template:TemplateName"` |
89
+ | `{{#invoke:ModuleName|function}}` | `get-page "Module:ModuleName"` |
90
+
91
+ ### Namespaces as Content Types
92
+
93
+ Custom namespaces often map 1:1 to content types.
94
+
95
+ | OSRS Namespace | Content Type | Query Via |
96
+ |----------------|--------------|-----------|
97
+ | `Update:` (1198) | Game updates | `get-category-members "Updates" namespaces=[1198]` |
98
+ | `Calculator:` | Calculators | `get-category-members "Calculators" namespaces=[1200]` |
99
+ | `Module:` | Lua modules | `get-page "Module:Name"` |
100
+
101
+ ### Categories as Canonical Indexes
102
+
103
+ **The category often IS the list; the page is just a view.**
104
+
105
+ - `Category:Updates` + namespace 1198 = all game updates
106
+ - `Category:Bosses` = all boss pages
107
+ - `Category:Grand Exchange items` = all GE-tracked items
108
+
109
+ ## Discovery Workflow for DPL/Template Pages
110
+
111
+ ```
112
+ 1. get-page "Page Name" → see <dpl> or {{Template}} in source
113
+ 2. get-site-info → find relevant namespace ID(s)
114
+ 3. get-category-members → with that namespace + category
115
+ 4. get-pages → for individual item details
116
+ ```
117
+
118
+ This applies to any wiki using DPL/Category-based lists, not just OSRS updates.
119
+
120
+ ## Example: Get All 2026 Game Updates
121
+
122
+ ```bash
123
+ # 1. Check namespace for game updates
124
+ get-site-info
125
+
126
+ # 2. Get all updates (Update: namespace 1198, category "Updates")
127
+ get-category-members "Updates" namespaces=[1198]
128
+
129
+ # 3. Filter for 2026 client-side, or fetch individual pages
130
+ # Results include page titles like "Game update 2026-01-01"
131
+ ```
132
+
133
+ ## Example: Find All Calculators
134
+
135
+ ```bash
136
+ # Calculator namespace is 1200
137
+ get-category-members "Calculators" namespaces=[1200]
138
+ ```
139
+
140
+ ## get-links-here Usage
141
+
142
+ | Type | Use Case |
143
+ |------|----------|
144
+ | `wikilinks` (default) | Pages that link to target |
145
+ | `transclusions` | Pages that embed target (templates) |
146
+ | `fileusage` | Pages that display target (files) |
147
+
148
+ ```bash
149
+ # Pages linking to "Abyssal whip"
150
+ get-links-here "Abyssal whip" type="wikilinks"
151
+
152
+ # Pages using Template:Infobox item
153
+ get-links-here "Template:Infobox item" type="transclusions"
154
+ ```
@@ -0,0 +1,66 @@
1
+ # Page Structure Guide
2
+
3
+ > Page types, key sections, infobox→bucket mapping for `get-page`.
4
+
5
+ ## Page Structure by Type
6
+
7
+ | Page Type | Key Sections |
8
+ |-----------|--------------|
9
+ | **Items** | Infobox (stats), Obtaining, Usage, Changes |
10
+ | **Monsters** | Infobox (stats), Drops, Strategies, Locations |
11
+ | **Bosses** | Infobox, Mechanics, Strategies, Drops, Hard mode |
12
+ | **Quests** | Infobox, Requirements, Walkthrough, Rewards, Quick guide |
13
+ | **Locations** | Map, Features, NPCs, Monsters, Shops |
14
+ | **Raids** | Overview, Entry requirements, Rooms/Bosses, Rewards, Strategies |
15
+
16
+ ## Infobox Fields (Semantic Data → Use Buckets)
17
+
18
+ Most structured data lives in infoboxes and is available via buckets:
19
+
20
+ | Page Type | Bucket | Key Fields |
21
+ |-----------|--------|------------|
22
+ | Items | `bucket("infobox_item")` | item_name, item_id, examine, high_alchemy_value, value, weight, buy_limit, is_members_only, tradeable, image, release_date |
23
+ | Items (GE) | `bucket("exchange")` | name, value, high_alch, low_alch, buy_volume, sell_volume |
24
+ | Monsters | `bucket("infobox_monster")` | name, combat_level, hitpoints, max_hit, slayer_level, slayer_experience, slayer_category, assigned_by, attack/defence bonuses, attack_speed, poisonous, attribute, attack_style, respawn_time, elemental_weakness |
25
+ | Shops | `bucket("infobox_shop")` | shop_name, location, owner, specialty, shop_version, is_members_only |
26
+ | NPCs | `bucket("infobox_npc")` | id, combat_level, examine |
27
+ | Quests | `bucket("quest")` | name, requirements, rewards, difficulty, length, series |
28
+ | Spells | `bucket("infobox_spell")` | name, level, rune_cost, effect, description |
29
+
30
+ **Rule**: If you need infobox data → use the bucket, not the page.
31
+
32
+ ## Redirects
33
+
34
+ Many pages redirect (e.g., "Abby whip" → "Abyssal whip"). `get-page` follows redirects by default. If you need the redirect target without following, use `followRedirects=false`.
35
+
36
+ ## Disambiguation
37
+
38
+ Common disambiguation patterns:
39
+ - `Item Name (disambiguation)` — rare
40
+ - `Item Name (item)` vs `Item Name (monster)` — e.g., "Dragon (item)" vs "Dragon (monster)"
41
+ - Use `search-page` to find the correct variant
42
+
43
+ ## Large Page Strategy
44
+
45
+ For pages with many sections:
46
+
47
+ 1. `get-page "Title" metadata=true` — get section outline
48
+ 2. Identify needed section number
49
+ 3. `get-page "Title" section=N` — fetch only that section
50
+
51
+ Example:
52
+ ```bash
53
+ get-page "Chest (Tombs of Amascut)" metadata=true
54
+ # Returns sections: Lead, Rewards, Unique drops, Standard drops, Supply drops
55
+ get-page "Chest (Tombs of Amascut)" section=3 # Standard drops
56
+ ```
57
+
58
+ ## Quick Reference: Common Prefixes
59
+
60
+ | Looking for... | Try prefix search |
61
+ |----------------|-------------------|
62
+ | Weapon variants | `search-page-by-prefix "Dragon "` |
63
+ | Armour sets | `search-page-by-prefix "Bandos "` |
64
+ | Potions | `search-page-by-prefix "Prayer "` |
65
+ | Bosses | `search-page-by-prefix "Phantom "` |
66
+ | Quests | `search-page-by-prefix "Recipe for "` |
@@ -1,6 +1,31 @@
1
- # Search Strategies
1
+ # Search Guide
2
2
 
3
- > When and how to use each search tool effectively.
3
+ > Tool selection, broad-first search, canonical page heuristic, section discovery for `search-page`, `search-page-by-prefix`, `get-page`.
4
+
5
+ ## Tool Selection Decision Tree (START HERE)
6
+
7
+ ```
8
+ User asks a question
9
+ │
10
+ ├─ Structured data? (stats, prices, drops, requirements, gear, varbits)
11
+ │ → bucket-query (read context://bucket-query-guide)
12
+ │
13
+ ├─ Canonical list? (all bosses, all quests, all items, all updates)
14
+ │ → get-category-members (read context://namespace-category-guide)
15
+ │
16
+ ├─ Custom namespace list? (game updates in Update:, calculators)
17
+ │ → get-site-info + get-category-members (read context://namespace-category-guide)
18
+ │
19
+ ├─ Exact page title known?
20
+ │ → get-page directly
21
+ │
22
+ ├─ Know start of title? (e.g., "Abyssal ", "Dragon ")
23
+ │ → search-page-by-prefix "Prefix"
24
+ │
25
+ └─ General topic / keywords / unstructured content?
26
+ → search-page with BROAD query + high limit (50-100)
27
+ → Check results for canonical index page → get-page that page
28
+ ```
4
29
 
5
30
  ## Tool Comparison
6
31
 
@@ -10,18 +35,34 @@
10
35
  | `search-page-by-prefix` | Known prefix, autocomplete | Page titles only (no snippets) |
11
36
  | `get-page` (metadata) | Get section outline of known page | Section headings + numbers |
12
37
 
13
- ## Decision Tree
38
+ ## Broad-First Search Strategy
14
39
 
40
+ **Start with a broad query + high limit to find the canonical page, then narrow.**
41
+
42
+ | Approach | Query | Limit | Why |
43
+ |----------|-------|-------|-----|
44
+ | ❌ Too specific | `"2026 game updates"` | 10 | Misses "Game updates" page |
45
+ | ✅ Broad first | `"game updates"` | 50-100 | Finds canonical page immediately |
46
+ | ✅ Broad first | `"updates"` | 50 | Even broader, catches "Game updates" |
47
+
48
+ ### Why this works
49
+ - `search-page` max limit = **100** (default 10). One broad call with `limit=100` costs same as narrow call.
50
+ - Canonical index pages (e.g., "Game updates", "Quest list") rank high for broad terms.
51
+ - Snippets in broad results reveal structure → you pick the right page → one `get-page`.
52
+
53
+ ### Workflow
15
54
  ```
16
- Need to find a page?
17
- │
18
- ├─ Know exact title? → get-page "Exact Title"
19
- │
20
- ├─ Know start of title? → search-page-by-prefix "Prefix"
21
- │
22
- ├─ General topic / keywords? → search-page "keywords"
23
- │
24
- └─ Want to browse a category? → get-page "Category:Name"
55
+ 1. search-page "updates" limit=100
56
+ → #2: "Game updates" (snippet: "chronological list of all game updates")
57
+ 2. get-page "Game updates" ← canonical page, has everything
58
+ 3. (if needed) get-page "Game updates" section=3 ← specific year
59
+ ```
60
+
61
+ ### Anti-pattern
62
+ ```
63
+ search-page "2026 game updates" limit=10 → misses canonical page
64
+ search-page "Easter 2026 update" → too narrow, fragments context
65
+ search-page "Cow Boss update" → too narrow
25
66
  ```
26
67
 
27
68
  ## search-page Best Practices
@@ -130,9 +171,19 @@ search-page "Game update 2026"
130
171
  - Use `metadata=true` + `section=N` to minimize page read calls
131
172
  - Cache results mentally within a conversation - don't re-search
132
173
 
174
+ ## DPL / Template Pages
175
+
176
+ If `get-page` returns `<dpl>` tags or `{{Template}}` transclusions — **the data isn't there**. See `context://namespace-category-guide` → "Dynamic Content Patterns" for the workflow:
177
+
178
+ 1. `get-site-info` → find namespace ID
179
+ 2. `get-category-members` with category + namespace
180
+ 3. `get-pages` for details
181
+
182
+ Common on OSRS: Game updates (`Update:` namespace 1198), calculators, module outputs.
183
+
133
184
  ## Fallback Chain
134
185
 
135
- 1. **bucket-query** (if structured data exists) → check `context://bucket-index`
186
+ 1. **bucket-query** (if structured data exists) → check `context://bucket-catalog`
136
187
  2. **search-page-by-prefix** (if you know title prefix)
137
188
  3. **search-page** (general topic)
138
189
  4. **get-page + metadata** (large page, need specific section)
@@ -0,0 +1,99 @@
1
+ # Tool Selection Guide (READ FIRST)
2
+
3
+ > Decide which tool to use, then read the corresponding guide.
4
+
5
+ ## Decision Tree
6
+
7
+ ```
8
+ User asks a question
9
+ │
10
+ ├─ Structured data? (stats, prices, drops, requirements, gear, varbits, IDs)
11
+ │ → bucket-query
12
+ │ → Read: context://bucket-query-guide
13
+ │
14
+ ├─ Canonical list? (all bosses, all quests, all items, all updates)
15
+ │ → get-category-members
16
+ │ → Read: context://namespace-category-guide
17
+ │
18
+ ├─ Custom namespace list? (game updates, calculators)
19
+ │ → get-site-info + get-category-members
20
+ │ → Read: context://namespace-category-guide
21
+ │
22
+ ├─ Exact title known?
23
+ │ → get-page
24
+ │
25
+ ├─ Know title prefix? (e.g., "Abyssal ", "Dragon ")
26
+ │ → search-page-by-prefix
27
+ │ → Read: context://search-guide
28
+ │
29
+ └─ General topic / unstructured content? (lore, mechanics, guides)
30
+ → search-page (broad query + high limit)
31
+ → Check for canonical page → get-page
32
+ → Read: context://search-guide
33
+ ```
34
+
35
+ ## Quick Tool → Resource Map
36
+
37
+ | Tool | Primary Resource | Secondary |
38
+ |------|------------------|-----------|
39
+ | `bucket-query` | `context://bucket-query-guide` | `context://bucket-catalog` |
40
+ | `get-category-members` | `context://namespace-category-guide` | — |
41
+ | `get-site-info` | `context://namespace-category-guide` | — |
42
+ | `get-page` | `context://search-guide` (section discovery) | `context://page-structure` |
43
+ | `search-page` | `context://search-guide` | — |
44
+ | `search-page-by-prefix` | `context://search-guide` | — |
45
+ | `get-links-here` | `context://namespace-category-guide` | — |
46
+
47
+ ## Most Common Patterns (Copy-Paste)
48
+
49
+ ### Bucket Query (structured data)
50
+ ```lua
51
+ -- Item price/stats
52
+ bucket("exchange").select("name","value","high_alch").where("name","Abyssal whip").run()
53
+ bucket("infobox_item").select("item_name","value","high_alch","weight").where("item_name","Abyssal whip").run()
54
+
55
+ -- Monster stats
56
+ bucket("infobox_monster").select("name","combat_level","hitpoints","max_hit").where("name","Hydra").run()
57
+
58
+ -- Drop sources for item
59
+ bucket("dropsline").select("item_name","drop_json").where("item_name","Abyssal whip").run()
60
+
61
+ -- Quest requirements
62
+ bucket("quest").select("name","requirements").where("name","Dragon Slayer I").run()
63
+
64
+ -- Gear for activity
65
+ bucket("recommended_equipment").select("item","slot").where("activity","hydra").run()
66
+
67
+ -- Varbit
68
+ bucket("varbit").select("name","value").where("name","hydra_task").run()
69
+
70
+ -- Shop
71
+ bucket("infobox_shop").select("shop_name","location","owner").where("shop_name","Bob's Brilliant Axes").run()
72
+ ```
73
+
74
+ ### Category Members (canonical lists)
75
+ ```bash
76
+ # All bosses
77
+ get-category-members "Bosses"
78
+
79
+ # All quests
80
+ get-category-members "Quests"
81
+
82
+ # All game updates (Update: namespace 1198)
83
+ get-category-members "Updates" namespaces=[1198]
84
+
85
+ # All GE items
86
+ get-category-members "Grand Exchange items"
87
+ ```
88
+
89
+ ### Search (unstructured content)
90
+ ```bash
91
+ # Broad first → canonical page → section
92
+ search-page "updates" limit=100
93
+ get-page "Game updates"
94
+ get-page "Game updates" section=3
95
+
96
+ # Section discovery
97
+ get-page "Chest (Tombs of Amascut)" metadata=true
98
+ get-page "Chest (Tombs of Amascut)" section=3
99
+ ```
@@ -1,147 +0,0 @@
1
- # Bucket Index (hint list)
2
-
3
- > On-demand hints for `bucket-query` on the Old School RuneScape Wiki.
4
- > **This index is not authoritative.** Purpose descriptions are best-effort
5
- > summaries; fields always come from the schema page. If nothing here fits
6
- > your need, or a name fails at runtime, fall back to discovery:
7
- > `search-page-by-prefix` in the `Bucket:` namespace (id 9592), then
8
- > `get-page` on `Bucket:<Name>` to see exact fields and a data preview.
9
- >
10
- > Naming rule: pass the page title lowercased with spaces as underscores
11
- > (`Bucket:Clue equipment` -> `bucket("clue_equipment")`). All bucket and
12
- > field names are lowercase; fields are verified on the schema page, never
13
- > guessed from this file.
14
-
15
- ## Known buckets
16
-
17
- | Query as | Page | Holds |
18
- | --- | --- | --- |
19
- | `bucket("bountytaskline")` | Bucket:Bountytaskline | Bounty Hunter task line entries |
20
- | `bucket("clue_equipment")` | Bucket:Clue equipment | Equipment associated with clue scroll steps |
21
- | `bucket("clue_info")` | Bucket:Clue info | Clue scroll metadata/step info |
22
- | `bucket("collection_log_source")` | Bucket:Collection log source | Collection log sources per item: item_id, item_name, sources (repeated wikilinks), rates, kinds. **Only queryable by item_name** - cannot filter by source. To find "what drops from X", use the source page directly. |
23
- | `bucket("combat_achievement")` | Bucket:Combat achievement | Combat achievement tasks, tiers, requirements |
24
- | `bucket("couriertaskline")` | Bucket:Couriertaskline | Courier activity task line entries |
25
- | `bucket("demonicpactleaguetask")` | Bucket:Demonicpactleaguetask | Demonic Pact league task entries |
26
- | `bucket("dependency_list")` | Bucket:Dependency list | Item/object dependency relations |
27
- | `bucket("drop_table_sources")` | Bucket:Drop table sources | Shared drop tables (rare drop table, gem drop table, herb drop table) and their roll/rarity data. Not specific monster/boss drop tables. |
28
- | `bucket("dropsline")` | Bucket:Dropsline | Drop table line entries: item_name, drop_json (JSON text with "Dropped from", rarity, quantity), rare_drop_table. **Only queryable by item_name** - cannot filter by source. To find "what drops from X", use the source page (boss/chest/activity) directly. |
29
- | `bucket("exchange")` | Bucket:Exchange | Grand Exchange prices (name, value, high/low, volumes) |
30
- | `bucket("feedback")` | Bucket:Feedback | Wiki feedback entries (site-internal) |
31
- | `bucket("ge_index_header")` | Bucket:Ge index header | Grand Exchange index header/snapshot metadata |
32
- | `bucket("infobox_activity")` | Bucket:Infobox activity | Skilling/activity infobox data |
33
- | `bucket("infobox_bonuses")` | Bucket:Infobox bonuses | Equipment combat stats and bonuses |
34
- | `bucket("infobox_construction")` | Bucket:Infobox construction | Construction object/buildable data |
35
- | `bucket("infobox_grid_master_unlock")` | Bucket:Infobox grid master unlock | Grid Master unlock data |
36
- | `bucket("infobox_item")` | Bucket:Infobox item | Core item data: item_name, item_id, examine, high_alchemy_value, value, weight, buy_limit, is_members_only, tradeable, image, league_region, release_date, removal_date, value, weight, high_alchemy_value, buy_limit, default_version, quest, version_anchor, is_members_only, tradeable |
37
- | `bucket("infobox_location")` | Bucket:Infobox location | Location/area data |
38
- | `bucket("infobox_monster")` | Bucket:Infobox monster | Monster combat stats: name, combat_level, hitpoints, max_hit, slayer_level, slayer_experience, slayer_category, assigned_by, attack/defence bonuses (stab/slash/crush/magic/range), attack_speed, hitpoints, max_hit, poisonous, attribute, attack_style, attack_speed, respawn_time, experience_bonus, flat_armour, magic_resistance, size, attack/strength/defence/ranged/magic levels, attack_bonus, strength_bonus, range_strength_bonus, magic_damage_bonus, poison/venom/freeze/burn/cannon/thrall resistance, elemental_weakness, elemental_weakness_percent |
39
- | `bucket("infobox_npc")` | Bucket:Infobox npc | NPC data: id, combat level, examine |
40
- | `bucket("infobox_pure")` | Bucket:Infobox pure | Pure-entity infobox data (verify schema) |
41
- | `bucket("infobox_scenery")` | Bucket:Infobox scenery | Scenery/object entity data |
42
- | `bucket("infobox_ship_part")` | Bucket:Infobox ship part | Ship part data |
43
- | `bucket("infobox_shop")` | Bucket:Infobox shop | Shop data: shop_name, location, owner, specialty, shop_version, is_members_only |
44
- | `bucket("infobox_spell")` | Bucket:Infobox spell | Spell data: requirements, effects, costs |
45
- | `bucket("interface")` | Bucket:Interface | Game interface definitions |
46
- | `bucket("item_id")` | Bucket:Item id | Item name to id mappings |
47
- | `bucket("locline")` | Bucket:Locline | Location line entries |
48
- | `bucket("logs")` | Bucket:Logs | Woodcutting log/tree data |
49
- | `bucket("map")` | Bucket:Map | Map marker/region data |
50
- | `bucket("mine")` | Bucket:Mine | Mining node/rock data |
51
- | `bucket("mmg_output")` | Bucket:Mmg output | Money making guide output calculations |
52
- | `bucket("money_making_guide")` | Bucket:Money making guide | Money making methods: profit, requirements |
53
- | `bucket("music")` | Bucket:Music | Music track unlock data |
54
- | `bucket("music_file")` | Bucket:Music file | Music file metadata |
55
- | `bucket("music_map")` | Bucket:Music map | Music tracks by region/map area |
56
- | `bucket("music_versions")` | Bucket:Music versions | Music version/history entries |
57
- | `bucket("npc_id")` | Bucket:Npc id | NPC name to id mappings |
58
- | `bucket("object_id")` | Bucket:Object id | Object/scenery id mappings |
59
- | `bucket("quest")` | Bucket:Quest | Quest data: requirements, rewards, difficulty |
60
- | `bucket("recipe")` | Bucket:Recipe | Creation/processing recipes: inputs, outputs, skills |
61
- | `bucket("recommended_equipment")` | Bucket:Recommended equipment | Recommended gear setups by activity/slot (schema not available on page - use runtime discovery) |
62
- | `bucket("seachart")` | Bucket:Seachart | Sea chart/naval data |
63
- | `bucket("sound_effect")` | Bucket:Sound effect | Sound effect metadata |
64
- | `bucket("soundtrack")` | Bucket:Soundtrack | Soundtrack track data |
65
- | `bucket("storeline")` | Bucket:Storeline | Store line entries |
66
- | `bucket("testing_bucket")` | Bucket:Testing bucket | Wiki-internal testing data (not real content) |
67
- | `bucket("transcript")` | Bucket:Transcript | NPC/dialogue transcripts |
68
- | `bucket("update")` | Bucket:Update | Game update records: dates, summaries |
69
- | `bucket("varbit")` | Bucket:Varbit | Varbit id to meaning mappings |
70
-
71
- ## Query reminders
72
-
73
- - Query must end in `.run()`; `limit` max 500, paginate with `continueFrom`.
74
- - Equality: `where("field","value")`; operators: `where({"field",">",value})`
75
- with `=`, `!=`, `>`, `<`, `>=`, `<=`; compose with `Bucket.And/Or/Not`.
76
- - Example: `bucket("infobox_item").select("item_id","examine").where("item_name","Raw lobster").run()`
77
- - Full Lua reference: https://meta.weirdgloop.org/w/Extension:Bucket/Usage
78
-
79
- ## Best Practices (MANDATORY)
80
-
81
- - **ALWAYS use `.select("field1","field2")`** - only fetch needed columns
82
- - **ALWAYS use `.where("field","value")`** - filter rows, never fetch all
83
- - **Use `.limit(N)`** - cap results (max 500)
84
- - **Chain filters** with `Bucket.And/Or/Not` for complex conditions
85
- - **NEVER** run `.run()` without `.select()` and `.where()`
86
-
87
- ### Exact Match Only - No Wildcards
88
-
89
- bucket-query uses **exact match only**. To find exact values:
90
- 1. `search-page` for the term → get exact name
91
- 2. Use exact name in bucket query
92
-
93
- Example: "Bob's Axe Shop" → `search-page "bob axe"` → "Bob's Brilliant Axes" → `bucket("infobox_shop").where("shop_name","Bob's Brilliant Axes")`
94
-
95
- ### Example Patterns
96
-
97
- ✅ Good:
98
- ```
99
- bucket("exchange").select("name","value","high_alch").where("name","Abyssal whip").run()
100
- bucket("infobox_shop").select("shop_name","location").where("location","Lumbridge").limit(5).run()
101
- ```
102
-
103
- ❌ Bad (causes context bloat):
104
- ```
105
- bucket("infobox_shop").run()
106
- bucket("exchange").select("*").run()
107
- ```
108
-
109
- ### Pagination
110
- ```lua
111
- bucket("infobox_shop").select("shop_name","location").limit(50).continueFrom("cursor").run()
112
- ```
113
-
114
- ### Common Bucket Patterns (Always use .select() and .where())
115
-
116
- | Task | Bucket Query |
117
- |------|--------------|
118
- | GE prices | `bucket("exchange").select("name","value","high_alch").where("name","Abyssal whip").run()` |
119
- | Monster stats | `bucket("infobox_monster").select("name","combat_level","hitpoints").where("name","Hydra").run()` |
120
- | Item stats | `bucket("infobox_item").select("item_name","value","high_alch").where("item_name","Abyssal whip").run()` |
121
- | Drop sources | `bucket("dropsline").select("source","quantity").where("item","Abyssal whip").run()` |
122
- | Quest requirements | `bucket("quest").select("name","requirements").where("name","Dragon Slayer I").run()` |
123
- | Varbits | `bucket("varbit").select("name","value").where("name","hydra_task").run()` |
124
- | Shop lookup | `bucket("infobox_shop").select("shop_name","location","owner").where("shop_name","Bob's Brilliant Axes").run()` |
125
- | Gear recommendations | `bucket("recommended_equipment").select("item","slot").where("activity","hydra").run()` |
126
-
127
- ### Workflow: Find Exact Values First
128
-
129
- 1. **search-page** for term → get exact name
130
- 2. Use exact name in `bucket-query` with `.where()`
131
-
132
- Example: "best gear for hydra" → `bucket("recommended_equipment").select("item","slot").where("activity","hydra").run()`
133
-
134
- ### Raid/Group Drop Patterns (use get-page, NOT buckets)
135
-
136
- No bucket supports "what drops from source" queries. For raid/group content, use `get-page` on individual source pages:
137
-
138
- | Content | Query |
139
- |---------|-------|
140
- | Tombs of Amascut (ToA) | `get-page "Chest (Tombs of Amascut)"` then `get-page "Tumeken's Warden"`, `get-page "Akkha"`, etc. |
141
- | Chambers of Xeric (CoX) | `get-page "Chambers of Xeric"` then individual boss pages (Olm, Great Olm, etc.) |
142
- | Theatre of Blood (ToB) | `get-page "Theatre of Blood"` then individual boss pages (Maiden, Bloat, Nylocas, Sotetseg, Xarpus, Verzik) |
143
- | General boss drops | `get-page "<Boss Name>"` (e.g., "Zulrah", "Vorkath", "Phantom Muspah") |
144
-
145
- For large pages: `get-page "<Title>" metadata=true` → get section outline → `get-page "<Title>" section=N` for drops section.
146
-
147
- Use page reads (`get-page`, `search-page`) ONLY for unstructured content: lore, mechanics, walkthroughs.
@@ -1,112 +0,0 @@
1
- # Wiki Navigation Guide
2
-
3
- > How to find pages on the Old School RuneScape Wiki using the available tools.
4
-
5
- ## Namespaces
6
-
7
- | Namespace ID | Prefix | Purpose |
8
- |--------------|--------|---------|
9
- | 0 | (none) | Main content pages (items, monsters, quests, bosses, mechanics) |
10
- | 1 | Talk: | Discussion pages |
11
- | 2 | User: | User pages |
12
- | 6 | File: | Images/media |
13
- | 10 | Template: | Templates |
14
- | 14 | Category: | Category listings |
15
- | 9592 | Bucket: | Bucket extension schemas (use `context://bucket-index` first) |
16
-
17
- ## Category Structure (Key Categories)
18
-
19
- **Items:**
20
- - `Category:Items` → subcategories: `Weapons`, `Armour`, `Food`, `Potions`, `Runes`, `Ammunition`, `Tools`, `Quest items`, etc.
21
- - `Category:Tradeable items` / `Category:Untradeable items`
22
- - `Category:Grand Exchange items`
23
-
24
- **Monsters/NPCs:**
25
- - `Category:Monsters` → subcategories by type: `Bosses`, `Slayer monsters`, `Dungeon monsters`, `Wilderness monsters`
26
- - `Category:Aggressive monsters`, `Category:Poisonous monsters`
27
-
28
- **Content:**
29
- - `Category:Quests` → `Free-to-play quests`, `Members quests`, `Novice/Intermediate/Experienced/Master/Grandmaster quests`
30
- - `Category:Achievement Diaries`, `Category:Combat Achievements`
31
- - `Category:Minigames`, `Category:Raids`, `Category:Activities`
32
- - `Category:Locations`, `Category:Dungeons`, `Category:Cities`
33
-
34
- **Data:**
35
- - `Category:Exchange` (GE price pages)
36
- - `Category:Drop tables`
37
-
38
- ## Finding Pages - Strategy
39
-
40
- ### 0. Search hit a canonical index page? Fetch it.
41
- ```bash
42
- search-page "2026 game updates"
43
- # Result: "Game updates" - snippet shows chronological list
44
- get-page "Game updates" # ← Do this first
45
- ```
46
-
47
- ### 1. Known exact title? Use `get-page` directly
48
- ```bash
49
- get-page "Abyssal whip"
50
- get-page "Tumeken's Warden"
51
- ```
52
-
53
- ### 2. Know approximate title? Use `search-page-by-prefix`
54
- ```bash
55
- search-page-by-prefix "Abyssal" # "Abyssal whip", "Abyssal dagger", etc.
56
- search-page-by-prefix "Tumeken" # "Tumeken's Warden"
57
- search-page-by-prefix "Chest (Tombs" # "Chest (Tombs of Amascut)"
58
- ```
59
-
60
- ### 3. General topic? Use `search-page` (full-text)
61
- ```bash
62
- search-page "hydra gear recommendations"
63
- search-page "prayer flicking guide"
64
- search-page "slayer task weights"
65
- ```
66
-
67
- ### 4. Browse via categories (when you don't know titles)
68
- ```bash
69
- get-page "Category:Bosses" # Lists all boss pages
70
- get-page "Category:Slayer monsters" # Lists all slayer monsters
71
- get-page "Category:Grand Exchange items" # Lists all GE-tracked items
72
- ```
73
-
74
- ## Redirects
75
-
76
- Many pages redirect (e.g., "Abby whip" → "Abyssal whip"). `get-page` follows redirects by default. If you need the redirect target without following, use `followRedirects=false`.
77
-
78
- ## Disambiguation
79
-
80
- Common disambiguation patterns:
81
- - `Item Name (disambiguation)` - rare
82
- - `Item Name (item)` vs `Item Name (monster)` - e.g., "Dragon (item)" vs "Dragon (monster)"
83
- - Use `search-page` to find the correct variant
84
-
85
- ## Page Structure by Type
86
-
87
- | Page Type | Key Sections |
88
- |-----------|--------------|
89
- | **Items** | Infobox (stats), Obtaining, Usage, Changes |
90
- | **Monsters** | Infobox (stats), Drops, Strategies, Locations |
91
- | **Bosses** | Infobox, Mechanics, Strategies, Drops, Hard mode |
92
- | **Quests** | Infobox, Requirements, Walkthrough, Rewards, Quick guide |
93
- | **Locations** | Map, Features, NPCs, Monsters, Shops |
94
- | **Raids** | Overview, Entry requirements, Rooms/Bosses, Rewards, Strategies |
95
-
96
- ## Infobox Fields (Semantic Data → Use Buckets)
97
-
98
- Most structured data lives in infoboxes and is available via buckets:
99
- - Items → `bucket("infobox_item")` or `bucket("exchange")`
100
- - Monsters → `bucket("infobox_monster")`
101
- - Shops → `bucket("infobox_shop")`
102
- - NPCs → `bucket("infobox_npc")`
103
-
104
- ## Quick Reference: Common Prefixes
105
-
106
- | Looking for... | Try prefix search |
107
- |----------------|-------------------|
108
- | Weapon variants | `search-page-by-prefix "Dragon "` |
109
- | Armour sets | `search-page-by-prefix "Bandos "` |
110
- | Potions | `search-page-by-prefix "Prayer "` |
111
- | Bosses | `search-page-by-prefix "Phantom "` |
112
- | Quests | `search-page-by-prefix "Recipe for "` |