stair-lab/kg-gen
A Python package that extracts knowledge graphs from plain text using language models via LiteLLM and DSPy.

Velocity · 7d
+2.0
★ / day
Trend
→steady
star history
kg-gen converts unstructured text into structured knowledge graphs using LLMs. It supports multiple model providers (OpenAI, Anthropic, Gemini, Ollama, Deepseek) through LiteLLM and uses DSPy for structured output generation. The tool is designed for RAG assistance, synthetic data creation for ML training, and relationship analysis in source text. It ships with an MCP server for integration into AI tooling ecosystems.