pi-openwiki
OpenWiki documentation generator for the Pi coding agent
Package details
Install pi-openwiki from npm and Pi will load the resources declared by the package manifest.
$ pi install npm:pi-openwiki- Package
pi-openwiki- Version
1.0.0- Published
- Jul 7, 2026
- Downloads
- 198/mo · 25/wk
- Author
- barha
- License
- MIT
- Types
- extension
- Size
- 24.5 KB
- Dependencies
- 0 dependencies · 2 peers
Pi manifest JSON
{
"extensions": [
"./extensions"
]
}Security note
Pi packages can execute code and influence agent behavior. Review the source before installing third-party packages.
README
pi-openwiki
AI-powered documentation that stays current with your code
Automatically generates and maintains comprehensive documentation for your codebase using Pi's AI capabilities.
Based on OpenWiki by LangChain - adapted as a Pi coding agent extension.
Quick Start
# Install from npm
pi install npm:pi-openwiki
# Generate docs
cd your-project
pi
/openwiki:init
# Update after code changes
/openwiki:update
# Ask questions
/openwiki:chat How does authentication work?
What You Get
After running /openwiki:init:
openwiki/
├── quickstart.md # Start here
├── architecture/ # System design
├── workflows/ # Development processes
├── domain/ # Business logic
├── operations/ # Deployment
└── testing/ # Test strategies
Features
- 🤖 AI-Generated - Leverages your Pi model to understand your codebase
- 🔄 Git-Aware - Updates only what changed
- 🎯 Agent-Optimized - Works for humans and AI agents
- ⚡ Smart - Prevents redundant regeneration
Commands
/openwiki:init
Generate initial documentation for your repository.
/openwiki:update
Update docs based on git changes since last run.
/openwiki:chat <question>
Ask questions about your codebase without modifying docs.
Installation Options
# Global (use everywhere)
pi install npm:pi-openwiki
# Project-specific
pi install -l npm:pi-openwiki
# From GitHub
pi install git:github.com/barvhaim/pi-openwiki
# Temporary (this session only)
pi -e git:github.com/barvhaim/pi-openwiki
# Local development
pi -e /path/to/pi-openwiki
How It Works
- Discovery - Explores your repository structure and git history
- Analysis - Understands the "why" behind your code
- Generation - Creates structured markdown documentation
- Tracking - Saves metadata for smart incremental updates
- Integration - Updates
AGENTS.md/CLAUDE.mdautomatically
Requirements
- Pi >= 0.80.0
- Git repository
- Node.js with TypeScript
Package Gallery
This package is prepared for the Pi package gallery. It is ready to publish as pi-openwiki and declares the required Pi package metadata:
{
"keywords": ["pi-package"],
"pi": {
"extensions": ["./extensions"]
}
}
After publishing to npm, the package can be installed with:
pi install npm:pi-openwiki
Development
# Clone and install dependencies
git clone https://github.com/barvhaim/pi-openwiki.git
cd pi-openwiki
npm install
# Test locally
pi -e .
# Make changes and reload
/reload
Architecture
Modular design for maintainability:
extensions/openwiki/
├── commands.ts # Command handlers
├── tools.ts # AI tools
├── events.ts # Event handlers
├── git-utils.ts # Git operations
├── metadata.ts # Metadata management
├── prompts.ts # System prompts
└── constants.ts # Constants & types
See extensions/openwiki/README.md for details.
Troubleshooting
"Not in a git repository!"
Initialize git: git init && git add . && git commit -m "init"
Commands not showing up?
Reload Pi: /reload
"No changes detected"
Normal - means your code hasn't changed since last update.
License
MIT
Credits
This Pi extension is based on OpenWiki by LangChain AI, adapted for the Pi coding agent ecosystem.
Contributing
Issues and PRs welcome at github.com/barvhaim/pi-openwiki