Thanks for your interest in contributing! This document explains how to get involved.
# Clone and install
git clone https://github.com/zimoliao/scholaraio.git
cd scholaraio
pip install -e ".[dev]"
# Install pre-commit hooks
pre-commit install
# Run tests
pytestSkills in .claude/skills/ are pure-prompt definitions that combine existing CLI commands. To add one:
- Create
.claude/skills/<name>/SKILL.mdwith YAML frontmatter + instructions - Follow the AgentSkills.io format
- Test with Claude Code:
/<name>
See existing skills (e.g., literature-review, writing-polish) for examples.
For new functionality that requires code:
- Implement in
scholaraio/(library module) - Expose via
cli.py(CLI subcommand) - Add contract-level tests in
tests/ - Optionally create a skill in
.claude/skills/
- Fork the repo and create a branch from
main - Make your changes
- Ensure all checks pass:
ruff check scholaraio/ # lint ruff format --check scholaraio/ # format mypy scholaraio/ # type check pytest # tests
- Submit a PR with a clear description
We use Conventional Commits:
feat:— new featurefix:— bug fixdocs:— documentation onlyrefactor:— code change that neither fixes a bug nor adds a featuretest:— adding or updating testschore:— maintenance (CI, deps, config)
- Test behavior contracts, not implementation details
- A refactor should not break tests — if it does, the test was too coupled
- Use
tmp_path/tmp_papersfixtures for isolation - Mark slow tests (network, GPU) with
@pytest.mark.slow
- Linter/formatter: ruff (configured in
pyproject.toml) - Type hints: encouraged, checked by mypy with
ignore_missing_imports - Docstrings: Google-style for public API functions in library modules
- CLI handlers (
cmd_*incli.py): no docstrings needed - UI text (CLI output, help, errors): Chinese
- Code comments: English, only when logic isn't self-evident
| Directory | Purpose |
|---|---|
scholaraio/ |
Python package (library + CLI) |
.claude/skills/ |
Agent skill definitions (SKILL.md) |
tests/ |
Contract-level test suite |
data/ |
User paper library (not tracked) |
workspace/ |
User workspace outputs (not tracked) |
docs/ |
Documentation |
- Bugs: use the bug report template
- Features: use the feature request template
- Security: see SECURITY.md — do not open a public issue
Open a discussion or file an issue.