Metadata-Version: 2.3
Name: code-payload
Version: 0.1.5.dev3
Summary: Giving language models context of your codebase
Project-URL: Homepage, https://github.com/darth-veitcher/code-payload
Project-URL: Source, https://github.com/darth-veitcher/code-payload
Project-URL: Issues, https://github.com/darth-veitcher/code-payload/issues
Project-URL: Documentation, https://github.com/darth-veitcher/code-payload
Author-email: darth-veitcher <1722315+darth-veitcher@users.noreply.github.com>
License: MIT License
        
        Copyright (c) 2024 James Veitch
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
License-File: LICENSE
Requires-Python: >=3.8
Requires-Dist: chardet>=5.2.0
Requires-Dist: hatch-fancy-pypi-readme>=24.1.0
Requires-Dist: jinja2>=3.1.4
Requires-Dist: omegaconf>=2.3.0
Requires-Dist: pydantic>=2.8.2
Requires-Dist: rich>=13.8.0
Requires-Dist: tiktoken>=0.7.0
Requires-Dist: typer>=0.12.5
Provides-Extra: docs
Requires-Dist: mkdocs-gen-files>=0.5.0; extra == 'docs'
Requires-Dist: mkdocs-literate-nav>=0.6.1; extra == 'docs'
Requires-Dist: mkdocs-material>=9.5.34; extra == 'docs'
Requires-Dist: mkdocs-section-index>=0.3.9; extra == 'docs'
Requires-Dist: mkdocs>=1.6.1; extra == 'docs'
Requires-Dist: mkdocstrings[python]>=0.26.0; extra == 'docs'
Description-Content-Type: text/markdown


# code-payload

Condense and summarize a codebase for passing to an LLM as context.

## Features

- **Token-based Summarization**: Summarizes content based on token counts, making it suitable for language models.
- **Flexible Configuration**: Supports configuration through YAML files, environment variables, and CLI arguments.
- **Rich CLI Interface**: Use the CLI to interact with your projects, including rendering Jinja2 templates.
- **Customizable Templates**: Generate custom summaries or reports using Jinja2 templates.

## Installation

We recommend using `pipx` to make this globally available. Alternatively you can use `pip`.

```zsh
pipx install code-payload
```

## Usage

```zsh
code-payload --help
```

### Example Usage

To process a project directory and output a JSON summary:

```bash
code-payload /path/to/your/project
```

To override the file extensions to include:

```bash
code-payload /path/to/your/project --include-extensions .py,.js,.md
```

To use a custom template:

```bash
code-payload /path/to/your/project --render-args template_input=readme_summary.j2
```
