Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault

No arguments

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

This server publishes no instructions, or was last inspected before Glama recorded them.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": true
}

Tools

Functions exposed to the LLM to take actions

NameDescription
list_tablesA

列出当前工作区的全部数值表清单:表名、所属模块、行数、列名。回答数值问题前先用它定位要查哪张表、有哪些列可用。

read_tableA

读取工作区内指定数值表的数据行。支持列选择、条件过滤(eq/ne/gt/gte/lt/lte/contains)、分页(offset/limit,默认前 20 行)。先用 list_tables 拿到表名和列名。

battle_simulateA

战斗模拟:玩家面板 × 敌人面板的对拼计算(确定性引擎,非 LLM 估算)。返回击杀刀数、被击刀数、咬合比 killRatio、评级(easy/balanced/tight/impossible)、期望 DPS;可选 Monte Carlo 胜率。用于改数值后评估战斗咬合变化。

simulate_gachaA

概率模拟(确定性引擎):mode=tiers 模拟无保底分层概率池(rogue 技能三选一、宝箱品质掉落)N 次抽取的各层次数分布与分位;mode=pity 模拟带保底的抽卡(基础概率+软/硬保底)抽数分布与期望。

compute_powerA

战力计算(确定性引擎,EHP×EDPS 开方模型):输入属性面板(中文键如 攻击/体力/暴击率/暴击伤害),返回战力、EDPS、EHP 与各属性边际价值。用于对比改数值前后的战力变化。

power_curveA

战力曲线(批量):读成长表逐行(可采样)属性面板调 computePowerStats,一次产出「等级→战力」全曲线与形态摘要(首/中位/末档战力、成长倍率、形态判定:匀速/后期加速/台阶断点)。属性列自动按常用名识别(攻击/攻击力→attack、体力/生命→hp、防御→defense、攻速/速度→speed、暴击率→crit),识别不到时用 columns 显式指定。适合全曲线分析与成长×装备联合推导,替代多次单点 compute_power。

eval_formulaA

确定性求值数值公式(四则/幂/括号/变量,支持中文变量名)。用于验证锚点公式、快速算数——数值永远由引擎算而非估算。

audit_columnA

列审计(对账):用锚点公式重算指定列的每一行(变量 x=varColumn 该行值,i=行序),报告偏离公式超过阈值(默认 1%)的行——识别成长曲线的手调断点。先看 list_tables 的 columnPatterns 了解列的既有模式。

infer_column_ruleA

列规则推断(确定性拟合,逆向分析的起点):对指定数值列拟合三大曲线族(等差/等比/幂律),返回最优规则——参数、吻合占比 fitPct、可直接使用的表达式——以及偏离规则的断点行(疑似手调)。分析成长/消耗曲线的构成规律先用它;得到规则后把 expression 交给 audit_column 复核,或用 write_table 的 apply_curve 按规则整列重算。

infer_table_relationA

表内列间派生关系推断(确定性拟合):判断「B 列 ≈ A 列 × k」的系数关系并标出偏离行(取整容限内免误报),或对整表数值列两两配对、自动发现基准锚点列与各列系数。还原「各装备属性 = 基准 × 装备系数」这类生成结构时用;发现系数后可与系数表(如 read_table 装备划分)对照确认同源性。列内时序规律(随行序怎么走)用 infer_column_rule,本工具管列与列的结构。

grade_workspaceA

工作区分级(逆向接入第一步):按输入契约三级分档扫描全部表——A 规范(双行表头点分列名比例/列生成模式命中率达标)、B 半规范(单行中文表头)、C 裸表(英文驼峰/无中文语义表头),输出工作区判级、逐表分级、覆盖率与孤儿表初判(无外键候选列且无角色候选信号)。分级结果可用 save_structure 固化到 structure.json。

profile_tableA

单表画像(确定性统计,无 LLM):行数、列类型分布、枚举度(distinct/行数)、单调性(递增/递减/无)、主键候选(唯一且非空列)、累计列校验(某列≈另一列逐行前缀和,取整容差)、角色候选(growth=有等级列且存在等差模式列;master_data=有索引/序号类列;cost=累计列校验成立)。逆向理解单表结构先用它,结论可经 save_structure 固化。

infer_foreign_keysA

