Agent Native

cn-stats

This skill enables the agent to query China's National Bureau of Statistics public data API to retrieve economic indicators, CPI, GDP, population, and…

by aahlCommunityNot reviewed

Community author

Agents
Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode, claude.ai and API
License
MIT (permissive)
Pin
47edd62pinned Oct 9, 2026
Context cost
about 720 tokenswhen the skill loads
GitHub stars
162on aahl/skills
Scripts
None found

What it does

“中国国家统计局公开数据查询技能,当用户想查询经济、CPI、GDP、人口、房价指数等数据时触发。”
The author's description, from SKILL.md

Generated summary from the skill's own text

This skill enables the agent to query China's National Bureau of Statistics public data API to retrieve economic indicators, CPI, GDP, population, and property price indices. The agent can browse indicator categories, search for specific metrics, and fetch statistical data across time periods and geographic regions including provinces and major cities.

When to use it

  • User asks for Chinese economic data, inflation rates, or GDP figures
  • Searching for property price indices or housing market data in China
  • Retrieving population statistics or demographic data by region
  • Querying historical economic trends across Chinese provinces or cities

When not to

  • Data needed from sources outside China's official statistics
  • Real-time stock market or financial trading data required
  • User needs international comparative economic data

Install

These commands install from the publisher's repository and need no account.

skills CLI

npx skills add aahl/skills --skill cn-stats

Installs from the repository's default branch, which may have changed since the commit we checked.

GitHub CLI 2.90 or later

gh skill install aahl/skills cn-stats@47edd621dff44253677d2ed14c223393ca020407

Installs the commit we checked (47edd62).

Copy by hand

Download the folder at 47edd62 and put it in .claude/skills/cn-stats for Claude Code and in .agents/skills/cn-stats for Codex, Cursor, Gemini CLI, GitHub Copilot and OpenCode.

Skill folder on GitHub at 47edd62

Copy for your agent

A prompt for any coding agent. It installs this skill from GitHub at the pinned commit, copies the files as they are, and runs nothing unless you ask.

Prompt

Install the agent skill "cn-stats" by aahl.

Source, pinned to commit 47edd621dff44253677d2ed14c223393ca020407:
https://github.com/aahl/skills/tree/47edd621dff44253677d2ed14c223393ca020407/skills/cn-stats

1. Download that folder at exactly this commit. Do not use the default branch.
2. Copy every file unchanged, keeping the folder structure, into .claude/skills/cn-stats/ for Claude Code and .agents/skills/cn-stats/ for Codex, Cursor, Gemini CLI, GitHub Copilot and OpenCode. Create the folders if they do not exist.
3. Do not edit the files, and do not run any script in the folder unless I ask you to.
4. When you are done, list the files you copied and where you put them.

Listing and checks: https://www.agentnative.dev/skills/aahl/cn-stats

SKILL.md at the pin

---
name: cn-stats
description: 中国国家统计局公开数据查询技能,当用户想查询经济、CPI、GDP、人口、房价指数等数据时触发。
---

