> ## Documentation Index
> Fetch the complete documentation index at: https://docs.graphify.com/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> The PyPI package is graphifyy, with two y's. The command is graphify.
> /graphify . is typed in an assistant chat, not in a shell.
> Use only commands, flags, and endpoints shown on these pages. Do not invent one.
> Choose the surface before you open a page. Local (Graphify Local) is the graphifyy package on the machine: the skill, the CLI, and the ten-tool MCP. Its pages are the Open Source tab (/open-source/) and the Graphify Local tab on each Integrations page. Graphify is the hosted workspace and https://api.graphify.com/mcp (Streamable HTTP, OAuth, no API key). Its pages are the Graphify tab (/platform/, /concepts/) and the Graphify (hosted) tab on each Integrations page. Prefer Graphify unless the user asks for a local or offline setup. Cookbooks (/cookbooks/) and /mcp/docs-search apply to both. Each page's source frontmatter records this as surface: local, cloud, or both. Buildkite is the CI integration.
> In llms.txt, tell the surface from the page path. Graphify: /platform/ and /concepts/. Local: /open-source/. Most /integrations/ pages cover both, with a Graphify (hosted) tab and a Graphify Local tab. Everything else applies to both.
> graphifyy release notes are published at https://github.com/Graphify-Labs/graphify/releases and https://graphify.com/changelog. The current package version is on PyPI (https://pypi.org/project/graphifyy/).
> The official site is https://graphify.com. These docs are https://docs.graphify.com.
> The local MCP server is the ten tools in the MCP tool reference and reads a graph on the machine. The hosted server is https://api.graphify.com/mcp (Streamable HTTP, OAuth, no API key). The JetBrains, ChatGPT, Codex, and Dots, and Vercel pages use the hosted server, not the ten-tool list. On pages with tabs, the Graphify (hosted) tab uses the hosted server and the Graphify Local tab uses the local skill or the ten-tool server.
> Read https://docs.graphify.com/llms.txt, then open one page's .md link. Use https://docs.graphify.com/llms-full.txt only when one page is not enough.

# Deduplication and symbol resolution

> How Graphify Local links calls and imports across files, tags every edge with its confidence, and merges duplicate entities without inventing connections.

Parsing one file at a time only gets you halfway. A call to `load_config()` in `app.py` is useful only when it points at the `load_config` defined in `config.py`, and a concept your docs call "Auth Service" should be the same node as the one another doc calls "auth service". Graphify Local does both before it writes the graph, and it labels how sure it is.

> [!NOTE]
>
> **Read this page when** you want to know whether to trust an edge, why two nodes merged, or why a call you expected isn't in the graph.

## How it works

### Symbol resolution

**1. Index**

Every file's definitions, imports, and exports are indexed with tree-sitter.

**2. Resolve across files**

Calls and references are matched to definitions through imports, re-exports, and language-specific passes (receiver types, qualified member calls, framework conventions). New languages plug in through a resolver registry.

**3. Tag confidence**

Each edge gets a tag, so you and your agent know what was read and what was worked out.

| Tag | Meaning |
| - | - |
| `EXTRACTED` | Written explicitly in the source, such as an import or a method on a class. |
| `INFERRED` | Derived by resolution, such as a call matched to its definition through imports. |
| `AMBIGUOUS` | Several targets were possible. Kept, but down-weighted in clustering. |

Resolution is conservative. When Graphify can't tell which of several definitions a call means, it records an `AMBIGUOUS` edge or no edge, rather than guessing.

### Deduplication

Entity deduplication runs on every build, before the graph is written:

**1. Exact match**

Labels are normalised (case, punctuation, Unicode marks) and identical ones merge.

**2. Candidate pairs**

MinHash with locality-sensitive hashing finds labels that might be the same, so Graphify never compares every pair.

**3. Verify**

Each candidate is scored with Jaro-Winkler similarity. Pairs in the same community get a 5-point bonus. A score of 92 or more merges.

**4. Guard rails**

Short labels only merge on a single-character typo, and labels that differ only in an embedded number (`ADR 0011` and `ADR 0012`) never merge.

**5. Rewire**

Edges and hyperedges are moved to the surviving node. Genuine ID collisions across files stay separate and are reported.

## See it in action

`explain` shows the tag on every connection:

```bash theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
graphify explain "APIRoute"
```

```text theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  --> RequestValidationError [uses] [INFERRED]
  --> Dependant [uses] [INFERRED]
  --> .get() [method] [EXTRACTED]
  <-- __init__.py [imports] [EXTRACTED]
```

## Configure

| To | Do this |
| - | - |
| Treat an extension as another language for resolution | Add `language.<ext>=...` to [`.graphifyrc`](https://docs.graphify.com/open-source/configuration/graphifyrc). |
| Change how much `AMBIGUOUS` edges affect communities | Set `GRAPHIFY_AMBIGUOUS_SCALE` (`1.0` = full weight, `0` = ignore). |
| Check for edges collapsed between the same two nodes | Run `graphify diagnose multigraph`. |

## Verify and troubleshoot

| Symptom | Fix |
| - | - |
| A call is missing | The target was probably ambiguous. Run `graphify explain` on the caller and look for `AMBIGUOUS` edges. |
| Two different things merged | Rename one label, or report it with both labels on [GitHub](https://github.com/Graphify-Labs/graphify/issues). |
| Calls between repositories are missing | Merge the graphs. Cross-repository member calls are completed after merging. See [Multiple repositories](https://docs.graphify.com/open-source/features/multi-repo.md). |

> **Does deduplication change code nodes?**
>
> Code symbols mostly have unique IDs from their file and name, so they rarely merge. Deduplication matters most for concepts pulled from docs and papers.

> **Can my agent rely on INFERRED edges?**
>
> Yes for navigation. For a change that must be correct, confirm the edge by opening the file and line the node points to.

## Run it on a second repository

These examples come from a code-only graph of the open-source [httpx](https://github.com/encode/httpx) repository, built with Graphify Local 0.9.97. Your counts will differ. The dedup step reports what it merged:

```text theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
[graphify] Deduplicated 32 node(s) (28 exact, 4 fuzzy).
[graphify extract] wrote .../graphify-out/graph.json: 1883 nodes, 3960 edges, 106 communities
```

`diagnose multigraph` on the same graph found no edges collapsed between the same endpoints:

```text theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
$ graphify diagnose multigraph
nodes: 1883
raw_edges: 3960
self_loop_edges: 5
exact_duplicate_edges: 0
directed_same_endpoint_collapsed_edges: 0
undirected_same_endpoint_collapsed_edges: 0
post_build_edges: 3960
note: normal graph.json is post-build; raw producer loss must be measured earlier.
```

## FAQ

**Can I see merges as JSON?** Pass `--json` to `diagnose multigraph`, and `--max-examples N` to see more examples.

**Same name in two files?** Those stay separate nodes. Commands such as `explain` report the ambiguity and list each ID, with exit code 3.

## What's next

> **[Community detection](https://docs.graphify.com/open-source/features/community-detection.md)**
>
> How resolved edges become communities.

> **[Supported inputs](https://docs.graphify.com/open-source/features/languages.md)**
>
> Languages and file types.

> **[Try it in Graphify](https://docs.graphify.com/platform/quickstart.md)**
>
> We build and host the graph for you. Start with a 14-day Pro trial, then keep up to 3 repositories on Free. No card required.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.