Skip to content

Conversation

@hawkaii
Copy link
Contributor

@hawkaii hawkaii commented Sep 24, 2025

What this PR does / why we need it:
adds AGENTS.MD file for AI-assisted development

Fixes #86

Checklist:

  • Docs included if any changes are user facing

Signed-off-by: Parthib Mukherjee <[email protected]>
@hawkaii hawkaii changed the title added(AGENTS.MD): added AGENTS.MD chore(AGENTS.MD): added AGENTS.MD Sep 24, 2025
@hawkaii hawkaii changed the title chore(AGENTS.MD): added AGENTS.MD chore(docs): added AGENTS.MD Sep 24, 2025
Copy link
Contributor

@kramaranya kramaranya left a comment

Choose a reason for hiding this comment

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

Thank you @hawkaii for working on this!

Could we provide more information in this doc to align with other examples?
For example, pipelines have a good content https://github.com/kubeflow/pipelines/blob/master/AGENTS.md
Also kubernetes https://github.com/kubernetes/kubernetes/blob/1f98145048835b8a9fd6ec9d769f57fc548c8304/AGENTS.md
I personally like what langchain has https://github.com/langchain-ai/langchain/blob/master/AGENTS.md

…and development principles

Signed-off-by: Parthib Mukherjee <[email protected]>
@google-oss-prow google-oss-prow bot added size/L and removed size/S labels Sep 29, 2025
Removed introductory line about AGENTS guide.

Signed-off-by: Parthib Mukherjee <[email protected]>
@coveralls
Copy link

coveralls commented Oct 16, 2025

Pull Request Test Coverage Report for Build 18630153766

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 26 unchanged lines in 1 file lost coverage.
  • Overall coverage increased (+0.7%) to 72.43%

Files with Coverage Reduction New Missed Lines %
kubeflow/trainer/utils/utils.py 26 66.06%
Totals Coverage Status
Change from base Build 17979146135: 0.7%
Covered Lines: 310
Relevant Lines: 428

💛 - Coveralls

Copy link
Member

@andreyvelich andreyvelich left a comment

Choose a reason for hiding this comment

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

Thank you @hawkaii!
Overall looks good, I left a few suggestions.
Maybe @franciscojavierarceo or @kubeflow/wg-pipeline-leads can provide additional suggestions based on their experience in Feast or KFP.

AGENTS.md Outdated
Comment on lines 14 to 28
## Project Overview

**Purpose**: Kubeflow SDK provides a unified Python SDK for AI practitioners to interact with multiple Kubeflow projects via consistent APIs, focusing on user workflows over infrastructure details.

**Problem It Solves**: Reduces Kubernetes and multi-project complexity, offering simple, local-first Python interfaces for training, tuning, pipelines (planned), and model lifecycle management.

**Key Benefits**:
- Unified experience across Kubeflow projects
- Simplified AI workflows with minimal infrastructure knowledge
- Local development support (install via `pip`) with optional cluster backends

**Today's Scope**:
- **Available**: Kubeflow Trainer (train/fine-tune with different backends)
- **Planned**: Katib (HPO), Pipelines (workflows), Model Registry
- See README "Supported Kubeflow Projects" for current status
Copy link
Member

Choose a reason for hiding this comment

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

Will this help AI Agents to write/debug code or we can remove this to reduce context ?

- **Available**: Kubeflow Trainer (train/fine-tune with different backends)
- **Planned**: Katib (HPO), Pipelines (workflows), Model Registry
- See README "Supported Kubeflow Projects" for current status

Copy link
Member

Choose a reason for hiding this comment

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

Might be useful to introduce Context Awareness:

### Context Awareness

Before writing code, agents should:

- Read docstrings and existing test cases for pattern alignment
- Match import patterns from neighboring files
- Preserve existing logging and error-handling conventions

- **Build**: Hatchling (optional `uv build`)
- **Pre-commit**: Config provided and enforced in CI

## Quick Start
Copy link
Member

Choose a reason for hiding this comment

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

Wondering if it is better to wrap command to special tokens, like this ?

<!-- BEGIN: AGENT_COMMANDS -->
Preferred commands:
- Install deps: `make install-dev`
- Verify: `make verify`
- Test: `make test-python`
<!-- END: AGENT_COMMANDS -->

- Use `pytest` as the testing framework
- See `kubeflow/trainer/test/common.py` for fixtures and patterns

**Test Quality Checklist:**
Copy link
Member

Choose a reason for hiding this comment

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

Tell that unit tests structure must be consistent between each other. As example add: kubeflow/trainer/backends/kubernetes/backend_test.py

Comment on lines +165 to +174
def test_filter_completed_jobs():
"""Test filtering completed jobs from a list."""
jobs = ["job-1", "job-2", "job-3"]
completed = {"job-1", "job-2"}

result = filter_completed_jobs(jobs, completed)

assert result == ["job-3"]
assert len(result) == 1
```
Copy link
Member

Choose a reason for hiding this comment

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

Please also show that tests cases must be set before the tests functions with @pytest.mark.parametrize like here:

@franciscojavierarceo
Copy link

@andreyvelich i just had claude generate it and i merged it. No discussion :)

@franciscojavierarceo
Copy link

That was much faster for me. :)

Copy link
Member

@andreyvelich andreyvelich left a comment

Choose a reason for hiding this comment

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

@andreyvelich
Copy link
Member

We should be good to move this forward.
/approve

@google-oss-prow
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: andreyvelich

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@google-oss-prow google-oss-prow bot merged commit e878505 into kubeflow:main Oct 27, 2025
13 of 14 checks passed
@google-oss-prow google-oss-prow bot added this to the v0.2 milestone Oct 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add AGENTS.MD for AI-assisted development

8 participants