neo4j-driver-python-skill

仓库创建 2026年1月20日最近提交 1 天前SkillHot 收录 21 天前
▸ 精选理由

对 async 与批量导入场景支持完善,适合 Python 开发者

这个 Skill 做什么

介绍 Neo4j Python 驱动 v6 的连接、事务、异步与数据映射用法

讲清怎么用 Neo4j Python 驱动 v6 建立连接、开会话、管理事务(显式或托管)以及 asyncio 异步模式,包含结果处理、类型映射、UNWIND 批量写和连接池调优。适合在 Python(需 ≥3.10)代码中与 Neo4j 交互、实现批量写入或调试驱动行为时使用。特别提醒包名是 `neo4j`(v6 起),并覆盖错误处理与一致性要点,便于工程化使用。

▸ 展开 SKILL.md 英文原文

Neo4j Python Driver v6 — driver lifecycle, execute_query, managed and explicit transactions, async (AsyncGraphDatabase), result handling, data type mapping, error handling, UNWIND batching, connection pool tuning, and causal consistency. Use when writing Python code that connects to Neo4j via GraphDatabase.driver, execute_query, execute_read, execute_write, AsyncGraphDatabase, neo4j.Result, or RoutingControl. Package name is `neo4j` (not neo4j-driver) since v6. Python >=3.10 required. Does NOT handle Cypher query authoring — use neo4j-cypher-skill. Does NOT cover driver upgrades or breaking changes — use neo4j-migration-skill. Does NOT cover GraphRAG pipelines (neo4j-graphrag package) — use neo4j-graphrag-skill.

开发编程Neo4jPython异步驱动通用
98
Stars
35
Forks
29
仓库内 Skill
+7
7 日增星
安装 / 使用
给你的 Agent 一句话(通用)
帮我安装这个 skill:https://raw.githubusercontent.com/neo4j-contrib/neo4j-skills/main/neo4j-driver-python-skill/SKILL.md
或 curl 直取 SKILL.md
curl -fsSL "https://raw.githubusercontent.com/neo4j-contrib/neo4j-skills/main/neo4j-driver-python-skill/SKILL.md"
SKILL.MD 节选查看完整文件 ↗
## When to Use
- Writing Python code that connects to Neo4j
- Setting up driver, sessions, transactions, or async patterns
- Debugging result handling, serialization, or UNWIND batching
- Reviewing Neo4j driver usage in Python code

## When NOT to Use
- **Writing/optimizing Cypher** → `neo4j-cypher-skill`
- **Driver version upgrades** → `neo4j-migration-skill`
- **GraphRAG pipelines** (`neo4j-graphrag` package) → `neo4j-graphrag-skill`

---

## Installation

```bash
pip install neo4j                  # package name is `neo4j`, NOT `neo4j-driver` (deprecated since v6)
pip install neo4j-rust-ext         # optional: 3–10× faster serialization, same API
```

**Python >=3.10 required** for v6.x. 
via SKILL·HOT · 数据来自 GitHub 公开信息 · 原文版权归作者所有