表间外键推断(值域包含检测,确定性):from 列非空值域 ⊆ to 列值域、悬挂率 <5% 才成立,from 非空值 ≥3 防巧合;confidence = (1-悬挂率)×值域大小因子。输出候选关系边(kind=foreign_key,不落盘,供用户确认后经 save_structure 固化)。可指定 fromTable/toTable 定向检测;缺省全表两两扫描(输出按置信度排序的 topN 防爆炸)。

read_memoryA

读取工作区全部项目记忆(项目画像 PROFILE.md + 事实流 facts.md)。回答与历史结论相关的问题前先查记忆。

list_workspacesA

列出全部可用工作区(位于本机工作区根,GND_WORKSPACES_DIR 环境变量控制,缺省 ~/.gamenumerics/workspaces)。切换工作区用 set_workspace。

set_workspaceA

切换当前工作区(后续全部数值工具调用均作用于它)。name 须来自 list_workspaces 的列表。

import_xlsxA

从本地 xlsx 文件(绝对路径)导入并创建工作区:读取工作簿全部 sheet(或 sheets 参数指定子集),双行表头自动合并为「父.子」复合列名,数值列自动识别等差/等比/常数模式,装配为规范化 tables/*.json + workspace.json 并设为当前工作区。headerRows 缺省由启发式探测(结果随摘要回显,探测失误可显式指定 1/2 重试);同名工作区整体覆盖重建。mode=check 只做九规则格式检查(表头结构/类型合法性/外部工作簿引用/公式结构一致性——含公式矩阵 cell.f),不建工作区,返回 findings 清单。导入后即可用 list_tables / read_table / audit_column / export_table 等工具审计导出。

export_tableA

导出当前工作区的数值表为 lua record 数组模块(return { [1] = { Key = v, ... } })或 JSON 数组文本(format 缺省 lua)。中文列名自动转 ["列名"] 字符串键;columns 可选收窄导出列。产物超 1MB 拒绝并引导收窄。先 list_tables 拿表名。

recon_diffA

跨表对账(L3):当前工作区两张表按声明键列对齐、值列逐格比对。left 为明细/被检方,right 为基准/主数据方;left 键在 right 缺失 → error(外键断链同构);值比对容差 = 绝对半格(誊抄取整,缺省 0.5)+ 相对 1e-9。ratio 可声明倍率誊抄(如品质系数 1.4)。leftValues/rightValues 省略时为纯键域对账(FK 形态,多对一引用合法)。先 list_tables 拿表名与列名。

suggest_refsA

引用完整性候选发现:扫描当前工作区全部表,找出「A 表某列的值疑似引用 B 表某键列」的候选映射(值域包含推断,词面相似度仅排序)。候选不是结论——须向用户确认映射后,用 recon_diff 对确认的映射执行零容忍断链扫描。典型流程:suggest_refs 列候选 → 用户确认 → recon_diff 逐对检查(悬挂行即配置断链:关卡表配置的装备等级在装备等级表无对应条目)。

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

TDQS

A3.9/5.0

Scored across 20 tools

Disambiguation3/5

Most tools have distinct targets, and the descriptions are detailed enough to separate table I/O, column inference, simulation, and workspace management. However, infer_foreign_keys and suggest_refs are near-duplicate FK-candidate scanners, and read_table/export_table plus several column-analysis tools have partial boundary overlap.

Naming Consistency4/5

The vast majority of names follow a clear snake_case verb_noun pattern (list_tables, read_table, compute_power, set_workspace). Minor deviations like battle_simulate, power_curve, and recon_diff break the pattern but remain readable and predictable.

Tool Count4/5

At 20 tools the server is on the high side, but the scope is genuinely broad: import/workspace management, table I/O, structural inference, reconciliation, simulations, and calculation utilities. It is slightly heavy due to a couple of redundant FK tools, but not unreasonable for the domain.

Completeness2/5

The core read/import/analyze/simulate path is well covered, but key workflow tools referenced in the descriptions are missing: write_table (apply_curve) and save_structure cannot be called, so applying inferred rules or persisting structural results creates dead ends. There is also no update/delete or memory-write capability beyond workspace import.

Maintenance

ActivityMaintained
ResponsivenessNo issues