# 国家统计局
```bash
# 全局环境变量
BASE_URL='https://data.stats.gov.cn/dg/website/publicrelease/web/external'

JQ_INDICATORS='.data | {total}, (.list[] | {_id, type, chart_style_text, i_showname})'
JQ_AREAS='.data[] | [.name_value,.name_text] | @tsv'

# 获取指标分类根节点ID
# code: {1:月度数据, 2:季度数据, 3:年度数据, 4:分省月度数据, 5:分省季度数据, 6:分省年度数据}
#       {7:主要城市月度价格, 8:主要城市年度数据, 9:港澳台月度数据, 10:港澳台年度数据}
#       {12:三大经济体月度数据, 13:国际市场月度商品价格, 14:主要国家年度数据}
ROOT_ID=$(curl "$BASE_URL/new/queryIndexTreeAsync?pid=&code=1" | jq -r '.data[0]._id // .')

# 获取指标分类子节点
curl "$BASE_URL/new/queryIndexTreeAsync?pid=$ROOT_ID&code=1" | jq -r '.data[] | {_id, name, type, isLeaf}'

# 获取指标列表 (isLeaf==true)
curl "$BASE_URL/new/queryIndicatorsByCid?cid=$NODE_ID&dt=&name=" | jq -r $JQ_INDICATORS

# 搜索指标列表
curl -G "$BASE_URL/new/queryIndicatorsByCid?cid=&dt=&rootId=$ROOT_ID" \
  --data-urlencode 'name=<关键词>' \
| jq -r $JQ_INDICATORS

# 获取统计数据 - 多指标
# dts: 时间范围 {年: 2026YY | 2022YY-2026YY, 月: 202501MM-202512MM}
curl "$BASE_URL/stream/esData" \
  -H 'Content-Type: application/json;charset=UTF-8' \
  -H 'Referer: https://data.stats.gov.cn/dg/website/page.html' \
  --data-raw '{
  "cid": "分类NODE_ID(isLeaf==true)",
  "indicatorIds": ["指标ID1","指标ID2"],
  "daCatalogId": "",
  "das": [{"text":"全国","value":"000000000000"}],
  "showType": "1",
  "dts": "",
  "rootId": "根节点ROOT_ID"
}' | jq -r '
  .data[] | 
  .name as $year |
  .values[] |
  [$year, ._name, .value // "-", .du_name] |
  @tsv
'

# 获取地区分类
curl "$BASE_URL/getDaCatalogTreeByIndicatorCid?indicatorCid=$NODE_ID"

# 获取地区列表
curl "$BASE_URL/getDasByDaCatalogId?daCid=$DA_CATELOG_ID&rootId=$ROOT_ID" | jq -r $JQ_AREAS

# 获取国内全部省份
curl "$BASE_URL/getDasByDaCatalogId?daCid=a10dceae75d245008bf4b9a0e6fe1d55" | jq -r $JQ_AREAS

# 获取国内大中城市
curl "$BASE_URL/getDasByDaCatalogId?daCid=44016f1bffeb4ea49fe34e100c6415fb" | jq -r $JQ_AREAS

# 获取统计数据 - 多地区
curl "$BASE_URL/stream/esData" \
  -H 'Content-Type: application/json;charset=UTF-8' \
  -H 'Referer: https://data.stats.gov.cn/dg/website/page.html' \
  --data-raw '{
  "cid": "分类NODE_ID(isLeaf==true)",
  "indicatorIds": ["指标ID"],
  "daCatalogId": "",
  "das":[{"text":"上海市","value":"310000000000"},{"text":"北京市","value":"110000000000"}],
  "showType": "3",
  "dts": ["202301MM-202512MM"],
  "rootId": "根节点ROOT_ID"
}' | jq -r '
  .data[] | 
  .name as $year |
  .values[] |
  [$year, ._name, .value // "-", .du_name] |
  @tsv
'

# 全局数据查询
curl -G "$BASE_URL/query?code=&pagenum=1&pageSize=15" \
  --data-urlencode 'search=<中文关键词>' \
  -H 'client: pc' \
  -H 'Accept: application/json, text/plain, */*' \
  -H 'Referer: https://data.stats.gov.cn/dg/website/page.html' \
| jq -r '.data | {types,count}, (.data[] | {cid,indic_id,show_name,da_name,da,dt,dt_type,value,explain})'
```

## 常用数据
```bash
# 大中城市住宅销售价格指数
curl "$BASE_URL/new/queryIndicatorsByCid?cid=3eb43764c74741469b745c396cf002d1&dt=&name=" | jq -r $JQ_INDICATORS
```

From aahl/skills at 47edd62, shown as plain text under its license: MIT (permissive). The license text is in LICENSE.

View SKILL.md on GitHub at 47edd62

Files

1 file, 3.5 KB in total. Each file has a sha256 in the pin's manifest; the first 12 characters are shown.

Skill folder on GitHub at 47edd62
  • data-table-manager

    This skill manages n8n Data Tables through creation, import, querying, and mutation operations.

    by n8nOfficial publisher

    Claude Code, Codex, Cursor +3 · about 2.1K tokens · pinned 6 days ago

  • algolia-automation

    This skill automates Algolia search and indexing operations through the Rube MCP interface.

    by ComposioOfficial publisher

    Claude Code, Codex, Cursor +3 · about 690 tokens · pinned 6 days ago

  • expo-sqlite

    This skill enables SQLite database operations in Expo and React Native apps for structured data storage, offline queues, and persistent caches.

    by ExpoOfficial publisher

    Claude Code, Codex, Cursor +4 · about 2.6K tokens · pinned 6 days ago

  • prisma-8

    This skill helps agents work with Prisma 8, a contract-first data layer for TypeScript projects.

    by PrismaOfficial publisher

    Contains scripts

    Claude Code, Codex, Cursor +3 · about 3.5K tokens · pinned 6 days ago

  • analyzing-experiment-session-replays

    This skill enables agents to analyze session recordings from experiment variants to identify behavioral differences between control and test groups.

    by PostHogOfficial publisher

    Claude Code, Codex, Cursor +4 · about 2.3K tokens · pinned 6 days ago

  • auditing-warehouse-view-health

    Audits materialized views in a PostHog data warehouse to identify failed views and flag unused ones that waste compute resources.

    by PostHogOfficial publisher

    Claude Code, Codex, Cursor +4 · about 1.4K tokens · pinned 6 days ago

The skills listed here are third-party software, collected from public GitHub repositories as a catalog of recent skills and provided as is. Agent Native does not write or control them and is not responsible for any harm, loss or damage caused by installing or using them. Labels and checks describe what we saw at one commit and are not a guarantee. Read a skill's files before you run it. Terms of use