agentleFS
NexusGPUNexusGPU/tensor-fusion/AGENTS.md

tensor-fusion

AGENTS.md170 starsChanged 10 months agoApache-2.0View on GitHub

A Kubernetes operator for GPU virtualization and pooling. This repository builds two binaries: The vendor libraries it loads (vgpu-provider), the client and worker used for hard isolation and remote GPUs (tensor-fusion-core), and the console (tensor-fusion-cloud) live in other repositories. docs/stack-context.md maps the whole stack and the contracts between repositories; read it before touching images, the limiter, client/worker, or anything the console consumes. Write code, comments, commit messages, and documentation in English. Design documents: docs/dynamic-gpu-isolation-design.md, docs/soft-isolation-preload.md, design/. Installation and Helm values:…

We split this AGENTS.md into the rules it gives an agent

1 rule. About 0 are common, 1 is distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Write code, comments, commit messages, and documentation in English.

    line 10

≈ “Common” is an estimate: at least 1 in 5 of the 36,368 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
AGENTS.md

TensorFusion

A Kubernetes operator for GPU virtualization and pooling. This repository builds two binaries:

  • controller (cmd/main.go): CRD controllers, the Pod mutating webhook, and an embedded kube-scheduler, in one process.
  • hypervisor (cmd/hypervisor): the per-node agent that discovers devices and enforces fractional GPU limits. It is written in Go and replaced the Rust hypervisor from vgpu.rs.

The vendor libraries it loads (vgpu-provider), the client and worker used for hard isolation and remote GPUs (tensor-fusion-core), and the console (tensor-fusion-cloud) live in other repositories. docs/stack-context.md maps the whole stack and the contracts between repositories; read it before touching images, the limiter, client/worker, or anything the console consumes.

Write code, comments, commit messages, and documentation in English.

Where things are

To changeGo to
CRD fieldsapi/v1/, then make manifests generate; the chart's copies are in charts/tensor-fusion/crds/
What gets injected into a Podinternal/webhook/v1/, internal/utils/compose.go
Scheduling and GPU allocationinternal/scheduler/, internal/gpuallocator/
Node scaling, Karpenterinternal/controller/gpupool_node_provision.go, gpunodeclaim_controller.go, internal/cloudprovider/, internal/scheduler/expander/
Enforcing compute and VRAM limitspkg/hypervisor/worker/ (shared memory layout in state/, control loop in computing/)
Device discovery, vendorspkg/hypervisor/device/, provider/, pkg/constants/vendors.go
Annotation and environment variable namespkg/constants/
Metrics and alertsinternal/metrics/, internal/alert/
Helm chartcharts/tensor-fusion/
End-to-end tests on real clusterse2e/ (EKS: e2e/terraform/, ACK with real GPUs: e2e/ack/)

Design documents: docs/dynamic-gpu-isolation-design.md, docs/soft-isolation-preload.md, design/. Installation and Helm values: docs/installation-guide.md.

Commands

make build              # controller
make build-hypervisor   # hypervisor (CGO disabled, purego)
make build-provider     # example accelerator library
make test               # full envtest suite
make ut F=<file>        # one test file under internal/controller
make ut-sched           # scheduler tests
make test-chart         # render the chart and check what it ships
make lint
make vendor             # re-vendor and apply the scheduler patches in patches/

Constraints

  • vendor/ holds a patched kube-scheduler. Do not edit it by hand: change the patch in patches/, then run make vendor.
  • The shared memory layout for soft isolation is defined in this repository, in vgpu-provider, and in vgpu.rs. It has no version field, so all three must change together.
  • pkg/hypervisor and api/v1 are imported as libraries by gpu-go. Changing an exported interface there is a breaking change.
  • provider/*.h are hand-copied from vgpu-provider.
  • A change to CRDs, Helm values, metric tables, or annotations needs a matching change in the console (tensor-fusion-cloud) and the documentation (tensor-fusion-website).

Sensitive information

This repository is public. Never commit keys, tokens, kubeconfigs, connection strings, internal addresses, cloud account IDs, or exploit details of an unfixed security issue. Keep local notes in tmp.* files, which .gitignore excludes.

Download now (ZIP)

  • Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about code style.

    Of the AGENTS.md files we read, the 28,693 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.

  • In this repository2 other files it gives its agents.

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.