Slac Mcp

io.github.DennisPrediger由 GitHub 账号 DennisPrediger 发布v1.1.1更新于 Oct 24, 2026

MCP server exposing SLAC (Simple Logic & Arithmetic Compiler) as tools for LLM agents

已验证STDIO仅桌面开发者工具

概览

AI 生成的概览

一个本地 MCP 服务器,将 SLAC 表达式编译器作为工具提供给助手,用于求值逻辑与算术表达式并查询语言语法。

可以做什么
对 SLAC 表达式进行编译求值并返回结果,默认返回 Rust 的 Display 表示,设置 OUTPUT_FORMAT 为 JSON 时返回序列化 JSON。获取完整的 SLAC 语言参考,包括语法、运算符、函数和示例。支持算术、字符串和条件表达式,例如 max(10, 20) + 1 或 len('test') > 2 ? 'long' : 'short'。
适用场景
适合助手需要计算或校验 SLAC 表达式,或需要语言参考来写出合法 SLAC 语法时使用,而不是自行推算。
运行要求
以本地进程通过 stdio 运行。README 的使用与开发部分用 Cargo 构建和运行,并说明需要 Rust 1.85+(edition 2024);清单中列有 npm 包 slac-mcp。未声明账号、API 密钥或请求头。可选设置 OUTPUT_FORMAT=JSON 以获得 JSON 输出。
安装前请注意
README 说明用 cargo run 启动,而清单列出的是 npm 包,安装前应确认适用哪种方式。表达式在本地编译求值,只传入你愿意被求值的表达式。

安装

在 SourceWeft 中

  1. 打开 控制台中的 Slac Mcp,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

slac-mcp

MCP server exposing SLAC (Simple Logic & Arithmetic Compiler) as tools for LLM agents.

Tools

ToolParametersDescription
evaluateexpression: stringCompiles and evaluates a SLAC expression, returns the result
get_syntaxnoneReturns the full SLAC language reference (syntax, operators, functions, examples)

Usage

sh
cargo run

The server communicates over stdio using the Model Context Protocol.

Output Format

By default, evaluate returns the Rust Display representation of the result. Set OUTPUT_FORMAT=JSON to get serialized JSON instead

With MCP Inspector

sh
npx @modelcontextprotocol/inspector cargo run

Example expressions

1 + 2max(10, 20) + 1'hello' + ' ' + 'world'len('test') > 2 ? 'long' : 'short'

Development

sh
cargo buildcargo run

Requires Rust 1.85+ (edition 2024).

License

Copyright 2026 Dennis Prediger

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

来源:npm/slac-mcp/README.md,提交 a130e01

工具

0
SourceWeft 尚未在沙箱中启动过该软件包,因此其工具未知。

版本历史

1
  1. v1.1.1最新Sep 16, 2026

评分

已满足适用检查项的 50%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通25 分

    请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。

  • 已声明认证方式10 分

    请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。

  • 已列出工具15 分

    请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。

  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分