This repository contains code for building a knowledge graph from the Meta Kaggle dataset and loading it into IssunDB, which provides CLI and MCP interfaces for querying the data.
The pipeline needs the Meta Kaggle tabular dataset, and it can (optionally) include the Meta Kaggle Code dataset.
curl -L -o /path/to/meta-kaggle.zip \
https://www.kaggle.com/api/v1/datasets/download/kaggle/meta-kaggleunzip /path/to/meta-kaggle.zip -d /path/to/meta-kagglecurl -L -o /path/to/meta-kaggle-code.zip \
https://www.kaggle.com/api/v1/datasets/download/kaggle/meta-kaggle-code
unzip /path/to/meta-kaggle-code.zip -d /path/to/meta-kaggle-codeexport META_KAGGLE_DIR="/path/to/meta-kaggle"
# This is optional. Set only if Meta Kaggle Code was downloaded
export META_KAGGLE_CODE_DIR="/path/to/meta-kaggle-code"Note
Remember to replace the correct paths in the commands above.
Build the Kaggle knowledge graph and launch the CLI or MCP server:
make graph-kcbuilds the knowledge graph from the Meta Kaggle dataset (parses imports and API calls ifMETA_KAGGLE_CODE_DIRis set).make comp-cliopens the competition knowledge graph in the IssunDB CLI.make comp-mcpruns the IssunDB MCP server for the competition knowledge graph.make graph-kernelbuilds the knowledge graph from the Meta Kaggle dataset (parses imports and API calls ifMETA_KAGGLE_CODE_DIRis set).make kernel-cliopens the kernel knowledge graph in the IssunDB CLI.make kernel-mcpruns the IssunDB MCP server for the kernel knowledge graph.make helpshows all available Makefile targets.
The published dataset is available on Hugging Face at habedi/kaggle-knowledge-graph.
make hf-package HF_SNAPSHOT=YYYY-MM-DDpackages the competition graph as a Hugging Face dataset indatabases/hf-dataset, with the Parquet files underdata/, a dataset card, and other metadata.make hf-upload HF_REPO_ID=<user>/<dataset> HF_VERSION=<version>uploads that directory to the Hugging Face Hub and tags it with the release version (log in first withhf auth login).
To connect AI agents to the IssunDB MCP server, use the configuration template at examples/mcp_config.json:
{
"mcpServers": {
"kaggle-comp-kg": {
"command": "/path/to/kaggle-knowledge-graph/bin/issundb-mcp",
"args": [
"--db-path",
"/path/to/kaggle-knowledge-graph/databases/comp-kg",
"--map-size-gb",
"8"
]
}
}
}See CONTRIBUTING.md for details on how to make a contribution.
This project is licensed under the MIT License except for the knowledge graph data (built by the code in this repository), which is subject to the CC BY-NC-SA 4.0 license.