Saltar al contenido principal

Code Index Governance

Status: active.

This document explains how agents should search and index AlphaSwarm during the repository split. The goal is to keep edits inside the right future project boundary before source code is physically separated.

Search Order

  1. Read the nearest AGENTS.md for the folder being edited.
  2. Read alphaswarm_docs/repository-split.md to identify the owning domain.
  3. Search within the owning domain first.
  4. Only broaden to alphaswarm/ or repo root when the boundary document says the implementation still lives there.
  5. Record new reusable patterns in alphaswarm_snippets/ or .cursor/skills/ instead of scattering notes across unrelated docs.

Domain Index

DomainStart hereNotes
Control planealphaswarm_controller/AGENTS.md/manage/*, providers, workload lifecycle
Platform corealphaswarm_core/AGENTS.mdShared contracts only
Clientalphaswarm_client/AGENTS.md, alphaswarm_client/AGENTS.mdActive source remains in alphaswarm_client/
Snippetsalphaswarm_snippets/AGENTS.mdReference-only curated knowledge
Botsalphaswarm_bots/AGENTS.mdRuntime remains in alphaswarm/bots/ for now
Runtime monolithAGENTS.mdAgents, RL, data, backtests, persistence, tasks

Indexing Rules

  • Codebase MCP indexes must respect workspace allow-lists and secret deny-lists from alphaswarm/codebase/mcp/policy.py.
  • Generated indexes should not include .env, private keys, kubeconfigs, token files, model weights, or local warehouse data.
  • Agent-readable docs should link to paths, not line numbers, unless the output is a transient review.
  • Keep split-boundary indexes short enough that agents can read them before editing.

Boundary Checks

Use these searches before a boundary-sensitive change:

rg --type py "^from alphaswarm(\.|$)|^import alphaswarm(\.|$)" alphaswarm_controller/src
rg "alphaswarm_snippets|extractions|inspiration" alphaswarm alphaswarm_controller alphaswarm_core
rg "control.local/api|management/backend|management/frontend" docs README.md

The first command must return no matches. The second and third commands may return documented migration references, but should not reveal runtime imports or active instructions that route new work to deprecated surfaces.