Find similar nodes
Nodes whose position in the network is most like this one. Cosine similarity of 64-dimension embeddings learned from the whole graph (shared neighbors and neighbors of neighbors), served from Vectorize. Filter by kind for "members most like this member".
GET https://www.chicagopolitics.org/api/v1/graph/nodes/{id}/similar
Authorizations
| Header | Value |
|---|---|
Authorization | Bearer <key>. Get a key; see authentication. |
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
id | string | yes | Node id |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
kind | string | One of: member, committee, matter, donor, employer, lobbyist, client. | |
limit | integer | Default 10. |
Response
200 Similar nodes
Example request
curl "https://www.chicagopolitics.org/api/v1/graph/nodes/{id}/similar" \
-H "Authorization: Bearer $CHICAGO_POLITICS_KEY"
Errors: 400, 401, 404, 429 (see errors).