# Ccg Namespace

> code-context-graph — namespace file management for MSA / multi-project isolation.

- **Type:** Skill
- **Install:** `agentstack add skill-tae2089-code-context-graph-ccg-namespace`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [tae2089](https://agentstack.voostack.com/s/tae2089)
- **Installs:** 0
- **Category:** [AI & ML](https://agentstack.voostack.com/c/ai-and-ml)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [tae2089](https://github.com/tae2089)
- **Source:** https://github.com/tae2089/code-context-graph/tree/main/skills/ccg-namespace

## Install

```sh
agentstack add skill-tae2089-code-context-graph-ccg-namespace
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# ccg-namespace — Namespace File Management

Manage uploaded source or documentation files in isolated **namespaces**. Use this for MSA environments or workflows spanning multiple repositories.

## Terminology

| Term | Status | Meaning |
| ---- | ------ | ------- |
| `namespace` | Canonical | Isolation key for graph data, uploaded files, RAG indexes, and postprocess policy |
| `--namespace-root` | Canonical | Root directory that stores namespace file trees |

For single-project local work, you usually do not need a named namespace. Use `ccg build .` and the default namespace.

## Folder Structure

```
{namespace-root}/
├── payment-svc/
│   ├── handler.go
│   └── service.go
├── user-svc/
│   └── auth.go
└── gateway/
    └── router.go
```

Configured via `ccg serve --namespace-root ` for local stdio MCP, or
`ccg-server --namespace-root ` for self-hosted HTTP MCP (default:
`namespaces/`).

## Core Patterns

### Upload, Then Build And Search

```
upload_file(namespace: "payment-svc", file_path: "handler.go", content: "")
→ build_or_update_graph(namespace: "payment-svc", path: "{namespace-root}/payment-svc")
→ search(namespace: "payment-svc", query: "payment")
```

### Wiki And RAG Per Namespace

```
upload_file(namespace: "my-service", file_path: "docs/handler.go.md", content: "")
→ build_rag_index(namespace: "my-service")
→ search_docs(namespace: "my-service", query: "handler")
→ get_doc_content(namespace: "my-service", file_path: "docs/handler.go.md")
```

### Bulk Upload

```
upload_files(files: '[{"namespace":"payment-svc","file_path":"a.go","content":""},...]')
```

`files` is a JSON string containing an array. Prefer bulk upload over many single-file calls.

## MCP Tools

| Tool | Use |
| ---- | --- |
| `upload_file` | Upload one file to a namespace (base64) |
| `upload_files` | Upload many files to namespaces (JSON array) |
| `list_namespaces` | List all namespaces |
| `list_files` | List files in a namespace |
| `delete_file` | Delete one file from a namespace |
| `delete_namespace` | Delete a namespace and its files |

## Security

- Path traversal (`../`) is blocked
- Namespace names must be single safe path segments
- Symlink traversal is rejected before file writes
- File size and bulk request size are capped

## Operational Tips

- Use one namespace per service or repository when graph/search state should stay isolated.
- Keep reference-only services in separate namespaces and rebuild them rarely.
- Delete retired service state with `delete_namespace` to remove graph, RAG, and search noise.

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [tae2089](https://github.com/tae2089)
- **Source:** [tae2089/code-context-graph](https://github.com/tae2089/code-context-graph)
- **License:** MIT

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-tae2089-code-context-graph-ccg-namespace
- Seller: https://agentstack.voostack.com/s/tae2089
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
