Markdown Converter
Agent skill for markdown-converter
Learnings and patterns for future agents working on this project.
Sign in to like and favorite skills
Learnings and patterns for future agents working on this project.
PRIMARY LANGUAGES: Python
USAGE CONTEXT: Python is the sole programming language used for this project. It's a Python package (neo4j-graphrag) designed to facilitate Neo4j's GraphRAG (Graph Retrieval-Augmented Generation) features. The codebase contains:
src/neo4j_graphrag/ with modules for embeddings, retrievers (vector, hybrid, text2cypher), LLM integrations (OpenAI, Anthropic, Cohere, Mistral, Ollama, VertexAI), generation, and utilitiestests/ directorydocs/ with theme customization)Project uses uv for dependency management (pyproject.toml), pytest for testing, mypy for type checking, and ruff for linting. No other programming languages are present in the active codebase.
BUILD SYSTEMS: Poetry, Hatchling, Sphinx, Make BUILD COMMANDS: uv run pytest tests/unit/, uv run ruff format --check ., uv run ruff check . --fix, uv run mypy ., make html (in docs/) BUNDLING: Hatchling (wheel builder)
TESTING FRAMEWORKS: pytest, coverage
TEST COMMANDS:
poetry run pytest tests/unit/ (per project instructions) or uv run pytest tests/unituv run pytest tests/e2euv run coverage run -m pytest tests/unit && uv run coverage report --fail-under=90TEST ORGANIZATION:
tests/unit/ and tests/e2e/ directoriesunittest.mock (MagicMock, patch)E2E TESTING:
tests/e2e/ directory with separate pytest.ini markersARCHITECTURE PATTERN: Modular Multi-Provider RAG Framework with Neo4j-Native Knowledge Graph Integration
DIRECTORY STRUCTURE: Layered package organization with provider abstraction -
src/neo4j_graphrag/ contains core layers (embeddings/, generation/, llm/, retrievers/, experimental/), each implementing specific responsibilities. External dependencies (Weaviate, Pinecone, Qdrant) isolated in retrievers/external/. Experimental features segregated in experimental/ with pipeline and component subsystems.
DESIGN PATTERNS: Template Method (Retriever base with abstract get_search_results), Strategy Pattern (multiple retriever/LLM implementations), Provider Pattern (pluggable LLM/embedding/vector DB adapters), Adapter/Bridge Pattern (external DB wrappers), Component/DAG Pattern (experimental pipeline with configurable components), Factory-like Configuration (AbstractPipelineConfig instantiation from dicts), Observer Pattern (EventNotifier callbacks).
DATABASE: Neo4j-native architecture with three query categories - vector search via
db.index.vector.queryNodes(), fulltext via db.index.fulltext.queryNodes(), and schema introspection via APOC (apoc.meta.data(), apoc.schema.nodes()). Message history persisted as linked Message nodes. Cypher builders in neo4j_queries.py support batch operations and variable scope clauses (Neo4j 5.x+).
API DESIGN: RAG pipeline follows init→compose→search flow with polymorphic
search(query_text, top_k, filters, retriever_config) returning RetrieverResult objects. Dual LLM interface (LLMInterface legacy, LLMInterfaceV2 current) with standardized invoke(input, message_history, system_instruction). Configuration via YAML/dict at three levels: pipeline-wide, environment-based (API keys), and runtime parameters (retriever_config dict).
DEPLOYMENT STRATEGY: PyPI package distribution with GitHub Actions CI/CD pipeline
CONTAINERIZATION: Not containerized. Project designed as a Python library, not a containerized application. E2E tests use Docker Compose for service dependencies (Neo4j, Weaviate, Qdrant) but the package itself is distributed as a pure Python wheel.
CI/CD: GitHub Actions with multi-stage pipeline:
HOSTING: PyPI (Python Package Index) - distributed as
package. End-users install via neo4j-graphrag
. No server-side hosting required. Examples provided for integration into user applications.pip install neo4j-graphrag[optional-extras]
ENVIRONMENT MANAGEMENT:
Key characteristics:
This AGENTS.md was generated using agent-based project discovery.