@cyanheads/eurostat-mcp-server 0.11.1 → 0.11.2

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 (56) hide show
  1. package/AGENTS.md +1 -1
  2. package/CLAUDE.md +1 -1
  3. package/README.md +8 -7
  4. package/changelog/0.11.x/0.11.2.md +27 -0
  5. package/dist/mcp-server/resources/definitions/eurostat-dataset.resource.d.ts +14 -1
  6. package/dist/mcp-server/resources/definitions/eurostat-dataset.resource.d.ts.map +1 -1
  7. package/dist/mcp-server/resources/definitions/eurostat-dataset.resource.js +17 -0
  8. package/dist/mcp-server/resources/definitions/eurostat-dataset.resource.js.map +1 -1
  9. package/dist/mcp-server/tools/definitions/eurostat-browse-themes.tool.d.ts +1 -1
  10. package/dist/mcp-server/tools/definitions/eurostat-browse-themes.tool.js +1 -1
  11. package/dist/mcp-server/tools/definitions/eurostat-browse-themes.tool.js.map +1 -1
  12. package/dist/mcp-server/tools/definitions/eurostat-download-dataset.tool.d.ts +8 -6
  13. package/dist/mcp-server/tools/definitions/eurostat-download-dataset.tool.d.ts.map +1 -1
  14. package/dist/mcp-server/tools/definitions/eurostat-download-dataset.tool.js +66 -30
  15. package/dist/mcp-server/tools/definitions/eurostat-download-dataset.tool.js.map +1 -1
  16. package/dist/mcp-server/tools/definitions/eurostat-get-dataset-info.tool.d.ts +1 -1
  17. package/dist/mcp-server/tools/definitions/eurostat-get-dataset-info.tool.d.ts.map +1 -1
  18. package/dist/mcp-server/tools/definitions/eurostat-get-dataset-info.tool.js +10 -1
  19. package/dist/mcp-server/tools/definitions/eurostat-get-dataset-info.tool.js.map +1 -1
  20. package/dist/mcp-server/tools/definitions/eurostat-get-dimension-values.tool.d.ts +2 -2
  21. package/dist/mcp-server/tools/definitions/eurostat-get-dimension-values.tool.d.ts.map +1 -1
  22. package/dist/mcp-server/tools/definitions/eurostat-get-dimension-values.tool.js +10 -1
  23. package/dist/mcp-server/tools/definitions/eurostat-get-dimension-values.tool.js.map +1 -1
  24. package/dist/mcp-server/tools/definitions/eurostat-query-dataset.tool.d.ts +2 -0
  25. package/dist/mcp-server/tools/definitions/eurostat-query-dataset.tool.d.ts.map +1 -1
  26. package/dist/mcp-server/tools/definitions/eurostat-query-dataset.tool.js +11 -4
  27. package/dist/mcp-server/tools/definitions/eurostat-query-dataset.tool.js.map +1 -1
  28. package/dist/mcp-server/tools/definitions/eurostat-search-datasets.tool.d.ts +4 -4
  29. package/dist/mcp-server/tools/definitions/eurostat-search-datasets.tool.d.ts.map +1 -1
  30. package/dist/mcp-server/tools/definitions/eurostat-search-datasets.tool.js +18 -6
  31. package/dist/mcp-server/tools/definitions/eurostat-search-datasets.tool.js.map +1 -1
  32. package/dist/services/eurostat-bulk/eurostat-bulk-service.d.ts +5 -4
  33. package/dist/services/eurostat-bulk/eurostat-bulk-service.d.ts.map +1 -1
  34. package/dist/services/eurostat-bulk/eurostat-bulk-service.js +66 -14
  35. package/dist/services/eurostat-bulk/eurostat-bulk-service.js.map +1 -1
  36. package/dist/services/eurostat-bulk/types.d.ts +21 -4
  37. package/dist/services/eurostat-bulk/types.d.ts.map +1 -1
  38. package/dist/services/eurostat-catalogue/eurostat-catalogue-service.d.ts +14 -8
  39. package/dist/services/eurostat-catalogue/eurostat-catalogue-service.d.ts.map +1 -1
  40. package/dist/services/eurostat-catalogue/eurostat-catalogue-service.js +34 -17
  41. package/dist/services/eurostat-catalogue/eurostat-catalogue-service.js.map +1 -1
  42. package/dist/services/eurostat-codelists.d.ts +2 -1
  43. package/dist/services/eurostat-codelists.d.ts.map +1 -1
  44. package/dist/services/eurostat-codelists.js +2 -1
  45. package/dist/services/eurostat-codelists.js.map +1 -1
  46. package/dist/services/eurostat-data/eurostat-data-service.d.ts +7 -0
  47. package/dist/services/eurostat-data/eurostat-data-service.d.ts.map +1 -1
  48. package/dist/services/eurostat-data/eurostat-data-service.js +84 -10
  49. package/dist/services/eurostat-data/eurostat-data-service.js.map +1 -1
  50. package/dist/services/eurostat-data/types.d.ts +17 -3
  51. package/dist/services/eurostat-data/types.d.ts.map +1 -1
  52. package/dist/services/eurostat-data/types.js.map +1 -1
  53. package/package.json +4 -4
  54. package/server.json +3 -3
  55. package/skills/eurostat-guide/SKILL.md +2 -1
  56. package/skills/eurostat-guide/references/sql-analysis.md +18 -2
@@ -4,7 +4,7 @@ description: Use with eurostat_* tools to compare countries or regions, analyse
4
4
  license: Apache-2.0
5
5
  metadata:
6
6
  author: "cyanheads"
7
- version: "1.1"
7
+ version: "1.1.1"
8
8
  ---
