000-project-context

000-project-context is a cursor rule for Cursor from arango-solutions/arango-sparql-py. It costs 735 tokens per session, scanned A, original, MIT.

A set of always-on project rules for arango-sparql-py, a Python service that converts SPARQL queries into ArangoDB queries.

In plain words
What is it for?
Use it when changing SPARQL translation, ArangoDB query generation, the FastAPI service, dependencies, or tests.
Why use it?
It keeps development aligned with the project’s required parser, safe query-building, legacy behavior, and application structure.

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/arango-solutions/arango-sparql-py/000-project-context
Clone the repo
git clone --depth 1 https://github.com/arango-solutions/arango-sparql-py

Made for: Cursor.

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 000-project-context

README.md
[![agentmods](https://agentmods.dev/badge/rules/arango-solutions/arango-sparql-py/000-project-context.svg)](https://agentmods.dev/rules/arango-solutions/arango-sparql-py/000-project-context)
Your own site
<a href="https://agentmods.dev/rules/arango-solutions/arango-sparql-py/000-project-context"><img src="https://agentmods.dev/badge/rules/arango-solutions/arango-sparql-py/000-project-context.svg" alt="Measured on agentmods" height="20"></a>
Per session 735 This file is loaded in full into every session.
When invoked 735 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.00735 $0.00735
Opus 5 $0.00367 $0.00367
Sonnet 5 $0.00147 $0.00147
Haiku 4.5 $0.00073 $0.00073

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

Security

Grade A, and why

000-project-context 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 5d 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.

.cursor/rules/000-project-context.mdc · 62 lines

How it starts

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

Project: arango-sparql-py

You are an expert Semantic Web and ArangoDB developer building arango-sparql-py, a Python microservice that transpiles SPARQL 1.1 queries into ArangoDB AQL.

This project is the modernization of the legacy JavaScript Foxx service arango-sparql and the sister project to arango-cypher-py.

Hard guardrails (non-negotiable)

  1. DO NOT use ANTLR or roll a custom SPARQL parser. Always use rdflib.plugins.sparql.parser.parseQuery() to obtain the SPARQL AST (Algebra), then walk it with a Python visitor.
  2. Never hand-concatenate AQL. All AQL must be emitted via the parameterized AQL query builder (mirroring arango-cypher-py's pattern) so bind variables are the only injection-safe path.
  3. Do not invent translation rules. The semantic mapping of SPARQL constructs to AQL must be ported from the legacy references/arango-sparql/src/lib/*-translator.js files. When in doubt, read the JS first and translate the behavior, not the syntax.
  4. Match arango-cypher-py architecture. FastAPI app factory, route modules, pydantic request/response models, multitenancy guards, uv + pyproject.toml dependency management, and pytest harness layout must be structurally identical so a developer who knows one repo can read the other immediately.

Reference repos (sibling projects)

When you need to understand a pattern, consult these — they are symlinked into references/:

  • references/arango-cypher-py/ — the architecture template (FastAPI, nl2cypher, eval harness, UI shell, pyproject layout).
  • references/arango-sparql/ — the legacy Foxx service whose SPARQL→AQL translation semantics are being ported (read-only source of truth for query translation behavior).
  • references/arango-schema-mapper/ — generates the OWL/Turtle ontology this service consumes for URI→collection resolution.

Directory anchors

  • arango_sparql/ — Python package (mirror of arango_cypher/).
  • arango_sparql/service/ — FastAPI app + routes (mirror of arango_cypher/service/).
  • arango_sparql/nl2sparql/ — NL→SPARQL pipeline (mirror of arango_cypher/nl2cypher/).
  • tests/ — pytest harness; tests/w3c/ is the SPARQL DAWG runner (analog of arango-cypher-py/tests/tck/).
  • ui/ — Vite + React + TypeScript frontend (mirror of arango-cypher-py/ui/).

Read the full file on GitHub · 62 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. 5d ago First seen · 62 lines · 735 tokens per session scan A c7a038dc02fc

Subscribe to this mod's changes

000-project-context is a cursor rule published in the GitHub repository arango-solutions/arango-sparql-py (2 stars, last pushed 18d ago), licensed MIT. It adds 735 tokens to every session, about $0.0037 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.