# Kida API Reference

URL: /kida/api/
Section: api
Description: Browse Python API documentation by package.

---

> For a complete page index, fetch /kida/llms.txt.

Open LLM text
(/kida/api/index.txt)

Share with AI

Ask Claude
(https://claude.ai/new?q=Please%20help%20me%20understand%20this%20documentation%3A%20%2Fkida%2Fapi%2Findex.txt)

Ask ChatGPT
(https://chatgpt.com/?q=Please%20help%20me%20understand%20this%20documentation%3A%20%2Fkida%2Fapi%2Findex.txt)

Ask Gemini
(https://gemini.google.com/app?q=Please%20help%20me%20understand%20this%20documentation%3A%20%2Fkida%2Fapi%2Findex.txt)

Ask Copilot
(https://copilot.microsoft.com/?q=Please%20help%20me%20understand%20this%20documentation%3A%20%2Fkida%2Fapi%2Findex.txt)

# Kida API Reference

Browse Python API documentation by package.

10
Packages

20
Modules

## Packages

Analysis

Kida Template Introspection API.

Static analysis of compiled templates for caching optimization,
validation, and...

18 items

(/kida/api/analysis/)

Compiler

Kida Compiler — transforms Kida AST into executable Python code.

The compiler takes an immutable Kida AST (Template...

10 items

(/kida/api/compiler/)

Contrib

Framework integrations for Kida template engine.

4 items

(/kida/api/contrib/)

Environment

Kida Environment — central configuration and template management.

The Environment is the central hub for all...

11 items

(/kida/api/environment/)

Nodes

Kida AST node definitions.

8 items

(/kida/api/nodes/)

Parser

Kida Parser — transforms token stream into immutable AST.

Recursive descent parser that consumes tokens from the...

8 items

(/kida/api/parser/)

Readme

Kida README generator — auto-detect project metadata, render styled READMEs.

2 items

(/kida/api/readme/)

Template

Kida Template package — compiled template objects ready for rendering.

10 items

(/kida/api/template/)

Terminal

Kida terminal components.

2 items

(/kida/api/terminal/)

Utils

Kida utilities.

17 items

(/kida/api/utils/)

## Modules

__main__

``python -m kida`` → CLI.

(/kida/api/__main__/)

_types

Core types for Kida template engine.

(/kida/api/_types/)

babel

Babel extraction plugin for Kida templates.

Usage in ``babel.cfg``::

[kida: templates/**.html]
encoding =...

(/kida/api/babel/)

bytecode_cache

Template Bytecode Cache.

Persists compiled template code objects to disk for near-instant
cold-start loading.

(/kida/api/bytecode_cache/)

cli

Command-line interface for Kida (``kida check``, future subcommands).

(/kida/api/cli/)

composition

Public composition API for template structure and block validation.

Provides validation helpers for frameworks like...

(/kida/api/composition/)

coverage

Template coverage collection and reporting for Kida.

(/kida/api/coverage/)

exceptions

Exceptions for Kida template system.

(/kida/api/exceptions/)

extensions

Extension/plugin architecture for Kida template engine.

(/kida/api/extensions/)

formatter

Opinionated template formatter for Kida.

Auto-formats Kida templates with consistent whitespace, indentation,
and...

(/kida/api/formatter/)

kida

Kida — Next-generation template engine for free-threaded Python (3.14t+).

A pure-Python template engine optimized...

(/kida/api/kida/)

lexer

Kida lexer — tokenizes template source code into a token stream.

The lexer scans template source and produces Token...

(/kida/api/lexer/)

markdown

Kida markdown components.

(/kida/api/markdown/)

render_accumulator

Kida RenderAccumulator — opt-in profiling for template rendering.

(/kida/api/render_accumulator/)

render_capture

Kida RenderCapture — opt-in content capture during template rendering.

This module provides render-time data...

(/kida/api/render_capture/)

render_context

Kida RenderContext — per-render state isolated from user context.

(/kida/api/render_context/)

render_manifest

Kida RenderManifest — batch capture accumulation, search indexing, and diffing.

(/kida/api/render_manifest/)

sandbox

Sandboxed template execution — defense-in-depth for risky templates.

``SandboxedEnvironment`` restricts attribute...

(/kida/api/sandbox/)

tstring

Kida Template String support (PEP 750).

(/kida/api/tstring/)
