Skip to content
Back to skills

Graph Context

ASecurity

Build and format graph context for codebase analysis. Trigger: When loading graph_context module for codebase analysis workflows.

  • 5 stars
  • 0 votes
  • 3 copies
  • 6 views
  • Added October 4, 2026
ai-agentspythonbashdockerapi

Works with

  • api

Security analysis

A100/100

Scanned October 4, 2026

npx -y skills add JNZader/repoforge --skill graph_context --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Graph Context?

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

Security grade badge for Graph Context
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/jnzader-graph-context/badge)](https://www.skillsdirectory.com/skills/jnzader-graph-context)

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: add-graph-context-endpoint
description: >
  Build and format graph context for codebase analysis.
  Trigger: When loading graph_context module for codebase analysis workflows.
license: Apache-2.0
metadata:
  author: repoforge
  version: "1.0"
complexity: medium
token_estimate: 1200
dependencies: []
related_skills: [build-graph-context, format-api-surface]
load_priority: high
---<!-- L1:START -->
# add-graph-context-endpoint

One sentence: Builds and formats graph context for codebase analysis workflows.

**Trigger**: When loading graph_context module for codebase analysis workflows.
<!-- L1:END -->

<!-- L2:START -->
## Quick Reference

| Task | Pattern |
|------|---------|
| Build graph context | `build_graph_context()` |
| Select code snippets | `select_code_snippets()` |
<!-- L2:END -->

<!-- L3:START -->
## Critical Patterns (Detailed)

### Pattern 1: build_graph_context

Builds graph context from root directory and optional file list.

```python
# Real code using actual exported names from this module
context = build_graph_context(root_dir: str, files: list[str] | None=None) -> str
```

### Pattern 2: select_code_snippets

Selects optimal code snippets within token budget.

```python
# Real code using actual exported names from this module
snippets = select_code_snippets(graph, "/path/to/code", entry_points=["main.py"], token_budget=2000)
```

## When to Use

- Analyzing codebase structure for AI context
- Selecting relevant code snippets within token limits
- Building structured graph representations

## Commands

```bash
python -m repoforge.graph_context --help
docker run --rm -v $(pwd):/code repoforge/graph_context:latest
```

## Anti-Patterns

### Don't: Ignore token budget when selecting snippets

```python
# BAD - will exceed context window
snippets = select_code_snippets(graph, root_dir, token_budget=100)  # Too small
```
<!-- L3:END -->

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.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.