Metadata-Version: 2.4
Name: talocode-wiki
Version: 0.1.0
Summary: Agent knowledge base — ingest, query, and manage a structured wiki of plain Markdown files
Author: Talocode
License: MIT
Project-URL: Homepage, https://github.com/talocode/wiki
Project-URL: Repository, https://github.com/talocode/wiki
Project-URL: Documentation, https://github.com/talocode/wiki#readme
Project-URL: Issues, https://github.com/talocode/wiki/issues
Keywords: wiki,knowledge-base,obsidian,markdown,agents,mcp,talocode
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Requires-Python: >=3.8
Description-Content-Type: text/markdown

# Talocode Wiki

**Agent knowledge base — ingest, query, and manage a structured wiki of plain Markdown files.**

Talocode Wiki turns any agent into a knowledge-powered assistant. It creates, maintains, and queries a structured knowledge base that persists across sessions.

## Install

```bash
pip install talocode-wiki
```

## Quickstart

```python
from talocode_wiki import WikiClient

# Initialize wiki
wiki = WikiClient(wiki_dir="./wiki")
wiki.init()

# Ingest content
wiki.ingest("notes.md", "Content to remember...")

# Query
result = wiki.query("What do we know about AI?")
print(result["answer"])

# Check health
health = wiki.lint()
print(f"Pages: {health['stats']['pages']}")
```

## CLI Usage

```bash
# Initialize wiki
wiki init

# Ingest a file
wiki ingest research-paper.pdf

# Query the knowledge base
wiki query "what do you know about AI agents?"

# Check wiki health
wiki lint

# Save conversation
wiki save "Key insights" -c "Important findings"
```

## API

### WikiClient

```python
from talocode_wiki import WikiClient

wiki = WikiClient(wiki_dir="./wiki")

# Initialize
wiki.init()

# Ingest content
result = wiki.ingest("source.md", "Content to ingest")
# Returns: {"source": "source", "pagesCreated": 5, "linksCreated": 3, "pages": [...]}

# Query
result = wiki.query("What is X?")
# Returns: {"answer": "Found 3 relevant sources...", "sources": [...]}

# Lint
result = wiki.lint()
# Returns: {"orphans": [...], "deadLinks": [...], "stats": {...}}

# Save
path = wiki.save("Title", "Content")
# Returns: "conversation-2026-07-21"
```

## Talocode Ecosystem

| Package | PyPI | npm |
|---------|------|-----|
| DocuLane | `talocode-doculane` | `@talocode/doculane` |
| XSearchLane | `talocode-xsearchlane` | `@talocode/xsearchlane` |
| Wiki | `talocode-wiki` | `@talocode/wiki` |

## License

MIT © Talocode
