First off, thanks for considering contributing! We welcome all kinds of contributions — bug reports, feature suggestions, documentation improvements, and code changes.
- Code of Conduct
- Getting Started
- Development Setup
- Project Structure
- Making Changes
- Commit Messages
- Pull Request Guidelines
- Ideas for First Contributions
Please be respectful and constructive in all interactions. This project is a safe space for developers of all backgrounds.
- Fork the repository
- Clone your fork:
git clone https://github.com/your-username/winkterm.git - Set up the development environment (see below)
- Create a branch:
git checkout -b feature/your-feature-name
- Python 3.12+
- Node.js 20+
- Docker (optional, for containerized testing)
cd backend
python -m venv .venv
source .venv/bin/activate # On Windows: .venv\Scripts\activate
pip install -r requirements.txt
# Run development server
python -m uvicorn backend.main:app --reload --port 8000cd frontend
npm install
npm run devIf you change frontend/package.json or any frontend dependency, commit the
updated frontend/package-lock.json in the same change. Before pushing, verify
the Docker install path locally:
cd frontend
npx npm@10.8.2 ci --omit=optional --ignore-scriptsThe Docker image and test-server deploy use this install path, so lockfile drift
will break online deployment even when a local npm install appears healthy.
Copy .env.example to .env and fill in at least an API key:
cp .env.example .env# Backend
cd backend
pip install ruff
ruff check .
# Frontend
cd frontend
npm run lintwinkterm/
├── backend/
│ ├── agent/ # LangGraph agent
│ │ ├── core/ # Agent state, builder
│ │ ├── registry/ # Agent config (agents.yaml)
│ │ ├── prompts/ # System prompts
│ │ ├── tools/ # Tool implementations
│ │ └── factory.py # Agent compilation
│ ├── terminal/ # PTY management
│ │ ├── pty_manager.py # Shell process wrapper
│ │ ├── session_manager.py # Multi-session management
│ │ └── ws_handler.py # WebSocket handling
│ ├── ssh/ # SSH connections & file transfer
│ ├── api/ # FastAPI routes
│ ├── config.py # Application config
│ └── main.py # Entry point
└── frontend/
├── src/
│ ├── app/ # Next.js App Router
│ ├── components/ # UI components
│ ├── lib/ # Utilities, API client
│ └── types/ # TypeScript types
└── orval.config.ts # API code generation
- Keep changes focused — one feature or fix per PR
- Write tests for new functionality (backend tests in
backend/test/, frontend infrontend/__tests__/) - Run lint before committing
- Update docs if you change behavior or add features
- Write code comments in English — all new comments and docstrings should be in English so the whole community can read them. (Existing Chinese comments are being migrated incrementally; don't add new ones.)
- Write commit messages in English so the whole community can read the history.
- Follow Conventional Commits:
type(scope): summary.- Common types:
feat,fix,docs,refactor,test,chore. - Example:
feat(agent): add kubectl toolorfix(ws): handle reconnect on close code 1006.
- Common types:
- Keep the subject line under ~72 characters; add a body to explain why when it isn't obvious.
- Title: Clear and descriptive (e.g., "Add tmux integration", "Fix WebSocket reconnection")
- Description: Explain what and why, including screenshots if UI changes
- Linked issues: Reference any related issues with
Closes #123 - Keep it small: PRs under 300 lines are much easier to review
- No unrelated changes: Don't fix formatting you didn't break
- CI must pass (lint, build, tests)
- At least one maintainer reviews
- Merge after approval (squash commits)
Here are some areas where we'd love help:
- Tests: The backend has minimal test coverage. Adding tests is high-impact.
- Error handling: Edge cases in PTY sessions and WebSocket reconnection
- Agent tools: Add tools for kubectl, docker, systemd, git operations
- Themes: Improve terminal color scheme and add theme switching
- Docs: Improve API documentation, add more examples
- i18n: Help translate prompts and UI strings
- Monitoring: Implement real Prometheus/Loki integration (currently mocked)
Open a Discussion or ping us on the issue tracker. No question is too small!