cursorrules

Rules for using Cursor with Sounio, a systems and scientific programming language whose source files use the .sio extension. They document Sounio syntax and its compiler checks.

In plain words
What is it for?
Use them when writing, checking, or running Sounio files, especially code involving input/output, mutation, division, or possible panics.
Why use it?
They prevent the coding agent from treating Sounio as Rust and introducing invalid syntax or missing required effect declarations.

Cursor rule for Cursor

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.

agentmods
npx agentmods add rules/sounio-lang/sounio/cursorrules
Clone the repo
git clone --depth 1 https://github.com/Sounio-lang/sounio

Made for: Cursor.

Per session 1,307 This file is loaded in full into every session.
When invoked 1,307 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
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 $0.01307 $0.01307
Opus 5 $0.00654 $0.00654
Sonnet 5 $0.00261 $0.00261
Haiku 4.5 $0.00131 $0.00131

Measured 2d ago against content hash 6a09f0766aa3, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

cursorrules 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 2d 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.

.cursorrules · 130 lines

How it starts

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

Sounio Language Rules for Cursor

Sounio (.sio) is a systems + scientific programming language. It is NOT Rust. Full syntax reference: docs/LLM_PROGRAMMING_GUIDE.md

Compiler

SOUC=./bin/souc $SOUC check file.sio # type-check $SOUC run file.sio # compile to temp ELF, then execute

Critical Syntax Differences from Rust

  • NO semicolons: let x = 5 not let x = 5;
  • NO &mut: use &! for exclusive refs
  • NO let mut: use var for mutable bindings
  • NO Rust macros: assert(cond) not assert!(cond), println("text") not println!("text")
  • NO unary minus: 0 - 42 not -42
  • NO closure literals: |x| x + 1 does not work. Use named fn refs: let f = square
  • NO attributes: no #[test], #[derive()]
  • Bit shifts require u8: x >> 4u8

Effects System (REQUIRED)

Functions must declare side effects or the compiler rejects them:

fn pure(a: i64, b: i64) -> i64 { a + b }
fn greet(name: &str) with IO { println(name) }
fn mutate(x: &!i32) with Mut { *x = 42 }
fn divide(a: f64, b: f64) -> f64 with Div, Panic { a / b }
fn main() with IO, Mut, Panic, Div { /* ... */ }

Effects: IO (print/file), Mut (&! mutation), Div (division/modulo), Panic (array access, assert, as casts)

Variables and Types

let x = 5                           // immutable
var y: i32 = 10                     // mutable
var buf: [i64; 8] = [0; 8]          // fixed-size array
let p = Point { x: 1.0, y: 2.0 }   // struct
let (a, b) = (1, 2)                 // tuple destructuring

Primitives: i8, i16, i32, i64, u8, u16, u32, u64, f32, f64, bool, char

Control Flow

for i in 0..10 { /* exclusive */ }
for i in 0..=10 { /* inclusive */ }
for x in arr { /* array iteration */ }
while cond { /* ... */ }
if x > 0 { "pos" } else { "neg" }   // if is an expression

break and continue work in for-in and while loops.

Functions and Methods

fn square(x: i64) -> i64 { x * x }

// Function references (closures do NOT work)
let f = square
let r = f(7)

// Higher-order
fn apply(f: fn(i64) -> i64, x: i64) -> i64 { f(x) }

// Methods use explicit self
impl MyStruct {
    fn new() -> MyStruct { MyStruct { val: 0 } }
    fn get(self: &MyStruct) -> i64 { self.val }
    fn set(self: &!MyStruct, v: i64) with Mut { self.val = v }
}

Read the full file on GitHub · 130 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. 2d ago First seen · 130 lines · 1,307 tokens per session scan A 6a09f0766aa3

Subscribe to this mod's changes

cursorrules is a cursor rule published in the GitHub repository Sounio-lang/sounio (5 stars, last pushed 2d ago), licensed Apache-2.0. It adds 1,307 tokens to every session, about $0.0065 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.