Governance infrastructure that compiles and validates organization-level agent rules
Project description
Org Agentic Toolkit (OAT)
Governance infrastructure that compiles and validates organization-level agent rules for all projects in an org.
Overview
The Org Agentic Toolkit (OAT) defines, compiles, and distributes the authoritative agent rules for all projects within an organization. It ensures every project inherits org rules by construction, allows optional personal overlays without weakening org authority, and produces deterministic, auditable agent instructions.
Inspiration:
This project is partly inspired by nAItmare, an open-source repository for centralizing multi-agent standards.
Features
- Single org-wide agentic constitution: Enforce consistent rules across all projects
- Explicit inheritance: Projects explicitly declare which skills and personas they use
- Personal overlays: Optional developer-specific preferences (lowest precedence)
- Deterministic compilation: Same inputs produce same output byte-for-byte
- IDE integration: Output to IDE-specific configuration files (Cursor, Windsurf, etc.)
- Validation: Comprehensive validation of configuration and referenced files
Installation
From Source (with uv and pyproject)
git clone <repository-url>
cd org_agentic_toolkit
# Install in editable mode using uv, based on pyproject.toml with dev dependencies
uv pip install -e ".[dev]"
This uses uv following dependencies declared in
pyproject.toml, with the package installed as a development-only dependency.
Quick Start
1. Initialize Organization Root
First, create your organization's constitution documents:
mkdir my-org
cd my-org
oat init org
This creates the full structure for an organization's agent rules, including:
.oat-root- Discovery marker file.agent/memory/constitution.md- Organization constitution.agent/memory/general-context.md- General context.agent/memory/manifest.yaml- Memory manifest- Directory structure for skills, personas, and teams
2. Initialize Projects
Then, initialize each project to reference the organization:
cd your-project
oat init project --org-root ../my-org
If the org root is in a parent directory, OAT will auto-detect it:
cd your-project
oat init project
This creates:
AGENTS.md- Entry point for agents.agent/inherits.yaml- Project configuration (references org root).agent/project.md- Project-specific rules
Organization Root Discovery:
- OAT automatically discovers org roots by walking up the directory tree looking for
.oat-root - If
.oat-rootis not found, it falls back to checking for.agent/memory/constitution.md - You can also specify the org root path in
.agent/inherits.yamlor via theOAT_ROOTenvironment variable
3. Configure Your Project
Edit .agent/inherits.yaml to specify which skills and personas your project uses:
org_root: ../my-org
skills:
universal:
- git
- test
- db
languages:
python:
- django
- pytest
personas:
- backend-developer
- tech-lead
target_agents:
- cursor
- windsurf
4. Compile Agent Instructions
oat compile
This produces AGENTS.compiled.md with all rules merged in the correct precedence order.
5. Validate Configuration
oat validate
Checks that all referenced files exist and configuration is valid.
Optional: Personal Preferences
To create a personal overlay for your own preferences:
oat init personal
Personal overlays have the lowest precedence and cannot override org rules.
CLI Commands
oat compile
Compile agent instructions from org rules, project rules, and personal overlay.
Options:
--out <path>: Override output path (default:AGENTS.compiled.md)--target <name>: Compile for specific IDE (e.g.,cursor,windsurf)--no-personal: Ignore personal overlay--print: Print compiled content to stdout--hash: Include content hash in output--diff: Show changes since last compilation--include-skill <name>: Additionally include a skill--exclude-skill <name>: Exclude a skill from manifest--include-persona <name>: Additionally include a persona--exclude-persona <name>: Exclude a persona from manifest--repo <path>: Explicit repo root path
Examples:
# Basic compilation
oat compile
# Compile for Cursor IDE
oat compile --target cursor
# Compile with hash
oat compile --hash
# Print to stdout
oat compile --print
oat validate
Validate repository configuration and referenced files.
Options:
--repo <path>: Explicit repo root path--strict: Treat warnings as errors--json: Output JSON format
Examples:
# Basic validation
oat validate
# Strict validation
oat validate --strict
# JSON output
oat validate --json
oat doctor
Show diagnostic information about the current repository configuration.
Options:
--json: Output JSON format
Example:
oat doctor
Output includes:
- Repo root and org root paths
- Entry point location
- Constitution version
- Memory files loaded
- Skills and personas from manifest
- Teams referenced
- Project rules location
- Personal overlay status
- Available but not included items
oat init project
Initialize a project repository with agentic toolkit configuration.
Options:
--org-root <path>: Explicit org root path--force: Overwrite existing files--suggest: Suggest skills/personas based on project files
Examples:
# Basic initialization
oat init project
# With suggestions
oat init project --suggest
# With explicit org root
oat init project --org-root ../org-agentic-toolkit
oat init org
Initialize an organization root repository.
Options:
--name <name>: Organization name (default: "My Org")--force: Overwrite existing files
oat init personal
Initialize personal overlay directory.
Options:
--path <path>: Override personal folder path--force: Overwrite existing files
Project Structure
Org Root
org-agentic-toolkit/
├── .oat-root # Discovery marker
├── AGENTS.md # Entry point
├── .agent/
│ ├── memory/
│ │ ├── constitution.md # Immutable org rules
│ │ ├── general-context.md
│ │ ├── manifest.yaml
│ │ └── teams/ # Team-specific context
│ ├── skills/ # Atomic knowledge modules
│ │ ├── git.md
│ │ ├── test.md
│ │ └── [language]/ # Language-specific skills
│ ├── personas/ # Specialized personas
│ └── toolkit/ # Toolkit implementation
└── repos/ # Project repositories
Project Repo
project-repo/
├── AGENTS.md # Entry point (optional)
└── .agent/
├── inherits.yaml # Project configuration (required)
└── project.md # Project-specific rules (required)
Compilation Order
The compiled document follows strict precedence (highest to lowest):
- Entry Point (
AGENTS.mdfrom repo) - Org Memory (constitution, general-context, teams)
- Universal Skills (from
inherits.yaml, in order) - Language/Stack Skills (grouped by language, in order)
- Org Personas (from
inherits.yaml, in order) - Project Rules (
project.md) - Personal Overlay (optional, lowest authority)
Environment Variables
OAT_ROOT: Explicitly set the org root pathORG_AGENTIC_TOOLKIT_ROOT_NAME: Control org root directory naming patternAGENT_PERSONAL_FOLDER: Path to personal overlay directory (default:~/.agent)
IDE Integration
The toolkit supports outputting to IDE-specific configuration files via the --target option:
oat compile --target cursor # Outputs to .cursorrules
oat compile --target windsurf # Outputs to .windsurfrules
Supported targets are defined in .agent/toolkit/targets.yaml.
Personal Overlay
Developers can maintain personal preferences in ~/.agent/ (or path specified by AGENT_PERSONAL_FOLDER):
~/.agent/
├── memory/
│ └── personal-context.md
├── skills/
│ └── personal-git.md
└── personas/
└── me.md # Team membership (gitignored)
Personal overlay has the lowest precedence and cannot override org rules.
Validation Rules
The validator checks:
AGENTS.mdexists (warning if missing).agent/inherits.yamlexists and is valid (error if missing)skillsandpersonassections exist (error if missing)org_rootresolves and contains constitution- All referenced skills exist
- All referenced personas exist
- All referenced teams exist
.agent/project.mdexists (error in strict mode, warning otherwise).agent/project.mdexists (error in strict mode, warning otherwise)- No forbidden constructs (absolute paths, etc.)
Validation automatically detects the context:
- Org Root: Checks
.oat-root, constitution, manifest, etc. - Personal Overlay: Checks personal context, me.md
- Project Repo: Checks inherits.yaml and inheritance
Examples
Example: Python Django Project
.agent/inherits.yaml:
org_root: ../..
skills:
universal:
- git
- test
- db
- review-checklist
languages:
python:
- django
- pytest
personas:
- backend-developer
- tech-lead
teams:
- platform
target_agents:
- cursor
Example: Full-Stack JavaScript Project
.agent/inherits.yaml:
org_root: ../..
skills:
universal:
- git
- test
languages:
javascript:
- react
- nodejs
- jest
personas:
- frontend-developer
- backend-developer
- tech-lead
Development
Running Tests
pytest
Project Structure
org_agentic_toolkit/
├── oat/ # Main package
│ ├── cli.py # CLI commands
│ ├── discovery.py # Root discovery
│ ├── config.py # YAML loading
│ ├── compiler.py # Compilation engine
│ ├── validator.py # Validation logic
│ ├── template_manager.py # Template manager
│ └── templates/ # Template files (package data)
├── tests/ # Test suite
├── pyproject.toml # Package config
└── MANIFEST.in # Package data config
License
MIT
Contributing
Contributions welcome! Please read CONTRIBUTING.md for guidelines on how to contribute, including:
- Development setup and installation
- Code style and testing guidelines
- How to submit pull requests
- Project structure and workflow
We appreciate all contributions, whether they're bug fixes, new features, documentation improvements, or other enhancements.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file org_agentic_toolkit-1.1.2.tar.gz.
File metadata
- Download URL: org_agentic_toolkit-1.1.2.tar.gz
- Upload date:
- Size: 46.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8480273a04123fe87f15dbcf057bbd70e5e8db80990501027ad52adae3046725
|
|
| MD5 |
89352abb0f83a6e06c9739a5d3398d2a
|
|
| BLAKE2b-256 |
941571d08793efc39d7227bbe7832bd0cd186c8297cb0d2336d5f00795a193ac
|
Provenance
The following attestation bundles were made for org_agentic_toolkit-1.1.2.tar.gz:
Publisher:
publish.yml on alain-sv/org-agentic-toolkit
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
org_agentic_toolkit-1.1.2.tar.gz -
Subject digest:
8480273a04123fe87f15dbcf057bbd70e5e8db80990501027ad52adae3046725 - Sigstore transparency entry: 1011138108
- Sigstore integration time:
-
Permalink:
alain-sv/org-agentic-toolkit@f82e55c1cad3b490694cc6e3ea074cd27b2055d5 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/alain-sv
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@f82e55c1cad3b490694cc6e3ea074cd27b2055d5 -
Trigger Event:
push
-
Statement type:
File details
Details for the file org_agentic_toolkit-1.1.2-py3-none-any.whl.
File metadata
- Download URL: org_agentic_toolkit-1.1.2-py3-none-any.whl
- Upload date:
- Size: 49.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b48f7b2fda4801f8a9bcab1efaf3303a87d914e2d6438084b93779784926cbbd
|
|
| MD5 |
dc66d6c0d866cc2409c06eb37d10056c
|
|
| BLAKE2b-256 |
10cf56f8600a85dc8c1c1dacadc9da44236f16d1417e7619e09b34648a20906a
|
Provenance
The following attestation bundles were made for org_agentic_toolkit-1.1.2-py3-none-any.whl:
Publisher:
publish.yml on alain-sv/org-agentic-toolkit
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
org_agentic_toolkit-1.1.2-py3-none-any.whl -
Subject digest:
b48f7b2fda4801f8a9bcab1efaf3303a87d914e2d6438084b93779784926cbbd - Sigstore transparency entry: 1011138174
- Sigstore integration time:
-
Permalink:
alain-sv/org-agentic-toolkit@f82e55c1cad3b490694cc6e3ea074cd27b2055d5 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/alain-sv
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@f82e55c1cad3b490694cc6e3ea074cd27b2055d5 -
Trigger Event:
push
-
Statement type: