Context Engine CLI - Compress the Chaos
Project description
Context Engine
Context Engine is a hybrid CLI that tracks local development sessions, generates summaries, and bundles context for AI handoffs. The CLI is split into a Python backend (Click + watchdog tracker) and a Node/Ink frontend (interactive chat + command palette).
Key Features
- Background session tracker that logs filesystem events and CLI commands to .context/session.md.
- context session save generates Markdown summaries (AI-assisted when an OpenRouter key is available, static otherwise).
- Ink chat interface mirrors all CLI commands (/start-session, /session status, /bundle, etc.).
- Ready-to-publish npm package (context-engine-dev) and Python package (context-engine).
Quick Start
`ash
Initialise scaffolding
context-engine init
Start tracker in background
context-engine start-session --auto
Inspect tracker status
context-engine session status
Capture a summary snapshot
context-engine session save "Wrapped up dashboard wiring"
Stop tracking
context-engine stop-session
Launch chat palette
context-engine chat `
Files created in .context/:
| File | Purpose |
|---|---|
| session.md | Log of file events and CLI commands. |
| session_summary.md | AI/static summary written by session save. |
| session.pid | PID of watchdog process. |
| session_state.json | Cache used by context session status. |
Project Structure
Context-Engine/ ├── backend/ # Python package │ ├── main.py # CLI bridge invoked by Node │ └── context_engine/ │ ├── cli.py # Click command definitions │ ├── core/session_tracker.py │ ├── core/ai_summary.py │ └── commands/ # Command modules (baseline, bundle, session, etc.) ├── ui/ # Node + Ink frontend │ ├── index.js # CLI entry and palette bootstrapper │ ├── components/ChatApp.tsx │ └── lib/backend-bridge.js └── docs/ # Authoring guides for contributors
Development Workflow
`ash
Install deps and run lint/tests (Node)
cd ui npm install npm test npm run lint
Run Python tests
cd .. python -m pytest -q `
Publishing
- Bump versions:
ash cd ui npm version <new-version> --no-git-tag-version cd .. python scripts/sync_versions.py <new-version> - Commit, tag, and push:
ash git add . git commit -m "chore: release <new-version>" git tag v<new-version> git push origin main git push origin v<new-version> - Publish packages:
ash cd ui npm publish --access public cd .. python -m build twine upload dist/*
Documentation
See docs/README.md for writing principles and deep-dive guides.
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file context_engine_dev-1.2.0.tar.gz.
File metadata
- Download URL: context_engine_dev-1.2.0.tar.gz
- Upload date:
- Size: 122.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4508310583475d3ef9442ec66620b12f653670e95d5207f553b70dc0c628bf9b
|
|
| MD5 |
a688315c9c399ef7537dc82be4c3146c
|
|
| BLAKE2b-256 |
a975a63ca91ffdbfa472d8e52dc920251f131abd0fad79ee69eba0f2101ab2eb
|
File details
Details for the file context_engine_dev-1.2.0-py3-none-any.whl.
File metadata
- Download URL: context_engine_dev-1.2.0-py3-none-any.whl
- Upload date:
- Size: 130.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c59ebb5bb6770e3dc7cb5e028588f3415ab4f578b9754c8d8df5d73151827e83
|
|
| MD5 |
592bbd0a9b3204a2d929164f5af16213
|
|
| BLAKE2b-256 |
16b3d8a679a1861910b994187b4a204bdf0c42ae5d2be511116d7be93d2adb22
|