This page is for AFK maintainers. It explains how to change public exports without making downstream code or docs confusing. For the user-facing import table, see API Reference.Documentation Index
Fetch the complete documentation index at: https://afk.arpan.sh/llms.txt
Use this file to discover all available pages before exploring further.
Contract
The public API is the set of names exported by package-level__init__.py files:
afk.agentsafk.coreafk.toolsafk.llmsafk.memoryafk.queuesafk.mcpafk.messagingafk.observabilityafk.evals
src.afk imports or deep implementation modules such as afk.core.runner.api.
Rules for maintainers
- If a downstream user should import a symbol, export it from the package-level
__init__.py. - If a symbol is not exported, do not use it in builder docs or examples.
- Keep
AgentandRunnerseparate:Agentcomes fromafk.agents;Runnercomes fromafk.core. - Prefer protocols, dataclasses, Pydantic models, and explicit error classes for public contracts.
- When removing or renaming a public symbol, update migration docs and tests in the same change.
- When changing a public constructor, update API Reference, Configuration Reference, examples, and generated agent-facing docs.
Preferred examples
Imports to avoid in public docs
| Avoid | Prefer |
|---|---|
src.afk.agents.Agent | afk.agents.Agent |
afk.agents.core.base.Agent | afk.agents.Agent |
afk.core.runner.api.RunnerAPIMixin | afk.core.Runner |
afk.tools.core.decorator.tool | afk.tools.tool |
afk.llms.builder.LLMBuilder | afk.llms.LLMBuilder |
Change checklist
Before merging a public API change:- Update the relevant package
__all__. - Add or update tests that import through the public package.
- Update user-facing docs if a builder would see the changed behavior.
- Update maintainer docs if an invariant or subsystem boundary changed.
- Run
PYTHONPATH=src pytest -qor targeted tests for the affected subsystem. - Regenerate agent-facing docs with
./scripts/build_agentic_ai_assets.shwhen docs, examples, skill metadata, or navigation changes.