Skip to main content

Local, deterministic repository context engine — turns a codebase + task into a token-budgeted markdown context package.

Project description

Rylox

Rylox is a fast, local repository context engine for Python codebases.

It analyzes your repository, builds a structured semantic index, and retrieves relationship-aware, token-budgeted context that can be used with any large language model.

Unlike keyword search or sending entire repositories to an LLM, Rylox understands the structure of your codebase and selects only the code that is relevant to the task. Indexing and retrieval run completely offline—no API keys, cloud services, or vendor-specific integrations required.

rylox index
rylox context "How does authentication work?" --max-tokens 20000

The generated output is a structured Markdown document that can be pasted directly into ChatGPT, Claude, Gemini, Codex, or any other LLM while remaining within the requested token budget.


Why Rylox?

Large repositories quickly exceed an LLM's context window. Traditional keyword search often retrieves unrelated files, while embedding-based approaches require external services or non-deterministic ranking.

Rylox takes a different approach by analyzing the repository's structure, extracting semantic code units, and building deterministic context from actual relationships inside the codebase.


Features

  • Incremental indexing using SHA-256 content hashing
  • Tree-sitter powered Python parsing
  • Semantic chunking at the function, method, and class level
  • Relationship-aware context retrieval
  • Token-budgeted context generation
  • Rich metadata extraction
    • file paths
    • line ranges
    • parent classes
    • signatures
    • docstrings
  • Persistent on-disk index cache
  • .gitignore and configurable ignore pattern support
  • Offline-first architecture
  • Cross-platform support
  • Comprehensive unit tests

Example

Index a repository:

rylox index

Generate context for an LLM:

rylox context \
  "How does authentication work?" \
  --max-tokens 20000

Rylox returns a structured Markdown document containing only the most relevant parts of the repository while respecting the requested token budget.


Philosophy

Rylox is built around three core principles.

Offline First

Repository indexing and retrieval never require an internet connection.

Vendor Independent

The generated context is provider-agnostic and works with any language model.

Deterministic Retrieval

Context generation is reproducible and driven by repository structure rather than opaque ranking heuristics.


Installation

Install from source:

pip install -e ".[dev]"

Supported Language

Current release:

  • Python

Future releases are designed to support additional programming languages through Tree-sitter grammars.


License

Rylox is licensed under the Apache License 2.0. See the LICENSE file for details.

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

rylox-0.0.1.tar.gz (27.6 kB view details)

Uploaded Source

Built Distribution

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

rylox-0.0.1-py3-none-any.whl (20.5 kB view details)

Uploaded Python 3

File details

Details for the file rylox-0.0.1.tar.gz.

File metadata

  • Download URL: rylox-0.0.1.tar.gz
  • Upload date:
  • Size: 27.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.3

File hashes

Hashes for rylox-0.0.1.tar.gz
Algorithm Hash digest
SHA256 059b37a2ab3736f9b9cb3be474fab5c8b038c24552b0ccea8efe7a2f4b6803a9
MD5 c2f994779c4cd063976fa6038c75cc40
BLAKE2b-256 790ce79e63b6d30156e80a6df517f49fffd021c61f382687dc0f57059f97c557

See more details on using hashes here.

File details

Details for the file rylox-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: rylox-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 20.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.3

File hashes

Hashes for rylox-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 1d5e214330aae24ec9290885d6e0f422cfe43a050674e411457d6e3ecd4a1c57
MD5 d318fbcaf65070ce3dfc93ed1ae57c3a
BLAKE2b-256 e03d6228cca4c9eb6b7d64b612adc659d64ab7284b4a2d4a6755637159cabffb

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