spherse-build-data-app

spherse-build-data-app is a skill for Claude Code, Codex from mengrru/Spherse. It costs 65 tokens per session (3,215 once invoked), scanned A, original, MIT.

A method for building data-driven web applications around a shared JSON data file. It defines named queries and controlled changes so both the webpage and AI agents can read and update the same data safely.

In plain words
What is it for?
Use it to build forums, task systems, simulations, communities, knowledge bases, and workflow boards whose pages and agents share editable data.
Why use it?
It prevents agents from repeatedly loading large data files or manually editing the wrong fields. Shared rules also reduce accidental overwrites when data changes.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to build forums, task systems, simulations, communities, knowledge bases, and workflow boards whose pages and agents share editable data.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/mengrru/spherse/spherse-build-data-app
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add mengrru/Spherse --skill spherse-build-data-app
Clone the repo
git clone --depth 1 https://github.com/mengrru/Spherse

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for spherse-build-data-app

README.md
[![agentmods](https://agentmods.dev/badge/skills/mengrru/spherse/spherse-build-data-app/github.svg)](https://agentmods.dev/skills/mengrru/spherse/spherse-build-data-app)
Your own site
<a href="https://agentmods.dev/skills/mengrru/spherse/spherse-build-data-app"><img src="https://agentmods.dev/badge/skills/mengrru/spherse/spherse-build-data-app/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for spherse-build-data-app

Your own site · 80×15
<a href="https://agentmods.dev/skills/mengrru/spherse/spherse-build-data-app"><img src="https://agentmods.dev/badge/skills/mengrru/spherse/spherse-build-data-app.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 65 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,215 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00065 $0.03215
Opus 5 $0.00032 $0.01607
Sonnet 5 $0.00013 $0.00643
Haiku 4.5 $0.00006 $0.00321

Measured 12d ago against content hash d92352753af7, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

spherse-build-data-app scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 12d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

packages/presets/skills/spherse-build-data-app/SKILL.md · 287 lines

How it starts

The opening of the file, as written. The whole thing — 287 lines — stays where its author put it; the contents beside it link to each section on GitHub.

构建数据型应用

数据型应用是由 HTML 页面和一个或多个 Agent 围绕同一份 *.data.json 持续互动的应用,例如虚拟论坛、任务系统、经营模拟、社区、知识库或工作流看板。

这套 data 能力有两个核心目标:

  1. 让 Agent 通过业务命名的查询只获取当前任务所需的数据,避免每次读取整个数据文件占用上下文。
  2. 让页面和 Agent 通过经过 schema 校验的原子 mutation 修改数据,避免手工编辑 JSON 时选错路径、写错字段或覆盖并发变更。

本 Skill 负责数据建模与协作方式。生成 HTML 时同时加载 spherse-write-html,查询 UI SDK 参数时加载 spherse-use-ui-sdk

核心原则

  • 数据会增长或需要 Agent 参与读写时,必须使用 *.data.json 并内嵌 $manifest
  • 先设计 Agent 会问的问题和会执行的业务动作,再设计 queriesmutations,最后生成页面。
  • $manifest 当作页面与 Agent 共享的业务接口,不只是数据结构说明。
  • Agent 首次接触文件时用 read_data 获取 outline,后续优先使用 query_datamutate_data
  • 页面和 Agent 对同一种业务写入必须调用同名 mutation,不能各自实现一套读改写逻辑。
  • 集合条目必须有稳定且唯一的 identity,通常是由 auto 生成的 UUID。
  • manifest 保持精简(建议不超过 2KB),只保存路径映射、入口描述和 schema,不放示例数据。
  • manifest 的 path 使用对象字段 dot-path(如 forum.threads),不支持数组下标。
  • 创建参与互动的 Agent 时,根据职责显式启用所需的 data tools,并遵循最小权限原则。

设计工作流

1. 列出 Agent 的读取问题

从 Agent 的实际任务出发列出需要回答的问题,而不是先暴露整份数据。例如虚拟论坛中的 Agent 可能需要:

  • 查看最新的开放主题
  • 按板块查看主题
  • 根据主题 ID 获取单个主题
  • 查看某个主题下的回复

将高频、边界明确的问题设计为命名 query。query 名称应表达业务语义,例如 listOpenThreadslistRepliesByThread,不要使用 getDataqueryItems 等模糊名称。

当前 query 引擎适合数组数据,支持:

  • enum、string、integer、boolean 参数按同名字段相等过滤
  • identity 字段精确定位单条记录
  • sort + dir 排序
  • defaultLimitlimitafter 分页

需要分页或按 ID 定位的 query 必须声明唯一 identity。翻页时把上次结果的 nextAfter 传给下一次调用;不要修改已有条目的 identity。

不要为了“以后可能需要”暴露大量入口。只声明页面或 Agent 确实会使用的查询。

2. 列出业务写入动作

把每种写入建模为命名 mutation:

业务动作 mutation op 示例
新增集合条目 append createThreadaddReply
按 identity 修改条目 update setThreadStatus
按 identity 删除条目 remove removeReply
合并更新对象 set updateForumStats

mutation 名称描述业务动作,fields 只开放允许调用方写入的字段。使用 requiredenumdefault 固化数据约束;使用 auto.uuidauto.nowIso 统一生成 identity 与时间。

match 用于 updateremove 定位条目,通常与对应 query 的 identity 相同。调用方把 match 字段放在 args 中传入,但不要在 fields 中重复声明。

3. 同源生成三部分

一次完成并保持一致:

  1. *.data.json 的业务数据结构和 $manifest
  2. HTML 的读取、渲染与 spherse.data.mutate 调用
  3. 参与 Agent 的职责说明和 data tool 权限

Read the full file on GitHub · 287 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 12d ago First seen · 287 lines · 65 tokens per session scan A d92352753af7

Subscribe to this mod's changes

spherse-build-data-app is a skill published in the GitHub repository mengrru/Spherse (73 stars, last pushed 6d ago), licensed MIT. It adds 65 tokens to every session and 3,215 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

build-with-tinybase

Scaffold, extend, and verify reactive local-first JavaScript or TypeScript applications with TinyBase. Use when choosing TinyBase for in-memory tabular or key-value state, generating an app with create-tinybase, adding schemas or UI bindings, configuring browser or database persistence, configuring MergeableStore…

tinyplex/tinybase · 76 tokens

web-design

Penguin visual language for generated web pages and app UIs — GitHub-style simplicity with a single blue accent, light and pure-black dark themes, design tokens, component and chat-interface recipes, plus an opt-in warm paper editorial theme.

Prism-Shadow/penguin-harness · 51 tokens

minimal-web-baas-demo

A guide for quickly building a small CloudBase web application with a database, such as a to-do list, notes app, or message board.

TencentCloudBase/CloudBase-AI-Toolkit · 144 tokens

redux-to-swr

Migrate React components from Redux + Saga to SWR hooks. Use when converting data fetching from Redux store (reducers, sagas, selectors, connect HOC) to SWR-based hooks in CockroachDB DB Console or cluster-ui.

cockroachdb/cockroach · 53 tokens

react-class-to-functional

Convert React class components to functional components with hooks.

cockroachdb/cockroach · 14 tokens

neo4j-nvl-skill

Neo4j Visualization Library (NVL) — framework-agnostic graph rendering for the browser. Covers @neo4j-nvl/base (NVL class, nodes/relationships, Canvas vs WebGL renderer), @neo4j-nvl/interaction-handlers (ZoomInteraction, PanInteraction, DragNodeInteraction, ClickInteraction, HoverInteraction, BoxSelectInteraction…

neo4j-contrib/neo4j-skills · 227 tokens