Skip to main content

How-Agentic

How-Agentic is a tutorial-first framework for training a small agent model from scratch.

The current release is the M0 closed-loop baseline. It is intentionally small and practical: the goal is to make the full path reproducible before moving on to more agentic behavior training.

tokenizer -> pretrain -> format-only SFT -> export -> infer -> HuggingFace-compatible export

M0 Status

M0 is complete and frozen.

  • Pretrained checkpoint: out/hello_agent_100m/pretrain/final.pt
  • SFT checkpoint: out/hello_agent_100m/sft/final.pt
  • Tokenizer: tokenizers/hello-agent-16k
  • Pretrain data: data/demo/m0_pretrain_100k.jsonl
  • SFT data: data/demo/m0_sft_format_500.jsonl
  • Pretrain infer mode: completion
  • SFT infer mode: chat

Model checkpoints and datasets are not included in the PyPI package.

Install

Minimal CLI install:

pip install how-agentic

M0 training environment, verified on Python 3.12 + CUDA 12.4:

pip install -r requirements/m0-py312-cu124.txt
pip install -e . --no-deps

Or with uv:

uv venv .venv --python 3.12
uv pip install -r requirements/m0-py312-cu124.txt
uv pip install -e . --no-deps

CLI

python -m how_agentic.cli --help

or:

how-agentic --help

M0 Quick Path

Train tokenizer:

python -m how_agentic.cli train-tokenizer --data data/demo/m0_pretrain_100k.jsonl --output tokenizers/hello-agent-16k --vocab-size 16000

Pretrain:

python -m how_agentic.cli train --config configs/hello_agent_pretrain_100k.yaml

Export pretrained model:

python -m how_agentic.cli export --checkpoint out/hello_agent_100m/pretrain/final.pt --output models/hello_agent_100m_native

Infer with pretrained model:

python -m how_agentic.cli infer --model models/hello_agent_100m_native --prompt "Once upon a time" --mode completion --max-tokens 50 --temperature 0

Build M0 format-only SFT data:

python scripts/build_m0_format_sft_dataset.py --output data/demo/m0_sft_format_500.jsonl --total 500 --seed 42

Run M0 SFT:

python -m how_agentic.cli train --config configs/hello_agent_sft.yaml

Export SFT model:

python -m how_agentic.cli export --checkpoint out/hello_agent_100m/sft/final.pt --output models/hello_agent_100m_sft_native

Infer with SFT model:

python -m how_agentic.cli infer --model models/hello_agent_100m_sft_native --prompt "What is the capital of France?" --mode chat --max-tokens 80 --temperature 0

Expected shape:

<answer>
The capital of France is Paris.
</answer>

Docs

Quickstart:

docs/quickstart.md

M0 reproduction:

docs/m0-reproduction.md

CLI reference:

docs/cli-reference.md

Configuration guide:

docs/configuration.md

Roadmap:

docs/roadmap.md

Publishing:

docs/publishing.md

Package Boundary

PyPI contains the framework code and CLI.

The following are intentionally kept outside the wheel:

  • checkpoints
  • exported models
  • tokenizer artifacts
  • training data
  • logs
  • local caches

Use HuggingFace Hub for model weights and GitHub for reproducibility docs, configs, scripts, and tests.

License

This project is licensed under CC BY-NC-SA 4.0.

Attribution is required, commercial use is not allowed, and derivative works must use the same license.

Metadata

Release files for how-agentic 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for how-agentic 0.1.1
File Size Uploaded
how_agentic-0.1.1.tar.gz 84.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for how-agentic 0.1.1
File Interpreter ABI Platform
how_agentic-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 164.5 kB

Release files / how_agentic-0.1.1.tar.gz

Download URL how_agentic-0.1.1.tar.gz
Size 84.5 kB
Tags Source
SHA-256 checksum
How to use checksums
e30475038bf7869f6c9c8351de149e4b24b0d2591600dba1633547becc502ef6
BLAKE2b-256 checksum
How to use checksums
dd7b72129b8edf7939fbd8160d8b989c576765203899d0ecd9402011e6276e15
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.11

Release files / how_agentic-0.1.1-py3-none-any.whl

Download URL how_agentic-0.1.1-py3-none-any.whl
Size 80.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
60e62ff0af44bd30bdd1a3da977efcfd222fc2edec8f2386774d8e8db01bd25d
BLAKE2b-256 checksum
How to use checksums
8bdd25882f770d117eaf20cb5bb3edf9ae3f5f673b97d6566e169910b095268a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.11

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page