Skip to main content

Agent tools and skills to read and write wiki in Open Knowledge Format (OKF)

Project description

wiki-skills

CI PyPI version Python License

Agent tools and skills to read, write, navigate, and validate wikis in Open Knowledge Format (OKF).


Why wiki-skills?

As AI agents work with larger and more complex codebases and documentation repositories, flat Markdown files quickly become difficult to navigate, query, and maintain. Open Knowledge Format (OKF) standardizes wiki bundles with structured frontmatter (type, tags, timestamp, etc.) and reserved documents (index.md, log.md).

wiki-skills provides:

  • CLI Utilities (wiki-cli) — High-performance indexing into SQLite state, OKF conformance linting, raw concept querying, and skill installation.
  • Bundled Agent Skills (skills/) — Purpose-built workflows for AI agents (wiki-compose and wiki-find) to author, validate, and search knowledge bases efficiently.
  • SQLite State Caching — Incremental index rebuilding via content hashing for instant retrieval.

Installation

Package & CLI

# Install with uv (recommended)
uv tool install wiki-skills

# Or with pip
pip install wiki-skills

Agent Skills

To install the bundled agent skills into your agent environment (~/.agents/skills/ by default):

wiki-cli install

Or specify a custom target directory:

wiki-cli install --target ~/.config/opencode/skills/

CLI Usage

wiki-cli exposes four core subcommands:

1. wiki-cli index

Walks an OKF bundle, parses frontmatter, and writes/updates SQLite state (.wiki-skills/state.db) using incremental content hashing.

wiki-cli index                # Indexes current working directory
wiki-cli index ./my-wiki      # Indexes specific bundle path
wiki-cli index --full         # Forces complete rebuild

2. wiki-cli validate

Lints an OKF bundle for conformance issues (missing required type, invalid frontmatter, malformed tags/timestamps) with structured output.

wiki-cli validate             # Validates current directory
wiki-cli validate ./my-wiki   # Validates specific bundle path

3. wiki-cli query

Executes SQL queries against the wiki SQLite state (state.db) with fallback handling.

wiki-cli query "SELECT concept_id, type FROM concepts WHERE type = 'concept'"

4. wiki-cli install

Copies bundled agent skills (wiki-compose, wiki-find) to the agent skill directory.

wiki-cli install --target ~/.agents/skills/

Bundled Skills

The skills/ directory contains ready-to-use agent skills:

  • wiki-compose — Guidance for AI agents on writing and editing OKF wiki documents and validating conformance.
  • wiki-find — Workflows for searching, querying SQLite state, and navigating wiki structures.

Development

# Install hatch
uv tool install hatch

# Run full release check (linting, static typing with mypy, and test suite with coverage)
hatch run release

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

wiki_skills-1.0.0.tar.gz (38.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

wiki_skills-1.0.0-py3-none-any.whl (13.9 kB view details)

Uploaded Python 3

File details

Details for the file wiki_skills-1.0.0.tar.gz.

File metadata

  • Download URL: wiki_skills-1.0.0.tar.gz
  • Upload date:
  • Size: 38.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for wiki_skills-1.0.0.tar.gz
Algorithm Hash digest
SHA256 2a17965719267609ebd6dcadcfefde48a0f5b679b3e8beedb6ad15d0ec88abcd
MD5 69c5dc86125fa7e37a5fd415f6bea31d
BLAKE2b-256 60d315c486cf8a81bdc942c0eec5d56fabf85de31566d911c3eab9288386739b

See more details on using hashes here.

File details

Details for the file wiki_skills-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: wiki_skills-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 13.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for wiki_skills-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9c7083ea1446a6612b3fcb0a00cdc418a561b4b3ac5389e8cf452c64831e465b
MD5 f3706f2050efaef372d668060679866e
BLAKE2b-256 7186e5e60cfe607a290c98956a993236d5b835932122d81d690a430615a66ce2

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page