Skip to content

tfmvn/Ryft

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Ryft

A calm, fast terminal companion for git — AI commit messages, live sync, formatting, and health checks, wrapped in a premium terminal UI.

pip install ryft
ryft

That's it. If this is the first time Ryft has been run in this folder, it will walk you through a 10-second setup and drop you straight into a ready-to-use session.

What it does

  • AI commit messages — a small local model (via Ollama) writes conventional commit messages from your diff. Tiny changes skip the AI entirely; identical diffs are cached.
  • Live syncryft watch watches your project and automatically formats, messages, commits, and (optionally) pushes on save.
  • Formatting — strips comments and collapses blank lines for Python and Lua, safely (it verifies the result still parses before writing).
  • AI review & analysis/review and /analyze for a second pair of eyes on your changes, using a larger local model.
  • ryft doctor — a full health check (Python, git, remotes, branch, Ollama, models, config, permissions, repo state) with plain-English explanations and one-command auto-fixes (ryft doctor fix).

Usage

Ryft works two ways:

ryft              # interactive session — type /help for commands
ryft doctor       # run one command and exit, e.g. from a script or CI
ryft commit
ryft watch
ryft --help       # usage summary
ryft --version    # installed version

Running a single command (anything after ryft) never blocks on a prompt — if there's no .src.py yet it proceeds on sane defaults instead of asking, so it's safe to call from scripts and CI. Run ryft init first if you want the interactive setup walkthrough.

Inside the interactive session, everything is a slash command:

/status             project status at a glance
/init                set up Ryft in this project (safe to re-run)
/commit              commit all changed files, AI messages generated in parallel
/push  /pull         publish or fetch
/diff  /diff <file>  GitHub-style diff, scrollable
/review <file>       AI code review
/analyze             AI summary of everything that changed
/sync start|stop     background watch mode
/doctor  /doctor fix  health check + auto-repair
/config init          write a .src.py with the defaults
/help                 full command list

Configuration

Ryft is configured with a .src.py file at your project root — plain Python, not YAML/TOML, so it's just as easy to script as it is to read:

class Project:
    name = "my-app"

class Ollama:
    commit_model = "qwen3:0.6b"
    analysis_model = "qwen2.5-coder:7b-instruct-q4_K_M"

class Git:
    branch = "main"
    remote = "origin"

If no .src.py exists, Ryft offers to create one the first time you run it — you're never left guessing what to do next.

Development

pip install -e ".[dev]"
pytest

The codebase is a small set of focused modules:

module responsibility
config.py .src.py discovery, loading, validation
git.py every git invocation goes through here
ai.py Ollama client, diff summarizer, commit messages
formatter.py comment stripping / blank-line collapsing
doctor.py health checks
recovery.py shared auto-repair helpers (used by doctor + commands)
onboarding.py first-run setup flow
sync.py file-watch → format → commit → push pipeline
commands.py the command registry / dispatcher
ui.py the terminal UI (Rich + Prompt Toolkit)

License

MIT

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages