Skip to content
Back to skills

Write Graph Query

ASecurity

Write a bounded, typed traversal. Cypher examples first, then ISO GQL, then Gremlin or SPARQL 1.1 stubs. Flag unbounded * and untyped -[]- as bugs. Includes GraphRAG local/global/DRIFT query patterns.

  • 7 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added September 23, 2026
ai-agentsgorails

Security analysis

A100/100

Scanned September 23, 2026

npx -y skills add mcorbett51090/RavenClaude --skill write-graph-query --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Write Graph Query?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Write Graph Query
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/mcorbett51090-write-graph-query/badge)](https://www.skillsdirectory.com/skills/mcorbett51090-write-graph-query)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: write-graph-query
description: "Write a bounded, typed traversal. Cypher examples first, then ISO GQL, then Gremlin or SPARQL 1.1 stubs. Flag unbounded * and untyped -[]- as bugs. Includes GraphRAG local/global/DRIFT query patterns."
---

# Skill: write-graph-query

> **Invoked by:** `graph-query-engineer` (primary).
>
> **When to invoke:** "write this Cypher/GQL"; "why is this path slow?"; "local vs global GraphRAG search."
>
> **Output:** language pick + bounded pattern + index advice + lint result. Fill [`../../templates/query-language-decision.md`](../../templates/query-language-decision.md).

## Procedure

1. Pick the language from the **engine + model**, not the brand. Default teaching order: **Cypher first**, then GQL equivalent, then Gremlin / SPARQL 1.1 stubs. See [`../../knowledge/graph-languages-and-engines-2026.md`](../../knowledge/graph-languages-and-engines-2026.md).
2. **Type every relationship.** Bound every quantified path (`*1..N` or GQL `{1, N}`).
3. If the user pasted `-[*]->` or `-[]-`, rewrite it; do not “just add LIMIT.”
4. If the job is PageRank / community / global shortest-path over a projection, say **algorithm library** — do not invent `CALL algo.*`.
5. **GraphRAG query section** (only after a retrieval graph exists):
   - **Local** — bounded typed neighborhood of seed entities.
   - **Global** — read community summaries (not an unbounded walk).
   - **DRIFT** — local first, escalate to community text.
   Construction stays on `construct-retrieval-graph`.
6. Lint snippets with [`../../scripts/lint_graph_shape.py`](../../scripts/lint_graph_shape.py). Pre-GQL `*` in a `.gql` file is a WARNING.

## Guardrails

- Advisory only — the user runs the snippet. No driver.
- Not Neo4j-only. Not GraphQL (`.graphql` → `graphql-engineering`).
- Date any engine claim `[verify-at-use]`.
- SPARQL is 1.1 only.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…