Skip to content

docs: add contributing guide and clean up docs#40

Merged
rayokamoto merged 1 commit intomainfrom
docs/cleanup-and-contrib
Feb 13, 2026
Merged

docs: add contributing guide and clean up docs#40
rayokamoto merged 1 commit intomainfrom
docs/cleanup-and-contrib

Conversation

@rayokamoto
Copy link
Contributor

@rayokamoto rayokamoto commented Feb 13, 2026

Summary by CodeRabbit

  • Documentation

    • Added a comprehensive CONTRIBUTING guide and reorganized development docs into a centralized Development Standards.
    • Added a checklist item to run lint/type checks (ruff/ty) before finishing changes.
    • Clarified miner testing guidance (MetaWorld is local-only) and updated validator workflow to include weight submission.
  • Chores

    • Consistency and formatting cleanups across guides and environment docs.
    • Recommended Python base updated to 3.12; miner image now runs as a non-root user.

@coderabbitai
Copy link

coderabbitai bot commented Feb 13, 2026

📝 Walkthrough

Walkthrough

Consolidated and reformatted documentation across multiple guides, added a new CONTRIBUTING.md with development and contribution workflows, standardized terminology (e.g., "backend" → "executor", "Affinetes" capitalization), and applied minor doc updates in code comments and a miner Dockerfile; no functional code changes.

Changes

Cohort / File(s) Summary
Documentation Restructuring
AGENTS.md, CONTRIBUTING.md, README.md
Replaced granular AGENTS.md sections with a centralized CONTRIBUTING.md; updated README links and development guidance to reference CONTRIBUTING.md.
Backend & E2E Guide Updates
docs/backend-guide.md, docs/e2e-testing.md
Reformatted multiple tables, introduced collapsible sections, standardized wording and headers, and renamed environment variables (e.g., KINITRO_BACKEND_EVAL_MEM_LIMITKINITRO_EXECUTOR_EVAL_MEM_LIMIT).
Miner & Validator Guides
docs/miner-guide.md, docs/validator-guide.md
Simplified miner testing instructions; added validator step “Submits weights to chain”; updated Docker base image recommendation from Python 3.11 to 3.12 in docs.
Environments Documentation
environments/README.md
Reformatted environment variables table, changed references from "backend" to "executor", and consolidated image examples into an executor image map.
Code Documentation Updates
kinitro/backend/storage.py, kinitro/environments/registry.py, kinitro/miner/template/Dockerfile
Updated docstrings and comments to replace robo with kinitro; adjusted Dockerfile header and introduced non-root miner user (permissions and USER miner)—no API/logic changes.
Configuration
docker-compose.yml
Corrected comment capitalization from "affinetes" to "Affinetes" in executor service volumes; no config semantics changed.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~15 minutes

Poem

🐰 A rabbit hops through docs with glee:
Consolidated notes for all to see,
CONTRIBUTING plants the seed,
Executor names take heed,
Kinitro hops forward—clean and tidy!

🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the two main changes: adding a new CONTRIBUTING.md guide and cleaning up/reorganizing existing documentation across multiple files.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.
Merge Conflict Detection ✅ Passed ✅ No merge conflicts detected when merging into main

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch docs/cleanup-and-contrib

No actionable comments were generated in the recent review. 🎉


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
kinitro/miner/template/Dockerfile (1)

5-7: ⚠️ Potential issue | 🟡 Minor

Update Docker image name for consistency.

Lines 5-7 reference robo-policy, which conflicts with the "Kinitro Miner Policy Server" header (line 1) and the kinitro miner push command (line 9). Update these examples to use kinitro-policy for naming consistency across the Dockerfile.

Suggested fix
-# Build: docker build -t your-username/robo-policy:v1 .
-# Test:  docker run -p 8000:8000 your-username/robo-policy:v1
-# Push:  docker push your-username/robo-policy:v1
+# Build: docker build -t your-username/kinitro-policy:v1 .
+# Test:  docker run -p 8000:8000 your-username/kinitro-policy:v1
+# Push:  docker push your-username/kinitro-policy:v1
🤖 Fix all issues with AI agents
In `@docs/backend-guide.md`:
- Around line 326-334: The heading "#### `GET /v1/weights/latest`" skips a level
under the existing "## API Reference"; change it to a level-3 heading ("### `GET
/v1/weights/latest`") so the hierarchy increments by one level, and ensure any
sibling API endpoint headings follow the same h3 pattern to satisfy MD001;
update the heading text only (leave the JSON example unchanged).

In `@kinitro/environments/registry.py`:
- Around line 19-20: The inline comment above _ENVIRONMENTS_DIR is inaccurate:
Path(__file__).parent.parent.parent / "environments" resolves to the repo-root
environments directory (three levels up), not kinitro/environments/; update the
comment to state that this constant points to the repository-root
"environments/" directory (or alternatively change the Path expression to
parent.parent / "environments" if you intended kinitro/environments) and ensure
the comment and the Path(...) usage for _ENVIRONMENTS_DIR are consistent.
🧹 Nitpick comments (2)
kinitro/miner/template/Dockerfile (1)

11-37: Consider adding a non-root user for improved security.

The Dockerfile runs the application as root, which is a security risk. As miners will deploy this template, consider adding a non-root user to follow container security best practices.

🛡️ Proposed security improvement
 FROM python:3.11-slim
 
 WORKDIR /app
 
 # Install system dependencies
 RUN apt-get update && apt-get install -y --no-install-recommends \
     libgl1 \
     libglib2.0-0 \
     && rm -rf /var/lib/apt/lists/*
 
 # Install Python dependencies
 COPY requirements.txt .
 RUN pip install --no-cache-dir -r requirements.txt
 
 # Copy policy server code
 COPY server.py .
 COPY policy.py .
 
 # Copy model weights (uncomment and modify as needed)
 # COPY model.pt .
 # COPY models/ ./models/
 
+# Create non-root user
+RUN useradd -m -u 1000 miner && chown -R miner:miner /app
+USER miner
+
 # Expose port for FastAPI
 EXPOSE 8000
 
 # Run the FastAPI server
 CMD ["uvicorn", "server:app", "--host", "0.0.0.0", "--port", "8000"]
CONTRIBUTING.md (1)

207-210: Add a language identifier to the fenced code block.

Static analysis flags this block (MD040). Since this shows a commit message template, you could use text or leave a brief identifier to satisfy linting.

Suggested fix
-```
+```text
 <type>(<scope>): <description>
</details>

</blockquote></details>

</blockquote></details>

<!-- This is an auto-generated comment by CodeRabbit for review status -->

@rayokamoto rayokamoto force-pushed the docs/cleanup-and-contrib branch from 629c6e3 to 1a00e24 Compare February 13, 2026 03:00
Copy link
Collaborator

@Shr1ftyy Shr1ftyy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm.

@rayokamoto rayokamoto merged commit ea963b9 into main Feb 13, 2026
2 checks passed
@rayokamoto rayokamoto deleted the docs/cleanup-and-contrib branch February 13, 2026 04:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Comments