9
9
 
10
10
  ## Scope
@@ -30,6 +30,7 @@ Keep codes as identifiers and labels as display text. Resolve codes within the c
30
30
  - Before interpreting a GDP comparison, distinguish economic size, per-inhabitant values and price-adjusted comparisons. For comparisons across countries, PPS removes price-level differences; changes in current-price PPS values are not automatically real growth. Consult [Eurostat's PPP guidance](https://ec.europa.eu/eurostat/en/web/purchasing-power-parities/information-data) when choosing the measure.
31
31
  - Before a regional time-series comparison, establish the NUTS classification used by the data. A matching code or label alone does not establish unchanged boundaries. Eurostat revises NUTS and historical reconstruction depends on feasibility; consult [NUTS history and changes](https://ec.europa.eu/eurostat/en/web/nuts/history) and the dataset metadata when classifications differ. This server does not supply a concordance operation.
32
32
  - Before claiming a series is absent, distinguish an unknown metadata bound, an unlisted page, an unmatched code, an empty combination of otherwise valid codes and a period range that excludes the period. Eurostat keeps only periods wholly inside since_period–until_period, per frequency, so a bound inside a period drops it; a notice or error names the bound to use. Inspect notices and discovery freshness; missing Comext discovery is not evidence that a known DS-* dataset is unavailable.
33
+ - Before comparing coverage across series, separate a period a series lacks from an observation published without a value. A query reports the former as absentCellCount (periods of a frequency a matched series carries, with no cell) and stages no row for it; obsCount and missingObsCount count only published cells. A download stages the former as a row with null obs_value and no flag, status or text (an unflagged ":"), counted in rowCount and missingCount, in absentCellCount when the series carries that frequency elsewhere, and also at periods of a frequency the series has no observation of (the padding of a mixed-frequency slice), which absentCellCount leaves out. Such a row is not an observation, and its period is not coverage; periodRange and timeRange leave it out. A flagged ":" or a text value is an observation.
33
34
  - Before calling observations the latest available for each geography, inspect the selected slice's actual periods. The dataset's latest period can have no populated value for that slice. Expand the search period when necessary; do not report an empty latest-period selection as a zero.
34
35
  - Before calculating totals or rankings, establish that the retained observations cover the intended population. Inline observations are a preview, not a random sample, and a "Same in all N rows shown" line describes those rows, not the match; a query's truncated=false does not prove the preview includes every matched row. Compare obsCount with the observations received or inspect the staged table. A bulk result with budgetExceeded is an ordered prefix, even when that prefix has been staged successfully. Narrow and refetch before presenting a complete total.
35
36
  - Preserve missing numeric values, published text values, observation flags and confidentiality status. A null numeric value is not zero; a PRODCOM text value is not a numeric quantity. Carry relevant provisional, break-in-series or reliability flags into the interpretation.
@@ -28,13 +28,29 @@ The ordering is total only when the selected slice has one row per geo/time pair
28
28
  Inspect missingness alongside an aggregate:
29
29
 
30
30
  ```sql
31
- SELECT geo, COUNT(*) AS cells, COUNT(obs_value) AS numeric_cells,
31
+ SELECT geo, COUNT(*) AS rows_staged, COUNT(obs_value) AS numeric_cells,
32
32
  AVG(obs_value) AS mean_value
33
33
  FROM observations_table
34
34
  GROUP BY geo
35
35
  ORDER BY geo
36
36
  ```
37
37
 
38
- AVG ignores null numeric values. Use it only when that average answers the statistical question; do not replace missing observations with zero. For DS-* tables, inspect obs_value_text before interpreting every null numeric cell as missing data. Inspect obs_flag and conf_status alongside the values before drawing conclusions.
38
+ AVG ignores null numeric values. Use it only when that average answers the statistical question; do not replace missing observations with zero.
39
+
40
+ A table staged by eurostat_query_dataset has a row only for each published cell, so a period a series lacks is not a row; the query's absentCellCount counts those. A table staged by eurostat_download_dataset also holds those periods as rows with null obs_value, obs_flag, conf_status and (on DS-* tables) obs_value_text. To count the null cells that are observations, exclude them:
41
+
42
+ ```sql
43
+ SELECT geo,
44
+ COUNT(*) AS rows_staged,
45
+ COUNT(*) FILTER (WHERE obs_value IS NOT NULL OR obs_flag IS NOT NULL
46
+ OR conf_status IS NOT NULL) AS observations,
47
+ COUNT(*) FILTER (WHERE obs_value IS NULL AND obs_flag IS NULL
48
+ AND conf_status IS NULL) AS unflagged_null_rows
49
+ FROM observations_table
50
+ GROUP BY geo
51
+ ORDER BY geo
52
+ ```
53
+
54
+ On a DS-* table add OR obs_value_text IS NOT NULL to the observation test and AND obs_value_text IS NULL to the unflagged test; otherwise a text value such as KG counts as an unflagged row. In a mixed-frequency slice, compare each row's frequency dimension (freq on Comext) with the shape of its time code: an unflagged null row at a monthly period of an annual series is padding, not a gap. For DS-* tables, inspect obs_value_text before interpreting every null numeric cell as missing data. Inspect obs_flag and conf_status alongside the values before drawing conclusions.
39
55
 
40
56
  When a SQL result is truncated, retrieve deterministic pages of an unchanged query with a total ORDER BY and LIMIT/OFFSET. Advance OFFSET by the returned rowCount. Restart at offset zero if the first query was unordered. Expired or changing tables and volatile expressions cannot provide stable paging. Integer counts may arrive as strings to preserve precision; do not coerce them to an unsafe JavaScript number.