tauri-syntax-state

tauri-syntax-state is a skill for Claude Code from OpenAEC-Foundation/OpenAEC-Workspace-Composer. It costs 95 tokens per session (1,930 once invoked), scanned A, original, MIT.

A guide to shared application data in Tauri 2, such as settings or in-memory values that multiple commands can access. It explains how to register this data and protect it when several tasks use it at once.

In plain words
What is it for?
Use it to register state during startup, access it from Rust commands or app handles, choose between mutexes and read-write locks, and handle optional state safely.
Why use it?
It helps prevent runtime failures from unregistered or mismatched state, deadlocks caused by locks, and unnecessary wrappers around data that does not need them.

Skill for Claude Code

Written for Claude Code: installed under .claude/. Also seen: mentions Claude Code.

Good fit Use it to register state during startup, access it from Rust commands or app handles, choose between mutexes and read-write locks, and handle optional state safely.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/openaec-foundation/openaec-workspace-composer/tauri-syntax-state
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 OpenAEC-Foundation/OpenAEC-Workspace-Composer --skill tauri-syntax-state
Clone the repo
git clone --depth 1 https://github.com/OpenAEC-Foundation/OpenAEC-Workspace-Composer

Made for: Claude Code.

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 tauri-syntax-state

README.md
[![agentmods](https://agentmods.dev/badge/skills/openaec-foundation/openaec-workspace-composer/tauri-syntax-state/github.svg)](https://agentmods.dev/skills/openaec-foundation/openaec-workspace-composer/tauri-syntax-state)
Your own site
<a href="https://agentmods.dev/skills/openaec-foundation/openaec-workspace-composer/tauri-syntax-state"><img src="https://agentmods.dev/badge/skills/openaec-foundation/openaec-workspace-composer/tauri-syntax-state/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 tauri-syntax-state

Your own site · 80×15
<a href="https://agentmods.dev/skills/openaec-foundation/openaec-workspace-composer/tauri-syntax-state"><img src="https://agentmods.dev/badge/skills/openaec-foundation/openaec-workspace-composer/tauri-syntax-state.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 95 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,930 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.
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.00095 $0.01930
Opus 5 $0.00048 $0.00965
Sonnet 5 $0.00019 $0.00386
Haiku 4.5 $0.00010 $0.00193

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

Security

Grade A, and why

tauri-syntax-state 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 11d 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.

.claude/skills/tauri-2/tauri-syntax/tauri-syntax-state/SKILL.md · 254 lines

How it starts

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

tauri-syntax-state

Quick Reference

State Registration (Tauri 2.x)

Method Context Description
Builder::manage(T) Builder chain Register state during app construction
App::manage(T) setup() hook Register state that depends on app initialization
AppHandle::manage(T) Any context Register state at runtime (rare)

State Access

Method Context Returns
State<'_, T> Command parameter Injected automatically by Tauri
app_handle.state::<T>() Any code with AppHandle State<'_, T> (panics if not registered)
app_handle.try_state::<T>() Any code with AppHandle Option<State<'_, T>> (safe)

Thread-Safety Wrappers

Wrapper Use Case Lock Method
std::sync::Mutex<T> Mutable state, no .await while locked .lock().unwrap()
tokio::sync::Mutex<T> Mutable state with .await while locked .lock().await
std::sync::RwLock<T> Read-heavy access, concurrent readers .read().unwrap() / .write().unwrap()
None (immutable) Read-only config data Direct field access

Critical Warnings

NEVER use State<'_, T> when you registered Mutex<T> — the type must match EXACTLY or Tauri panics at runtime, not at compile time. If you registered Mutex<Counter>, the command parameter must be State<'_, Mutex<Counter>>.

NEVER wrap managed state in Arc — Tauri already wraps all managed state in Arc internally. Using app.manage(Arc::new(data)) adds a redundant layer.

NEVER lock the same Mutex twice in the same call chain — this causes a deadlock. If a function holding a lock calls another function that also locks, the thread blocks forever.

NEVER use tokio::sync::Mutex unless you need to hold the lock across .await points — std::sync::Mutex is more efficient for synchronous access.

ALWAYS register state before any command tries to access it — accessing unregistered state via State<T> causes a runtime panic.

Read the full file on GitHub · 254 lines

Files

What ships with it

3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 11d ago First seen · 254 lines · 95 tokens per session scan A 58ae1d0a3130

Subscribe to this mod's changes

tauri-syntax-state is a skill published in the GitHub repository OpenAEC-Foundation/OpenAEC-Workspace-Composer (5 stars, last pushed 5mo ago), licensed MIT. It adds 95 tokens to every session and 1,930 once invoked, about $0.0005 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-31.

Related

Other skills, from other repositories

service-app-creator

Create or update the Service component of a NextClaw Mini App, choosing between Portable Rust/WASI Components and native-process MCP services. Use after nextclaw-app-creator selects a Service-backed app, or when the user explicitly asks for Service Actions, portable components, local files, external APIs, commands…

Peiiii/nextclaw · 74 tokens

schema-validation

JSON/data schema validation for construction data exchange: API payloads, file imports, BIM exports. Ensure data structure compliance before processing.

datadrivenconstruction/DDC_Skills_for_AI_Agents_in_Construction · 29 tokens

erp-data-extractor

Extract and analyze data from construction ERP systems. Pull project data for analytics, reporting, and integration.

datadrivenconstruction/DDC_Skills_for_AI_Agents_in_Construction · 25 tokens

interoperability-analyzer

Analyze data interoperability issues in construction projects. Identify format incompatibilities and data loss points.

datadrivenconstruction/DDC_Skills_for_AI_Agents_in_Construction · 23 tokens

massing-bim

Drive a Massing BIM/AEC project from an AI agent over MCP — read a project's status, records, CDE, KPI and model-quality checks; run standards-compliance, schedule-risk, embodied-carbon, permit- readiness and drawing-QA analyses; author the IFC model with GUID-stable recipes; and draft RFIs. Use when the user asks to…

ibuilder/massing · 90 tokens

ara3d-sdk

Use when processing AEC/BIM 3D data in .NET 8 — mesh generation and transformation, SIMD-accelerated math, IFC/STEP/PLY to glTF/GLB/VIM conversion, plugin development. Ara3D-SDK: high-performance .NET 3D geometry and BIM library suite.

znlgis/opengis-skills · 70 tokens